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
+41-12
Original file line number
Diff line number
Diff line change
@@ -24,7 +24,7 @@ appropriate for Docker containers and the major languages that we use.
24
24
To run the `cisagov/example` image via Docker:
25
25
26
26
```console
27
-
docker run cisagov/example:0.0.1
27
+
docker run cisagov/example:0.2.0
28
28
```
29
29
30
30
### Running with Docker Compose ###
@@ -37,7 +37,7 @@ docker run cisagov/example:0.0.1
37
37
38
38
services:
39
39
example:
40
-
image: cisagov/example:0.0.1
40
+
image: cisagov/example:0.2.0
41
41
volumes:
42
42
- type: bind
43
43
source: <your_log_dir>
@@ -82,7 +82,7 @@ environment variables. See the
82
82
83
83
services:
84
84
example:
85
-
image: cisagov/example:0.0.1
85
+
image: cisagov/example:0.2.0
86
86
volumes:
87
87
- type: bind
88
88
source: <your_log_dir>
@@ -125,23 +125,52 @@ environment variables. See the
125
125
1. Pull the new image:
126
126
127
127
```console
128
-
docker pull cisagov/example:0.0.1
128
+
docker pull cisagov/example:0.2.0
129
129
```
130
130
131
131
1. Recreate and run the container by following the [previous instructions](#running-with-docker).
132
132
133
+
## Updating Python dependencies ##
134
+
135
+
This image uses [Pipenv] to manage Python dependencies using a [Pipfile](https://github.com/pypa/pipfile).
136
+
Both updating dependencies and changing the [Pipenv] configuration in `src/Pipfile`
137
+
will result in a modified `src/Pipfile.lock` file that should be committed to the
138
+
repository.
139
+
140
+
> [!WARNING]
141
+
> The `src/Pipfile.lock` as generated will fail `pre-commit` checks due to JSON formatting.
142
+
143
+
### Updating dependencies ###
144
+
145
+
If you want to update existing dependencies you would run the following command
146
+
in the `src/` subdirectory:
147
+
148
+
```console
149
+
pipenv lock
150
+
```
151
+
152
+
### Modifying dependencies ###
153
+
154
+
If you want to add or remove dependencies you would update the `src/Pipfile` file
155
+
and then update dependencies as you would above.
156
+
157
+
> [!NOTE]
158
+
> You should only specify packages that are explicitly needed for your Docker
159
+
> configuration. Allow [Pipenv] to manage the dependencies of the specified
160
+
> packages.
161
+
133
162
## Image tags ##
134
163
135
164
The images of this container are tagged with [semantic
136
165
versions](https://semver.org) of the underlying example project that they
137
166
containerize. It is recommended that most users use a version tag (e.g.
138
-
`:0.0.1`).
167
+
`:0.2.0`).
139
168
140
169
| Image:tag | Description |
141
170
|-----------|-------------|
142
-
|`cisagov/example:1.2.3`| An exact release version. |
143
-
|`cisagov/example:1.2`| The most recent release matching the major and minor version numbers. |
144
-
|`cisagov/example:1`| The most recent release matching the major version number. |
171
+
|`cisagov/example:0.2.0`| An exact release version. |
172
+
|`cisagov/example:0.2`| The most recent release matching the major and minor version numbers. |
173
+
|`cisagov/example:0`| The most recent release matching the major version number. |
145
174
|`cisagov/example:edge` | The most recent image built from a merge into the `develop` branch of this repository. |
146
175
|`cisagov/example:nightly` | A nightly build of the `develop` branch of this repository. |
147
176
|`cisagov/example:latest`| The most recent release image pushed to a container registry. Pulling an image using the `:latest` tag [should be avoided.](https://vsupalov.com/docker-latest-tag/) |
@@ -196,8 +225,7 @@ Build the image locally using this git repository as the [build context](https:/
0 commit comments