You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+29-29Lines changed: 29 additions & 29 deletions
Original file line number
Diff line number
Diff line change
@@ -79,15 +79,15 @@ docker run [-d] \
79
79
80
80
| Parameter | Description |
81
81
|-----------|-------------|
82
-
| -d | Run the container in the background. If not set, the container runs in the foreground. |
83
-
| -e | Pass an environment variable to the container. See the [Environment Variables](#environment-variables) section for more details. |
84
-
| -v | Set a volume mapping (allows to share a folder/file between the host and the container). See the [Data Volumes](#data-volumes) section for more details. |
85
-
| -p | Set a network port mapping (exposes an internal container port to the host). See the [Ports](#ports) section for more details. |
82
+
| -d | Run the container in the background. If not set, the container runs in the foreground. |
83
+
| -e | Pass an environment variable to the container. See the [Environment Variables](#environment-variables) section for more details. |
84
+
| -v | Set a volume mapping (allows to share a folder/file between the host and the container). See the [Data Volumes](#data-volumes) section for more details. |
85
+
| -p | Set a network port mapping (exposes an internal container port to the host). See the [Ports](#ports) section for more details. |
86
86
87
87
### Environment Variables
88
88
89
89
To customize some properties of the container, the following environment
90
-
variables can be passed via the `-e` parameter (one for each variable). Value
90
+
variables can be passed via the `-e` parameter (one for each variable). Value
91
91
of this parameter has the format `<VARIABLE_NAME>=<VALUE>`.
92
92
93
93
| Variable | Description | Default |
@@ -108,7 +108,7 @@ of this parameter has the format `<VARIABLE_NAME>=<VALUE>`.
108
108
#### Deployment Considerations
109
109
110
110
Many tools used to manage Docker containers extract environment variables
111
-
defined by the Docker image and use them to create/deploy the container. For
111
+
defined by the Docker image and use them to create/deploy the container. For
112
112
example, this is done by:
113
113
- The Docker application on Synology NAS
114
114
- The Container Station on QNAP NAS
@@ -120,33 +120,33 @@ variables to fit its needs, it can also be confusing and dangerous to keep all
120
120
of them.
121
121
122
122
A good practice is to set/keep only the variables that are needed for the
123
-
container to behave as desired in a specific setup. If the value of variable is
124
-
kept to its default value, it means that it can be removed. Keep in mind that
123
+
container to behave as desired in a specific setup. If the value of variable is
124
+
kept to its default value, it means that it can be removed. Keep in mind that
125
125
all variables are optional, meaning that none of them is required for the
126
126
container to start.
127
127
128
128
Removing environment variables that are not needed provides some advantages:
129
129
130
-
- Prevents keeping variables that are no longer used by the container. Over
130
+
- Prevents keeping variables that are no longer used by the container. Over
131
131
time, with image updates, some variables might be removed.
132
-
- Allows the Docker image to change/fix a default value. Again, with image
132
+
- Allows the Docker image to change/fix a default value. Again, with image
133
133
updates, the default value of a variable might be changed to fix an issue,
134
134
or to better support a new feature.
135
135
- Prevents changes to a variable that might affect the correct function of
136
-
the container. Some undocumented variables, like `PATH` or `ENV`, are
137
-
required to be exposed, but are not meant to be changed by users. However,
136
+
the container. Some undocumented variables, like `PATH` or `ENV`, are
137
+
required to be exposed, but are not meant to be changed by users. However,
138
138
container management tools still show these variables to users.
139
139
- There is a bug with the Container Station on QNAP and the Docker application
140
140
on Synology, where an environment variable without value might not be
141
-
allowed. This behavior is wrong: it's absolutely fine to have a variable
142
-
without value. In fact, this container does have variables without value by
143
-
default. Thus, removing unneeded variables is a good way to prevent
141
+
allowed. This behavior is wrong: it's absolutely fine to have a variable
142
+
without value. In fact, this container does have variables without value by
143
+
default. Thus, removing unneeded variables is a good way to prevent
144
144
deployment issue on these devices.
145
145
146
146
### Data Volumes
147
147
148
-
The following table describes data volumes used by the container. The mappings
149
-
are set via the `-v` parameter. Each mapping is specified with the following
148
+
The following table describes data volumes used by the container. The mappings
149
+
are set via the `-v` parameter. Each mapping is specified with the following
0 commit comments