22
33The Docker Management Container (or DMC for short) contains a number of plugins and services that are designed to make it easy to create, test, deploy and manage infrastructures. For more information also take a look at our [ Blog] ( https://blog.telekom-mms.com/tech-insights/manage-your-infrastructure-better-with-this-opensource-tool ) .
44
5- <!-- < picture>
5+ <picture >
66 <source
77 srcset="https://user-images.githubusercontent.com/3198961/186105564-3901aded-21f1-4191-b323-e943f49ea5ed.png "
88 media="(prefers-color-scheme: dark)"
99 width="30%" height="30%">
1010 <img width =" 30% " height =" 30% " src =" " >
11- </picture> -->
11+ </picture >
1212
1313## How does the DMC work?
1414
1515The DMC provides a Dockerfile template (from modular setup) that creates the Dockerfile with the desired tools and versions through a file and script. This Dockerfile is then used for the actual build of the container. The Dockerfile itself does not need to be kept, but is created and discarded after the build of the Dockerfile.
1616
1717The DMC uses the wakemeops as base setup, for more information about wakemeops look at the [ docs] ( https://docs.wakemeops.com/ ) .
1818
19- ### Try
19+ ### Try it out
2020
2121For a quick overview and test of the DMC, we have created images based on the [ minimal] ( examples/min_build.yaml ) and [ full] ( examples/full_build.yaml ) examples that can be used directly.
2222
@@ -34,202 +34,39 @@ docker run ghcr.io/telekom-mms/dmc:full
3434
3535Setup plugins, services, tools, versions and configuration over file with yaml syntax.
3636
37+ Create a build.yaml:
38+
3739``` bash
3840touch build.yaml
3941```
4042
41- #### Image
43+ Then fill it with the settings you need:
44+
45+ * [ Image] ( docs/usage/setup_and_configuration/image.md )
46+ * [ Base] ( docs/usage/setup_and_configuration/base.md )
47+ * [ Tools] ( docs/usage/setup_and_configuration/tools.md )
48+ * [ Tool Config] ( docs/usage/setup_and_configuration/tool_config.md )
49+ * [ Post Build Config] ( docs/usage/setup_and_configuration/post_build_config.md )
50+ * [ Tool Config] ( docs/usage/setup_and_configuration/tool_config.md )
51+
52+ Take a look at the examples to see what's possible:
4253
43- The DMC uses the wakemeops image as base image.
44-
45- ##### Image ARG
46-
47- * ` distribution `
48- * Required: no
49- * Default: ` ubuntu `
50- * Description: distribution that should be used, see also [ wakemeops] ( https://hub.docker.com/u/wakemeops )
51- * Examples:
52- * ``` yaml
53- distribution : debian
54- ` ` `
55-
56- * ` version`
57- * Required: no
58- * Default: `latest`
59- * Description: specific version
60- * Examples:
61- * ``` yaml
62- version : buster
63- ` ` `
64-
65- #### Base
66-
67- Basic Setup of the DMC.
68-
69- #### Tools
70-
71- Tools to be installed within the DMC.
72-
73- ##### Tools ARG
74-
75- * ` packages`
76- * Required: no
77- * Default:
78- * Description: list of packages to be installed
79- * Examples:
80- * ``` yaml
81- packages :
82- - ansible
83- - docker-ce
84- - helm
85- - kubectl
86- ` ` `
87-
88- * ` repositories`
89- * Required: no
90- * Default:
91- * Description: further repositories that should be used, currently the following are defined with defaults **_[hashicorp, docker, microsoft]_**
92- * Examples:
93- * ``` yaml
94- repositories :
95- docker : {}
96- microsoft : {}
97- hashicorp : {}
98- ` ` `
99- * ` ` ` yaml
100- repositories :
101- mongodb :
102- gpg : https://www.mongodb.org/static/pgp/server-6.0.asc
103- entry : https://repo.mongodb.org/apt/ubuntu focal/mongodb-org/6.0 multiverse
104- ` ` `
105-
106- * ` binaries`
107- * Required: no
108- * Default:
109- * Description: binaries that should be installed, currently the following are supported **_[github, google]_**
110- * Examples:
111- * ``` yaml
112- github :
113- - remotemobprogramming/mob=linux_amd64=v3.2.0
114- - derailed/k9s=Linux_x86_64
115- google :
116- - google-cloud-cli
117- ` ` `
118-
119- * ` repositories_hashicorp_gpg`
120- * Required: no
121- * Default: `https://apt.releases.hashicorp.com/gpg`
122-
123- * `repositories_hashicorp_entry`
124- * Required: no
125- * Default: `'https://apt.releases.hashicorp.com $(lsb_release -cs) main'`
126-
127- * `repositories_docker_gpg`
128- * Required: no
129- * Default: `https://download.docker.com/linux/ubuntu/gpg`
130-
131- * `repositories_docker_entry`
132- * Required: no
133- * Default: `'https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable'`
134-
135- * `repositories_microsoft_gpg`
136- * Required: no
137- * Default: `https://packages.microsoft.com/keys/microsoft.asc`
138-
139- * `repositories_microsoft_entry`
140- * Required: no
141- * Default: `'https://packages.microsoft.com/repos/azure-cli/ $(lsb_release -cs) main'`
142-
143- * `binaries_github_uri`
144- * Required: no
145- * Default: `https://api.github.com/repos`
146-
147- * `binaries_google_uri`
148- * Required: no
149- * Default: `https://packages.cloud.google.com/apt/dists/cloud-sdk/main/binary-arm64/Packages`
150-
151- # ### Tool Config
152-
153- Extension of installed tools.
154-
155- # #### Tool Config ARG
156-
157- * `requirements`
158- * Required: no
159- * Default:
160- * Description: requirements that should be installed for the used tools, currently the following are supported **_[pip, ansible(roles, collections)]_**
161- * Examples:
162- * ``` yaml
163- requirements :
164- pip :
165- packages :
166- - awsume
167- requirements :
168- - https://raw.githubusercontent.com/ansible-collections/azure/v1.15.0/requirements-azure.txt
169- ansible :
170- roles :
171- - telekom_mms.grafana
172- collections :
173- - telekom_mms.acme=2.3.1
174- - telekom_mms.icinga_director=1.28.0
175- requirements :
176- - https://raw.githubusercontent.com/T-Systems-MMS/ansible-role-maxscale/master/requirements.yml
177- ` ` `
178-
179- * ` extensions`
180- * Required: no
181- * Default:
182- * Description: extensions that should be installed for the used tools, currently the following are supported **_[az, google, helm]_**
183- * Examples:
184- * ``` yaml
185- extensions :
186- az :
187- - front-door=1.0.15
188- google :
189- - gsutil
190- - gke-gcloud-auth-plugin
191- - kubectl
192- helm :
193- - https://github.com/databus23/helm-diff=3.5.0
194- - https://github.com/jkroepke/helm-secrets
195- ` ` `
196-
197- #### Post Build Config
198-
199- System configuration and further setups to finish the DMC build.
200-
201- ##### Post Build Config ARG
202-
203- * ` profiles`
204- * Required: no
205- * Default:
206- * Description: configuration for profile settings
207- * Examples:
208- * ``` yaml
209- profiles :
210- .vimrc :
211- - filetype on
212- .bash_aliases :
213- - alias ll='ls -la'
214- ` ` `
215-
216- * ` post_build_commands`
217- * Required: no
218- * Default:
219- * Description: commands to run after the image build to finish the setup
220- * Examples:
221- * ``` yaml
222- post_build_commands :
223- - awsume-configure
224- ` ` `
225-
226- ### Build Dockerfile
227-
228- To create the Dockerfile from Template you have simply to run the following steps.
229-
230- 1. create build.yaml with your needed settings
231- 2. run the script ` render.sh`
232- 3. build Docker Image
54+ ## Examples
55+
56+ Examples for the ` build.yaml ` could be found under [ examples] ( examples ) :
57+
58+ * [ minimal] ( examples/min_build.yaml )
59+ * [ full] ( examples/full_build.yaml )
60+
61+ ### Build
62+
63+ #### Dockerfile
64+
65+ To create the Dockerfile from Template you have to run the following steps.
66+
67+ 1 . Create ` build.yaml ` with your needed settings
68+ 2 . Run the script ` render.sh `
69+ 3 . Build the Docker Image
23370
23471` render.sh `
23572
@@ -239,7 +76,7 @@ The build script will create the `Dockerfile` from template.d with your settings
23976sh render.sh .
24077```
24178
242- # ## Build Image
79+ #### Image
24380
24481``` bash
24582docker image build -t dmc:latest .
@@ -261,18 +98,7 @@ Provided build presets can be found under [pipeline](pipeline). The preset also
26198}
26299```
263100
264- # #### [gitlab-ci](pipeline/gitlab-ci.yml)
265-
266- # #### Inputs
267-
268- | variable | description | default |
269- | --- | --- | --- |
270- | GITHUB_DMC_TAG | version of the dmc release | latest version |
271- | DMC_NAME | name of the container | dmc |
272- | DMC_IMAGE | full image name | `$CI_REGISTRY_IMAGE/${DMC_NAME}` |
273-
274- The preset needs a `.docker-login`-extend. In it you have to define your docker registry information.
275- To include the preset see [gitlab-ci](examples/pipeline/gitlab-ci.yml)
101+ * [ gitlab-ci] ( docs/build/image/preset/gitlab-ci.md )
276102
277103### Run Image
278104
@@ -352,7 +178,8 @@ We provide a [renovate-preset](https://docs.renovatebot.com/key-concepts/presets
352178If you use it renovate can update the versions in your ` build.yaml `
353179
354180Include it like this:
355- ```
181+
182+ ``` json
356183{
357184 "$schema" : " https://docs.renovatebot.com/renovate-schema.json" ,
358185 "extends" : [
@@ -364,7 +191,7 @@ Include it like this:
364191
365192Change your ` build.yaml ` like this to use it:
366193
367- ```
194+ ``` yaml
368195packages :
369196 # renovate: datasource=repology depName=ubuntu_22_04/ansible versioning=loose
370197 - ansible=2.10.7+merged+base+2.10.8+dfsg-1
@@ -375,7 +202,6 @@ packages:
375202 - telekom_mms.acme=2.3.1
376203` ` `
377204
378-
379205## Migration
380206
381207With Version 2.0.0 there's a breaking change in the configuration and usage of the DMC.
@@ -387,13 +213,6 @@ To support the migration we provide a script to migrate from the old .docker_bui
387213sh migrate.sh .
388214` ` `
389215
390- ## Examples
391-
392- Examples for the ` build.yaml ` could be found under [ examples] ( examples ) :
393-
394- * [ minimal] ( examples/min_build.yaml )
395- * [ full] ( examples/full_build.yaml )
396-
397216# # Others
398217
399218Feedback, suggestions for improvement and expansion, and of course collaboration are expressly desired.
0 commit comments