Skip to content

Commit

Permalink
exec.md: remove misleading part
Browse files Browse the repository at this point in the history
"By default" implies that this is something which could be
disabled for an individual `docker exec` call. This doesn't seem
to be the case, so removing the "by default" part would make
these docs clearer to me.

Signed-off-by: Per Lundberg <[email protected]>
(cherry picked from commit a431b1d)
Signed-off-by: Sebastiaan van Stijn <[email protected]>
  • Loading branch information
perlun authored and thaJeztah committed Dec 11, 2023
1 parent 3ab117e commit a976e50
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions docs/reference/commandline/exec.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,10 @@ This starts a new shell session in the container `mycontainer`.

Next, set environment variables in the current bash session.

By default, the `docker exec` command, inherits the environment variables that
are set at the time the container is created. Use the `--env` (or the `-e` shorthand)
to override global environment variables, or to set additional environment variables
for the process started by `docker exec`.
The `docker exec` command inherits the environment variables that are set at the
time the container is created. Use the `--env` (or the `-e` shorthand) to
override global environment variables, or to set additional environment
variables for the process started by `docker exec`.

The example below creates a new shell session in the container `mycontainer` with
environment variables `$VAR_A` and `$VAR_B` set to "1" and "2" respectively.
Expand Down

0 comments on commit a976e50

Please sign in to comment.