---
title: "Run script to prepare for deployment"
slug: "run-script-to-prepare-for-deployment"
abstract: ""
---
# Run script to prepare for deployment

The Sitecore container deployment package provides a script for automating some of the preparations for Sitecore deployment to a developer machine. The `compose-init.ps1` file is located with the `.env` file.

The `compose-init.ps1` file performs the following actions:

- compresses the Sitecore license file
- creates the Identity Server token signing certificate
- populates the `.env` file
- generates TLS/HTTPS certificates
- installs the root certificate into your Trusted Root Certification Authorities
- updates Windows host names

The script accepts a number of parameters. The following table shows the parameters you can use.

| Parameter | Description | Example | Mandatory |
| --- | --- | --- | --- |
| `LicenseXmlPath` | Path to the Sitecore license file. You must specify this. | `-LicenseXmlPath "c:\license.xml"` | Yes |
| `Topology` | The name of your chosen topology. | `-Topology "XM1"` | No |
| `IdHost` | A custom host name for the Identity Server. | `-IdHost mySCID_1` | No |
| `CdHost` | A custom host name for the CD server. | `-CdHost mySCCD_1` | No |
| `CmHost` | A custom host name for the CM server. | `-CmHost mySCCM_1` | No |
| `SitecoreAdminPassword` | A custom password for the `admin` user. | `-SitecoreAdminPassword df8732V45GH` | No |
| `SqlSaPassword` | A custom password for the database `SA` users. | `-SqlSaPassword poi34l2xGH45` | No |
| `EnvFilePath` | Path to the `.env` file. Specify this if the `.env` file is located in a different folder. | `-EnvFilePath "c:\compose\.env"` | No |
| `SitecoreGalleryRepositoryLocation` | Path to the location of the Sitecore Gallery repository. Specify this if you are not using the official repository. | `-SitecoreGalleryRepositoryLocation "https:\\<path_to_repository>"` | No |
| `IdFolder` | Path to the folder where the Identity Server data are located. Specify this if the data are not located in .\id. | `-IdFolder "c:\compose\id"` | No |
| `CertDataFolder` | Path to the folder where the traefik certificates are located. Specify this if the certificates are not located in `.\traefik\certs`. | `-CertDataFolder "c:\compose\certs"` | No |
| `SqlServer` | Name of the Sql server instance (only for `upgrade.env` file) | `-SqlServer “mssql”` | No |
| `SqlServerFolder` | Path to the folder where the Sql Server data are located. Specify this if the data are not located in .\mssql. | `-SqlServerFolder "c:\compose\mssql"` | No |
| `SqlUserName` | Name of the user of sql server (only for `upgrade.env` file) | `-SqlUserName “sa”` | No |
| `SqlServerCertificatePassword` | A custom password for the mssql.pfx certificate file. | `-SqlServerCertificatePassword "poi34l2xGH45"` | No |
| `IsAlwaysEncrypted` | Option for sql server which allows using of encryption (only for `upgrade.env` file) | `-IsAlwaysEncrypted $false` | No |
| `ProcessingEngineTasksDatabaseUsername` | Name of the least privileged user in database (only for `upgrade.env` file) | `-ProcessingEngineTasksDatabaseUsername “dbo”` | No |
| `SolrConnectionPassword` | Password for user used in connection of Sitecore to Solr | `-SolrConnectionPassword df8732V45GH` | Yes |

If you do not specify passwords for the `admin` or `SA` users, the script assigns default values to them.

To use the script:

1. Open a Windows command window with administrator access. Navigate to the folder containing the `compose-init.ps1` file.
2. Run the script. For example:

    ```text
    .\compose-init.ps1 -Topology "<your_topology>" -LicenseXmlPath "<path_to_the_license_file>" -IdHost <custom_Id_host_name> -CdHost <custom_cd_host_name> -CmHost <custom_cm_host_name> -SitecoreAdminPassword <your_password_for_Sitecore_admin> -SqlSaPassword <your_password_for_sql_sa_user>
    ```

    > [!note]
    > If your Traefik certificates folder already contains certificates the script does not install new certificates.