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: docs/development.md
+65-34Lines changed: 65 additions & 34 deletions
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@
4
4
5
5
### Folder structure
6
6
7
-
The top level folder with the docker files is `release`.
7
+
The top level folder with the `Dockerfile`s is `release`.
8
8
This should only have folders under it.
9
9
The three folders are:
10
10
@@ -17,43 +17,17 @@ The name of the folder will be the name of the image in the build system, but do
17
17
For example, the `stable` Ubuntu 16.04 image is in `release/stable/ubuntu16.04`.
18
18
In this folder, there are 4 items:
19
19
20
-
*`docker` - a folder containing the `Dockerfile` to build the image and any other files needed in the Docker build context
21
-
*`meta.json` - This is required for Linux images. It should contain the following:
22
-
23
-
```json
24
-
{
25
-
"IsLinux" : true,
26
-
"tagTemplates": [
27
-
"my-tag",
28
-
"my-other-tag"
29
-
]
30
-
}
31
-
```
32
-
33
-
Tags are a JSON array that describes the tags the image should have.
34
-
35
-
Tags you can use:
36
-
*`#psversion#` is replaced by the version of PowerShell used to build the image.
37
-
*`#tag#` is replaced by all tags generated by the `getLatestTag.ps1` script.
38
-
*`#shorttag#` is replaced by short tags generated by the `getLatestTag.ps1` script.
39
-
*`#longtag#` is replaced by long tags generated by the `getLatestTag.ps1` script.
40
-
41
-
Example
42
-
43
-
```json
44
-
"tagTemplates": [
45
-
"#psversion#-windowsservercore-#tag#",
46
-
"windowsservercore-#tag#"
47
-
]
48
-
```
49
-
20
+
*`docker` - A folder containing the `Dockerfile` to build the image and any other files needed in the Docker build context.
21
+
*`test-deps` (official images only) - Directory for a sub-image. See the [`test-deps` image purpose](./index.md#test-dep-images).
22
+
*`dependabot` (optional) - in this directory you can put a dummy `Dockerfile` for [Dependabot](https://dependabot.com) to auto-bump the version. See [Dependabot](#dependabot).
23
+
*`meta.json` - See [this section](#metadata-files) later.
50
24
*`getLatestTag.ps1` - This script should use the `Get-DockerTags` command from `tools\getDockerTags` to get the tags that should be used as the tag in the `FROM` statement in the Dockerfile.
51
25
52
-
### Dockerfile Standards
26
+
### `Dockerfile` Standards
53
27
54
-
The Dockerfile should follow certain standards:
28
+
All `Dockerfile`s should follow certain standards:
55
29
56
-
* The following comments should be applied at the beginning of the dockerfile to all images:
30
+
* The following comments should be applied at the beginning of the `Dockerfile`:
57
31
58
32
* Copyright notice
59
33
* Software license
@@ -146,3 +120,60 @@ Here is a template for an image build job:
146
120
communityStable: true
147
121
continueonerror: false
148
122
```
123
+
124
+
## Tags
125
+
126
+
Tags are a JSON array that describes the tags the image should have.
127
+
128
+
### Supported Tags
129
+
130
+
Tags you can use:
131
+
132
+
* `#psversion#` is replaced by the version of PowerShell used to build the image.
133
+
* `#tag#` is replaced by all tags generated by the `getLatestTag.ps1` script.
134
+
* `#shorttag#` is replaced by short tags generated by the `getLatestTag.ps1` script.
135
+
136
+
### Example
137
+
138
+
```json
139
+
"tagTemplates": [
140
+
"#psversion#-windowsservercore-#tag#",
141
+
"windowsservercore-#tag#"
142
+
]
143
+
```
144
+
145
+
## Metadata Files
146
+
147
+
This file *is **required*** for all containers. Here is the bare minimum:
148
+
149
+
```json
150
+
{
151
+
"IsLinux" : true
152
+
}
153
+
```
154
+
155
+
You should also add [tags](#tags) as a field.
156
+
157
+
## Dependabot
158
+
159
+
This repository has [Dependabot](https://dependabot.com) enabled on it.
160
+
161
+
The PRs opened for automatic base-image-version bumps will be closed, but the version will most likely get increased.
162
+
163
+
### Adding to a new Image
164
+
165
+
You will need to put a `Dockerfile` in the `dependabot` directory of your image, simply containing:
166
+
167
+
```dockerfile
168
+
FROM my-base-image:1.0.0
169
+
```
170
+
171
+
You will also need to add an entry in the `/.dependabot/config.yml` file. Here is a template for that:
0 commit comments