development · docker · framework

Playing around with Sitecore 10 docker containers and my simple development framework version 3.0

So I had a chance to play around with Sitecore version 9.3 docker containers some months ago. Now I wanted to deploy the Sitecore solution of my simple development framework to Sitecore version 10.0 docker containers as well. By learning from the following super helpful sources:

As a result, my simple Sitecore development framework version 3.0 is out.

Also, there are some other updates so they’re able to work properly with Sitecore 10.0:

  • upgrade to Glass.Mapper.Sc.100 (thanks my fellow Sitecore MVP Micheal Edwards)
  • msdf30_10
  • upgrade to Unicorn 4.1.12 + Rainbow 2.1.2 (thanks my fellow Sitecore MVPs Mark Cassidy)
  • msdf30_11
  • msdf30_12

Step-by-step guide for Sitecore docker container deployment

  1. please ensure to set up your development environment by following https://containers.doc.sitecore.com/docs/environment-setup
  2. create a new folder, let’s say D:\my-simple-framework and then download + unzip my simple Sitecore development framework version 3.0
  3. to avoid any conflicts, we should ensure the following ports are not being used by another process: 443, 8079, 8081, 8984, and 14330
    • stop IIS
    • stop windows services if any
    • quit Skype for sure
  4. let’s spin up our own container-based Sitecore 10.0.0 instances:
    • rename D:\my-simple-framework\Docker\.env.example to D:\my-simple-framework\Docker\.env
    • open Windows PowerShell (run as administrator)
    • change directory to D:\my-simple-framework\Docker
    • execute .\Init -InitEnv to initialize environment variables and then input
      • LicenseXmlPath: (Ex: “C:\license\license.xml”)
      •  AdminPassword: (Ex: “b”)
         
    • execute .\up to spin up a new Sitecore 10.0.0 instance
    • hopefully will see something like this after a loooooooooooog operation
  5. open a browser, navigate to https://cm.viethoang.local/, we would see the default Sitecore page with a valid SSL certificate
  6. let’s deploy the Sitecore solution
    • rename D:\my-simple-framework\cake-config.json.example to cake-config.json then update the following ones
    • WebsiteRoot to deploy folder which is mounted to docker container
    • This slideshow requires JavaScript.

    • BuildToolVersions to your MS Build version on your own machine (Ex: “VS2019”)
    • rename D:\my-simple-framework\Common.LocalSettings.config.example to Common.LocalSettings.config
    • msdf26_23
    • msdf30_13
    • open Windows PowerShell (run as administrator)
    • change directory to D:\my-simple-framework
    • execute .\build -target Deploy-Docker
    • msdf26_17
    • msdf30_8
  7. open a browser, navigate to the following ones to access Sitecore sites with HTTPS protocol in the docker environment

Notes:

  • take a look at the following steps to shutdown all the containers
    • open Windows PowerShell (run as administrator)
    • change directory to D:\my-simple-framework\Docker
    • execute docker-compose down
    • msdf30_9
  • for data cleanup
    • open Windows PowerShell (run as administrator)
    • change directory to D:\my-simple-framework\Docker
    • execute .\clean
    • msdf30_10
  • for troubleshooting problems with Docker Desktop for Windows and Docker-based Sitecore development https://containers.doc.sitecore.com/docs/troubleshooting
  • for Sitecore docker cheat seat https://containers.doc.sitecore.com/docs/cheat-sheet

Happy Sitecore Docker and Coding!

One thought on “Playing around with Sitecore 10 docker containers and my simple development framework version 3.0

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.