Deploying a Custom Starter Site - Documentation topics on: custom starter site,starter.zip,.

This documentation is a static copy for this version. For current documentation, see: http://dotcms.com/docs/latest

Deploying a Custom Starter Site

The dotCMS distribution comes with a “pre-built” starter site which includes a complete sample site demonstrating the capabilities of dotCMS and providing samples of almost all content types and assets (including Folders, Pages, Content Types, Templates, Containers, code, and more).

The starter site is contained in the starter.zip file in the ROOT directory in the dotCMS distribution (/dotserver/tomcat-X.x.xx/webapps/ROOT). When dotCMS is started, it checks to see if a working site has already been set up; if the database and assets are empty, dotCMS constructs a new site from the starter.zip file.

Disabling the Default Starter Site

dotCMS only builds the default starter site if the starter.zip file is found in the appropriate folder in the distribution.

To disable the creation of the starter site, remove or rename the starter.zip file. When you do this, dotCMS will start up with a blank database, and you must create or import all content and content types in your dotCMS instance.

Creating a Custom Starter Site

You may replace the default dotCMS starter site with your own custom starter site. This enables you to quickly deploy custom starter sites/accelerators on a new dotCMS instance with a specific set of customized pre-built features, content types, assets, etc.

Creating a Custom starter.zip File

You may create your own custom starter.zip file using the built-in Export dotCMS Content function in dotCMS.

To create your own custom starter.zip file:

  1. Build up a normal dotCMS instance containing all the content you wish to include in your custom starter site.
    • Note: All content included in this dotCMS instance will be included in your custom starter site, including all sites, content types, content, etc. So make sure that this dotCMS instance only includes content that you want to include in your starter site.
  2. From the backend of your dotCMS instance, select System -> Maintenance and click the Tools tab.
  3. In the Export dotCMS Content section of the Tools tab, press the Download Data/Assets button.
    • This will download a ZIP file containing all content on the dotCMS instance.
  4. Rename the downloaded ZIP file to starter.zip.

Deploying a Custom Starter Site

You may use a configuration plugin to override the default starter.zip file with your own custom zip file.

To configure a new dotCMS instance to point to a custom starter site:

  1. (Recommended) Disable the default starter.zip file.
  2. Create a new static plugin to contain and deploy your custom starter site.
  3. Create a dotmarketing-config-ext.properties properties extension file in the plugin /conf directory (e.g. /plugins/plugin.name/conf).
  4. Add the STARTER_DATA_LOAD property to the properties extension file and set it to a relative path from the root of the dotCMS distribution, as in the following example:
        STARTER_DATA_LOAD=/plugins/plugin.name/my_starter.zip
    
  5. Deploy the plugin.

When the new dotCMS instance is started (with a clean database and cache), dotCMS will create a new dotCMS instance using your custom starter site.

Note:

  • It is important that you perform all the above steps before starting your dotCMS instance the first time.
    • If you start the dotCMS instance before deploying your starter site plugin, the default dotCMS starter site will be installed; if you later start dotCMS after deploying your plugin, your custom starter site will not be installed, since an existing site (the default starter site) will already exist.
  • As a best practice, it is recommended that you keep your custom starter.zip file in the same plugin used to set the STARTER_DATA_LOAD property.
    • This allows you to easily copy and deploy the entire plugin to new dotCMS distributions.

Important Notes

  • The dotCMS Demo Site is built using the default starter site.
    • This means that even if you have not installed the default starter site on your local dotCMS distribution, you can view and copy contents from the default starter site by browsing the back-end of the dotCMS demo site.
    • The dotCMS demo site is rebuilt (and all changes are wiped out) at 12pm and 12am EST every day, to restore the demo site to the default configuration.
  • The default starter site login credentials (both when installed locally or on the dotCMS Demo Site) are:
    • Login: admin@dotcms.com
    • Password: admin