Skip to content

Commit 5c6680b

Browse files
author
Natalie Arellano
committed
WIP
Signed-off-by: Natalie Arellano <[email protected]>
1 parent 4d0434e commit 5c6680b

File tree

2 files changed

+86
-5
lines changed

2 files changed

+86
-5
lines changed
Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
+++
2+
title="The finer points of image extensions"
3+
weight=406
4+
+++
5+
6+
TODO - move this to extension-guide/conventions?
7+
8+
# Guidance for extension authors
9+
10+
## During detect
11+
12+
### Expressing provided dependencies through the build plan
13+
14+
### Configuring build args
15+
16+
```
17+
├── bin
18+
│ ├── detect
19+
├── generate
20+
│ ├── build.Dockerfile
21+
│ ├── run.Dockerfile
22+
│ ├── extend-config.toml
23+
├── extension.toml
24+
```
25+
26+
## During generate
27+
28+
### Re-setting the user/group with build args
29+
30+
### Invalidating the build cache with the UUID build arg
31+
32+
### Making 'rebasable' changes
33+
34+
## In general
35+
36+
### Choosing an extension ID
37+
38+
### Expressing information in extension.toml
39+
40+
### Pre-populating output
41+
42+
The root directory for a typical extension might look like the following:
43+
44+
```
45+
.
46+
├── bin
47+
│ ├── detect <- similar to a buildpack ./bin/detect
48+
│ ├── generate <- similar to a buildpack ./bin/build
49+
├── extension.toml <- similar to a buildpack buildpack.toml
50+
```
51+
52+
But it could also look like any of the following:
53+
54+
#### ./bin/detect is optional!
55+
56+
```
57+
.
58+
├── bin
59+
│ ├── generate
60+
├── detect
61+
│ ├── plan.toml
62+
├── extension.toml
63+
```
64+
65+
#### ./bin/generate is optional!
66+
67+
```
68+
├── bin
69+
│ ├── detect
70+
├── generate
71+
│ ├── build.Dockerfile
72+
│ ├── run.Dockerfile
73+
├── extension.toml
74+
```
75+
76+
#### It's all optional!
77+
78+
```
79+
├── detect
80+
│ ├── plan.toml
81+
├── generate
82+
│ ├── build.Dockerfile
83+
│ ├── run.Dockerfile
84+
├── extension.toml
85+
```

content/docs/extension-guide/create-extension/building-blocks-extension.md

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,9 @@ You should see something akin to the following:
3838
* Only a limited set of Dockerfile instructions is supported - consult
3939
the [spec](https://github.com/buildpacks/spec/blob/main/image_extension.md)
4040
for further details.
41-
* In the [initial implementation](/docs/features/dockerfiles#phased-approach), `run.Dockerfile` instructions are
42-
limited to a single `FROM` instruction (effectively, it is only possible to switch the run-time base image to a
43-
pre-created image i.e., no dynamic image modification is allowed). Consult
44-
the [spec](https://github.com/buildpacks/spec/blob/main/image_extension.md)
45-
for further details.
4641

4742
We'll take a closer look at the executables for the `vim` extension in the next step.
43+
For guidance around writing extensions and more advanced use cases, see [here](/docs/extension-guide/create-extension/advanced-extensions).
4844

4945
<!--+ if false+-->
5046
---

0 commit comments

Comments
 (0)