We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The environment file syntax documentation contains the following example:
Quotes can be escaped with \. VAR='Let\'s go!' -> Let's go!
\
VAR='Let\'s go!'
Let's go!
Source: https://docs.docker.com/compose/environment-variables/env-file/
However, when I attempt this, VAR has a value of Let\'s go!.
VAR
Let\'s go!
# test.env VAR='Let\'s go!'
# compose.yaml services: test: image: debian env_file: test.env command: env
docker compose up
This is the output I get:
scratch-test-1 | PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin scratch-test-1 | HOSTNAME=ef2eaa14b918 scratch-test-1 | VAR=Let\'s go! scratch-test-1 | HOME=/root scratch-test-1 exited with code 0
This is the expected output:
scratch-test-1 | PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin scratch-test-1 | HOSTNAME=ef2eaa14b918 scratch-test-1 | VAR=Let's go! scratch-test-1 | HOME=/root scratch-test-1 exited with code 0
Docker Compose version v2.21.0
Client: Docker Engine - Community Version: 24.0.7 Context: default Debug Mode: false Plugins: buildx: Docker Buildx (Docker Inc.) Version: v0.11.2 Path: /usr/libexec/docker/cli-plugins/docker-buildx compose: Docker Compose (Docker Inc.) Version: v2.21.0 Path: /usr/libexec/docker/cli-plugins/docker-compose Server: Containers: 2 Running: 0 Paused: 0 Stopped: 2 Images: 3 Server Version: 24.0.7 Storage Driver: overlay2 Backing Filesystem: extfs Supports d_type: true Using metacopy: false Native Overlay Diff: true userxattr: false Logging Driver: json-file Cgroup Driver: cgroupfs Cgroup Version: 1 Plugins: Volume: local Network: bridge host ipvlan macvlan null overlay Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog Swarm: inactive Runtimes: io.containerd.runc.v2 runc Default Runtime: runc Init Binary: docker-init containerd version: 3dd1e886e55dd695541fdcd67420c2888645a495 runc version: v1.1.10-0-g18a0cb0 init version: de40ad0 Security Options: seccomp Profile: builtin Kernel Version: 5.15.133.1-microsoft-standard-WSL2 Operating System: Debian GNU/Linux 11 (bullseye) OSType: linux Architecture: x86_64 CPUs: 4 Total Memory: 7.731GiB Name: [REDACTED] ID: 8020fa55-64b4-46e1-8b70-947218f6c476 Docker Root Dir: /var/lib/docker Debug Mode: false Experimental: false Insecure Registries: 127.0.0.0/8 Live Restore Enabled: false WARNING: No blkio throttle.read_bps_device support WARNING: No blkio throttle.write_bps_device support WARNING: No blkio throttle.read_iops_device support WARNING: No blkio throttle.write_iops_device support
No response
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
Description
The environment file syntax documentation contains the following example:
Source: https://docs.docker.com/compose/environment-variables/env-file/
However, when I attempt this,
VAR
has a value ofLet\'s go!
.Steps To Reproduce
docker compose up
This is the output I get:
This is the expected output:
Compose Version
Docker Environment
Anything else?
No response
The text was updated successfully, but these errors were encountered: