-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathcst.yml
More file actions
27 lines (27 loc) · 1.02 KB
/
cst.yml
File metadata and controls
27 lines (27 loc) · 1.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
schemaVersion: 2.0.0
metadataTest:
entrypoint: ["/docker-entrypoint.sh"]
cmd: ["nginx", "-g", "daemon off;"]
exposedPorts: ["8080"]
volumes: ["/var/log/nginx", "/var/run/nginx", "/var/cache/nginx"]
fileExistenceTests:
- name: 'nginx'
path: '/usr/sbin/nginx'
shouldExist: true
isExecutableBy: 'any'
- name: 'Nginx user home exists and is the cache directory'
path: '/var/cache/nginx'
shouldExist: true
- name: 'Nginx logs directory exists'
path: '/var/log/nginx'
shouldExist: true
fileContentTests:
- name: 'Default user nginx exists with the correct UID/GID'
path: '/etc/passwd'
expectedContents: ['.*nginx:x:.*:nginx:/var/cache/nginx:/sbin/nologin.*']
- name: 'Default nginx vhost listens on the unprivileged 8080 port for HTTP'
path: '/etc/nginx/conf.d/default.conf'
expectedContents: ['.*listen.*8080.*']
- name: 'Default nginx configuration writes pid file into the custom directory'
path: '/etc/nginx/nginx.conf'
expectedContents: ['.*pid.*/var/run/nginx/nginx.pid;.*']