+ Use the helper script docker/create_new_docker_image.py
+
+
+❯ python docker/create_new_docker_image.py --help
+
+usage: create_new_docker_image.py [-h] [-t {python,powershell}] [-p {two,three}] [-l {alpine,debian}] [--pkg PKG] name
Create a new docker image
positional arguments:
- name The image name to use without the organization prefix.
- For example: ldap3. We use kebab-case naming
- convention.
+ name The image name to use without the organization prefix. For example: ldap3. We use kebab-case naming convention.
-optional arguments:
+options:
-h, --help show this help message and exit
-t {python,powershell}, --type {python,powershell}
Specify type of image to create (default: python)
-p {two,three}, --python {two,three}
Specify python version to use (default: three)
- -l {alpine,debian,ubuntu}, --linux {alpine,debian,ubuntu}
+ -l {alpine,debian}, --linux {alpine,debian}
Specify linux distro to use (default: alpine)
- --pkg PKG Specify a package/module to install. Can be specified
- multiple times. Each package needs to be specified
- with --pkg. For example: --pkg google-cloud-storage
- --pkg oath2client (default: None)
-```
+ --pkg PKG Specify a package to install. Can be specified multiple times. Each package needs to be specified with --pkg. For example: --pkg google-cloud-storage --pkg oath2client (default: None)
+
+
+ For example to create a new image named ldap
using Python 3 and with the Python package ldap3
run the following:
-For example to create a new image named ldap using python 3 and with the python package ldap3 run the following:
-```
+
./docker/create_new_docker_image.py -p three --pkg ldap3 ldap
-```
-The above command will create a directory `docker/ldap` with all relevant files all setup for building a docker image. You can now build the image locally by following: [Building Locally a Test Build](#building-locally-a-test-build).
+
+
+ The above command will create a directory `docker/ldap` with all relevant files all setup for building a docker image. You can now build the image locally by following: [Building Locally a Test Build](#building-locally-a-test-build).
+
+
+