@@ -15,25 +15,20 @@ one of 3 cases based on the parameter you pass in:
15152 . ` ./dev.sh run ` runs the main application.
16163 . ` ./dev.sh cli ` drops you into the cli for the image
1717
18- ## :hourglass_flowing_sand : Migration to version 4
19-
20- The version 4 comes with significant changes:
21-
22- * The docker base image was changed from alpine to slim buster
23- * All the ` apk add ` commands need to be replaced with equivalent ` apt-get ` commands
24- * slim buster has more base packages such as bash so probably less installation
25- of system packages is needed
26- * The entrypoint now provides standard commands to run and test the webapp
27- * No ` CMD ` is necessary for production as ` startapp ` is the default
28- * In development, run the ` developapp ` command
29- * See below for testing
30- * A ` config.sh ` is expected where environment variables for configuration purposes
31- can be defined
32- * The ` requirements.txt ` has been reduced to the base and development python packages
33- * Base packages such as FastAPI, pydantic, loguru, ...
34- * Development pacakages such as watchmedo, pytest, mypy, ...
35- * Therefore you need to add to your requirements file packages such as pandas
36- that were included in this image in versions prior to 4
18+ ## :hourglass_flowing_sand : Migration from version 202205 to above
19+
20+ Starting with the version 202207, the docker python base does not contain
21+ any preinstalled python packages. It is now just providing a folder structure
22+ with adequate permissions for the python user, and a standard test suite.
23+
24+ As a consequence upgrading to version 202207 and latest requires to
25+ add the packages that used to be provided by the docker python base image.
26+ The list of packages in listed in the
27+ [ removed-packages.txt] ( ./removed-packages.txt ) file.
28+
29+ The docker python base test image uses now poetry as it is the preferred
30+ way to manage dependencies at Satel. It can be used as an example
31+ on how to use poetry while building a python app image.
3732
3833## :open_file_folder : Folder structure
3934
@@ -51,19 +46,11 @@ such as the `entrypoint.sh`. Then the subfolders organize the app files:
5146
52471 . Go to docker hub to get the latest patch version for
5348 the [ python docker image] ( https://hub.docker.com/_/python/ )
54- 2 . Then 3 files need to be edited with the latest python minor or patch versions:
55- 1 . ` docker-compose.generate_requirements.yml ` to generate the requirements files.
49+ 2 . Then 2 files need to be edited with the latest python minor or patch versions:
5650 1 . ` .github/workflows/docker_image.yml ` to build and push the right images to docker hub.
57- 1 . ` Dockerfile ` to change the default base image version. This is used only for testing
58- while developing but better to keep it up to date.
59-
60- ### Upgrade the requirements files
61-
62- Rather simple. Just run the following command at the root of the repo:
63-
64- ``` bash
65- docker-compose -f docker-compose.generate_requirements.yml up
66- ```
51+ 1 . ` Dockerfile ` at the root (not the one in ` /tests ` ) to change the default
52+ base image version. This is used only for testing while developing but
53+ better to keep it up to date.
6754
6855## :keyboard : Commands
6956
0 commit comments