Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where does APPDATA get initialized in the default docker-compose.override file

Below I will show the default docker-compose.override.yml file that was created for me when added orchestration to my ASP.NET application. This is using .NET Core 3.1. I right clicked on the project file -> Add -> Container Orchestrator Support... and the docker-compose project was added to my solution. (Obviously I chose Docker Compose in the options).

I would like to know where the variable APPDATA is being initialized so that I can understand the full path. I understand how the volumes work; I'm simply interested in knowing how and where APPDATA is initialized.

version: '3.4'

services:
  myproject:
    environment:
      - ASPNETCORE_ENVIRONMENT=Development
      - ASPNETCORE_URLS=https://+:443;http://+:80
    ports:
      - "80"
      - "443"
    volumes:
      - ${APPDATA}/Microsoft/UserSecrets:C:\Users\ContainerUser\AppData\Roaming\Microsoft\UserSecrets:ro
      - ${APPDATA}/ASP.NET/Https:C:\Users\ContainerUser\AppData\Roaming\ASP.NET\Https:ro
like image 493
Michael Puckett II Avatar asked Feb 13 '20 02:02

Michael Puckett II


People also ask

What does Docker compose override do?

The docker-compose. override. yml is the configuration file where you can override existing settings from docker-compose. yml or even add completely new services.

Where are Docker compose files located?

The default path for a Compose file is ./docker-compose.yml .

Does Docker compose override Dockerfile?

Docker-compose command doesn't override Dockerfile CMD.

Which is the default location of a config file when using docker config?

The preferred method for configuring the Docker Engine on Windows is using a configuration file. The configuration file can be found at 'C:\ProgramData\Docker\config\daemon. json'. You can create this file if it doesn't already exist.


Video Answer


1 Answers

I know this is an old post and you probably figure it out but, APPDATA is variable built in with Windows.

If you open Windows Explorer or Run and paste APPDATA with % before and after you will get path.

appdata-variable-path

like image 144
Alan Jagar Avatar answered Oct 03 '22 21:10

Alan Jagar