Skip to content

Commit fe0075e

Browse files
authored
Change the default image command to hello (#6)
1 parent b14ddd8 commit fe0075e

File tree

3 files changed

+18
-9
lines changed

3 files changed

+18
-9
lines changed

.github/workflows/ci.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,4 +55,4 @@ jobs:
5555
docker image ls -a
5656
5757
- name: Test image
58-
run: ./run.sh hello
58+
run: ./run.sh

Dockerfile

+3
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,6 @@ RUN uv sync --frozen
1818

1919
# Place executables in the environment at the front of the path
2020
ENV PATH="/app/.venv/bin:$PATH"
21+
22+
# Set the default command to the application
23+
CMD ["hello"]

README.md

+14-8
Original file line numberDiff line numberDiff line change
@@ -11,29 +11,35 @@ A [`run.sh`](./run.sh) utility is provided for quickly building the image and st
1111
This script demonstrates best practices for developing using the container, using bind mounts for
1212
the project and virtual environment directories.
1313

14-
To run the application in a container:
14+
To run the application in the container:
1515

1616
```console
17-
$ ./run.sh hello
17+
$ ./run.sh
1818
```
1919

20-
To enter a Python REPL in a container:
20+
To run the application in the container, checking if the environment is up-to-date first:
2121

2222
```console
23-
$ ./run.sh
23+
$ ./run.sh uv run hello
24+
```
25+
26+
To check that the environment is up-to-date:
27+
28+
```console
29+
$ ./run.sh uv sync --frozen
30+
Audited 2 packages ...
2431
```
2532

26-
To enter a `bash` shell in a container:
33+
To enter a `bash` shell in the container:
2734

2835
```console
2936
$ ./run.sh /bin/bash
3037
```
3138

32-
To check that the environment is up-to-date:
39+
To build the image without running anything:
3340

3441
```console
35-
$ ./run.sh uv sync --frozen
36-
Audited 2 packages ...
42+
$ docker build .
3743
```
3844

3945
## Project overview

0 commit comments

Comments
 (0)