Silent/Automated Setup

Hello

I would like to be able to install the CMS completely automatically. The demo/blog data should not be installed.

This would allow us to offer the setup directly from the Control Panel.

Can composer create project do this?

Thanks!

Hi @martin.schaible

Yes, this is possible. Try the following:

  1. Run: composer create-project october/october ./octobercms

  2. Navigate to the octobercms directory

  3. Update the .env file with the database configuration

  4. Run php artisan october:migrate

  5. Run php artisan tailor:migrate (optional)

  6. Run php artisan theme:seed demo (optional)

  7. Open http://localhost/admin to create an admin account

You can also combine the three artisan commands with the following (this will seed the demo theme):

php artisan october:install --no-interaction

Hi @daftspunk

Thanks for the answer.

  • If i am in the root folder of the webspace, is the command composer create-project october/october ./ correct? Usualy the CMS goes in the root folder of the webspace.
  • Point 5: Any reason why tailor needs a migration of a brand new installation?
  • Is it possible to use the combined command without seeding the demo data (Blog, etc.)?

Yeah create-project in dot (.) is fine too.

Point 5 is the standard install with the demo theme, etc.

It’s easy enough to remove all that stuff with tailor:prune but the manual process is best if you intentionally don’t want the demo theme/content at all.

There is also october:fresh which deletes the demo theme, we could get it to also call tailor:prune.

However --no-interaction is purely for the happy (non-custom) path.

Why not make it easy and add a switch like eg. -nodemo to not install any demo data?

The same for the UI-based setup: Add a checkbox to disable the installation of any demo stuff.

Why wasting time to remove stuff manually?

Thanks

Because then it would be functionally identical to

php artisan october:migrate

Hi

I don’t understand your answer. What exactly does php artisan october:migrate do?

That doesn’t look like an installation, but rather a migration. What is being migrated and why?

So I’d like to ask again: What needs to be done to ensure that neither demo data, tailoring tools, nor the theme are installed?

thanks

Hi Martin,

The october:install command is a wrapper that runs three things in sequence: october:migrate, tailor:migrate, and theme:seed demo. So if you want a clean install with no demo data, no Tailor, and no demo theme, you just run the first one on its own:

php artisan october:migrate

The word “migrate” here refers to database migrations (the standard Laravel term for creating and updating database tables). It’s not migrating from another system. On a fresh install, it creates all the core tables needed for the CMS to run. That’s the entire installation as far as the database is concerned.

To summarise the three steps and what each one adds:

  • october:migrate - core tables only. This is a complete, working install.
  • tailor:migrate - adds Tailor’s content tables (only needed if you plan to use Tailor blueprints).
  • theme:seed demo - installs the demo theme and its sample content.

So for your silent/automated setup, run composer create-project, configure .env, then run php artisan october:migrate. That’s it. No flag needed because the “no demo” path is already the default behaviour of the individual command - october:install just exists as a convenience for the happy path that includes everything.

Cheers

1 Like

Hi,

Thank you so much. Your answer clarified and answered everything. This will help me achieve my goal very well.

Cheers.

This clarification is useful because the command name can easily suggest that it is only for upgrading an existing installation.

It might be worth adding a short note to the installation documentation that october:migrate is also the minimal clean-install path for automated setups. That would make the distinction between core installation, Tailor, and demo content much easier to discover without needing to piece it together from several commands.

I had the same idea, that the documentation deserves an update on this topic.