The typical setup for developing an Optimizely site is to use CLI tools to create a site and a database. The site can then be executed locally and debugged directly from the local IDE (for example, Visual Studio), to make it easy for developers to build and test sites.
During development, you will eventually want to deploy your solution to a production-like environment, to verify that everything works. In reality, you normally plan how the website is deployed, maintained, and hosted from the start. Cloud-based options are great for optimizing resource usage. Specific development considerations may apply depending on your choice of hosting and maintenance for the site. See Plan deployments.
Some common deployment scenarios include:
- Cloud-based – Deploy to Azure Web Apps.
- Cloud-based managed service – Deploy to Optimizely Digital Experience Platform (DXP).
- Containerized hosting – Deploy to Kubernetes, for example.
- Non-cloud – Deploy to Microsoft IIS and Windows Server.
In this scenario, you deploy your site to an environment based on Microsoft Azure cloud components. Before deploying your site, you must create and configure the various Azure components needed, including a Web App, an SQL Database, a Service Bus, and a BLOB storage.
Cloud-based solutions are powerful when scaling for site availability. However, managing the required components can be quite challenging. With Optimizely Digital Experience Platform (DXP), you let Optimizely manage your cloud components. You can deploy through the Optimizely self-deployment portal or let Optimizely do the deployment.
When the application is to be hosted as a container, the application must first be built as a container image. See Create a Docker file for a CMS application for an example of how to build an Optimizely Content Management System (CMS) application in a Docker image. The built image is then typically deployed to a container registry (for example, Azure Container Registry) that can be accessed from the container orchestrator. Deploy to Azure Web Apps describes how an Azure Web app can be set up from a docker image.
You can also run your site "non-cloud" using Microsoft IIS and Windows or SQL Server. As a first step when moving towards a production-like environment, you can set up a local environment with IIS and deploy to that to understand how it works. Moving to a full version of IIS also requires enabling some features.
When deploying, you create the artifacts for the site, the database, and the application data, and then use XCOPY to move the files to the target server. See Deploy to Windows servers.
You can install a CLI tool called
EPiServer.Net.Cli and then create or update CMS databases.
To transfer content between CMS applications or databases you can use Optimizely's export/import feature. This lets you define which items you want to export to an export file. Data from the export file can then be imported to another application or database.
You can also let the application create the database schema directly on a remote server, given that
DataAccessOption.CreateDatabaseSchema is true (which is the default value):
- Create an empty database on the SQL Server.
- Configure your connection string for your application (for example, in
appSettings.json) to point to your empty database.
- Start your application
Updated about 1 month ago