Updated 08. Setting up and Deploying eShopOnContainers to Windows Containers (markdown)
							parent
							
								
									28088e3a57
								
							
						
					
					
						commit
						1c1a6c9369
					
				| @ -57,9 +57,11 @@ Although you can create the Docker images when trying to run the containers, let | ||||
| In order compile the bits and build the Docker images, run: | ||||
| ``` | ||||
| cd <root-folder-of--eshoponcontainers> | ||||
| docker-compose -f docker-compose-windows.yml build | ||||
| docker-compose -f docker-compose.yml -f docker-compose.windows.yml build | ||||
| ``` | ||||
| 
 | ||||
| **Note** Be sure to pass both `-f` when building containers for windows containers! | ||||
| 
 | ||||
| ### 2. Deploy/run the containers | ||||
| 
 | ||||
| The esasiest way to run/start the Windows Containers of eShopOnContainers is by running this PowerShell script: | ||||
| @ -73,10 +75,18 @@ Otherwise, you could also run it directly with `docker-compose up` but then you' | ||||
| Under the covers, in any case, the start-windows-containers.ps1 is running this command to deploy/run the containers: | ||||
| 
 | ||||
| ``` | ||||
| docker-compose -f docker-compose-windows.yml -f docker-compose.override.yml -f docker-compose.override.windows.yml up | ||||
| set ESHOP_OCELOT_VOLUME_SPEC=C:\app\configuration | ||||
| docker-compose -f docker-compose-windows.yml -f docker-compose.override.yml -f -f docker-compose.windows.yml -f docker-compose.override.windows.yml up | ||||
| ``` | ||||
| 
 | ||||
| **IMPORTANT**: You need to use these three files when running docker-compose up and to have te environment variables related to the localhost loopback limitation mentioned at the end of this post. | ||||
| **IMPORTANT**: You need to those files when running docker-compose up **and the `ESHOP_OCELOT_VOLUME_SPEC` environment variable must be set to `C:\app\configuration`.Also yo have to have the environment variables related to the localhost loopback limitation mentioned at the end of this post. | ||||
| 
 | ||||
| Just for reference here are the docker compose files and what they do: | ||||
| 
 | ||||
| 1. `docker-compose.yml`: Main compose file. Define all services for both Linux & Windows and set base images for Linux | ||||
| 2. `docker-compose.override.yml`: Main override file. Define all config for both Linux & Windows, with Linux-based defaults | ||||
| 3. `docker-compose.windows.override.yml`: Overrides some previous data (like images) for Windows containers | ||||
| 4. `docker-compose.windows.override.yml`: Adds specific windows-only configuration | ||||
| 
 | ||||
| ## Test/use the eShopOnContainers MVC app in a browser | ||||
| 
 | ||||
| @ -115,6 +125,7 @@ When passing the parameter `-customEventBusLoginPassword $true` to the script yo | ||||
| If you prefer to use `docker-compose` you can do it. Just call it without the `docker-compose.override.windows.yml` file: | ||||
| 
 | ||||
| ``` | ||||
|  docker-compose -f docker-compose-windows.yml -f docker-compose.override.yml up | ||||
|  set ESHOP_OCELOT_VOLUME_SPEC=C:\app\configuration | ||||
|  docker-compose -f docker-compose-windows.yml -f docker-compose.override.yml  -f docker-compose.windows.yml up | ||||
| ``` | ||||
| 
 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user