Skip to content

Commit 1f81197

Browse files
Add awesome example (#24)
Signed-off-by: Jacob Tomlinson <[email protected]>
1 parent 379540a commit 1f81197

File tree

2 files changed

+40
-5
lines changed

2 files changed

+40
-5
lines changed

README.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@
77
A little bird to validate your container images.
88

99
```console
10-
$ canary validate --file somespec.yaml foo/bar:latest
11-
Validating foo/bar:latest against somespec
12-
📦 Required packages are installed [true]
13-
🤖 Expected services are running [true]
14-
🎉 Your container is awesome [true]
10+
$ canary validate --file examples/awesome.yaml your/container:latest
11+
Validating your/container:latest against awesome
12+
📦 Required packages are installed [passed]
13+
🤖 Expected services are running [passed]
14+
🎉 Your container is awesome [passed]
1515
validation passed
1616
```
1717

examples/awesome.yaml

+35
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
apiVersion: container-canary.nvidia.com/v1
2+
kind: Validator
3+
name: awesome
4+
description: A dummy example to show all containers are awesome
5+
command:
6+
- "sleep"
7+
- "30"
8+
checks:
9+
- name: packages
10+
description: 📦 Required packages are installed
11+
probe:
12+
exec:
13+
command:
14+
- /bin/sh
15+
- -c
16+
- "true"
17+
initialDelaySeconds: 1
18+
- name: services
19+
description: 🤖 Expected services are running
20+
probe:
21+
exec:
22+
command:
23+
- /bin/sh
24+
- -c
25+
- "true"
26+
initialDelaySeconds: 2
27+
- name: awesome
28+
description: 🎉 Your container is awesome
29+
probe:
30+
exec:
31+
command:
32+
- /bin/sh
33+
- -c
34+
- "true"
35+
initialDelaySeconds: 3

0 commit comments

Comments
 (0)