Skip to content

Commit 0f139a3

Browse files
authored
docs: adding guide for packaging devfile (#83)
Signed-off-by: Michael Hoang <[email protected]>
1 parent caac377 commit 0f139a3

File tree

4 files changed

+90
-0
lines changed

4 files changed

+90
-0
lines changed
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
---
2+
title: Packaging devfile
3+
description: Packaging devfile
4+
---
5+
6+
## Creating a devfile
7+
8+
To create a devfile, you can [start from scratch](./create-devfiles-with-templates) or use the [public community devfile registry](https://registry.devfile.io/viewer) to find predefined stacks for popular languages and frameworks. Once you have a devfile, save it as `.devfile.yaml` to your application’s root directory.
9+
10+
## Resources to include with your devfile
11+
12+
If the devfile contains outerloop support, make sure the required files are included in your application with the correct path. Some common examples include:
13+
14+
* The devfile contains an image component that uses a `Dockerfile`:
15+
```yaml
16+
components:
17+
- name: outerloop-build
18+
image:
19+
imageName: image:latest
20+
dockerfile:
21+
uri: docker/Dockerfile
22+
```
23+
24+
* The devfile contains a deploy component:
25+
```yaml
26+
components:
27+
- name: outerloop-deploy
28+
kubernetes:
29+
uri: kubernetes/deploy.yaml
30+
```
31+
32+
If the devfile was created using the [public community devfile registry](https://registry.devfile.io/viewer), visit the [source directory on Github](https://github.com/devfile/registry/tree/main/stacks) to get the required files.
33+
34+
{% callout title="Note!" %}
35+
Check out the [devfile schema](./devfile-schema) for supported components.
36+
{% /callout %}
37+
38+
39+
## Additional resources
40+
41+
- For more information about working with devfiles, go to [How to work with devfiles](./how-to-work-with-devfiles).
42+
43+
- For more information about outerloop, go to [Innerloop versus outerloop](./innerloop-vs-outerloop).
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
---
2+
title: Packaging devfile
3+
description: Packaging devfile
4+
---
5+
6+
## Creating a devfile
7+
8+
To create a devfile, you can [start from scratch](./create-devfiles-with-templates) or use the [public community devfile registry](https://registry.devfile.io/viewer) to find predefined stacks for popular languages and frameworks. Once you have a devfile, save it as `.devfile.yaml` to your application’s root directory.
9+
10+
## Resources to include with your devfile
11+
12+
If the devfile contains outerloop support, make sure the required files are included in your application with the correct path. Some common examples include:
13+
14+
* The devfile contains an image component that uses a `Dockerfile`:
15+
```yaml
16+
components:
17+
- name: outerloop-build
18+
image:
19+
imageName: image:latest
20+
dockerfile:
21+
uri: docker/Dockerfile
22+
```
23+
24+
* The devfile contains a deploy component:
25+
```yaml
26+
components:
27+
- name: outerloop-deploy
28+
kubernetes:
29+
uri: kubernetes/deploy.yaml
30+
```
31+
32+
If the devfile was created using the [public community devfile registry](https://registry.devfile.io/viewer), visit the [source directory on Github](https://github.com/devfile/registry/tree/main/stacks) to get the required files.
33+
34+
{% callout title="Note!" %}
35+
Check out the [devfile schema](./devfile-schema) for supported components.
36+
{% /callout %}
37+
38+
39+
## Additional resources
40+
41+
- For more information about working with devfiles, go to [How to work with devfiles](./how-to-work-with-devfiles).
42+
43+
- For more information about outerloop, go to [Innerloop versus outerloop](./innerloop-vs-outerloop).

libs/docs/src/navigation/2.2.0.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,8 @@
6666
href: ./create-devfiles-with-templates
6767
- title: Innerloop versus outerloop
6868
href: ./innerloop-vs-outerloop
69+
- title: Packaging devfile
70+
href: ./packaging-devfile
6971
- title: API reference
7072
links:
7173
- title: Devfile schema

libs/docs/src/navigation/2.2.1-alpha.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,8 @@
6666
href: ./create-devfiles-with-templates
6767
- title: Innerloop versus outerloop
6868
href: ./innerloop-vs-outerloop
69+
- title: Packaging devfile
70+
href: ./packaging-devfile
6971
- title: API reference
7072
links:
7173
- title: Devfile schema

0 commit comments

Comments
 (0)