mirror of
https://github.com/bitnami/containers.git
synced 2026-03-29 08:17:42 +08:00
[bitnami/osclass] Add VIB tests (#33417)
Signed-off-by: Marcos Bjoerkelund <marcosbd@vmware.com>
This commit is contained in:
committed by
GitHub
parent
40ec94d4ec
commit
eb2955a86e
13
.vib/osclass/goss/goss.yaml
Normal file
13
.vib/osclass/goss/goss.yaml
Normal file
@@ -0,0 +1,13 @@
|
||||
gossfile:
|
||||
# Goss tests exclusive to the current container
|
||||
../../osclass/goss/osclass.yaml: {}
|
||||
# Load scripts from .vib/common/goss/templates
|
||||
../../common/goss/templates/check-apache-libphp.yaml: {}
|
||||
../../common/goss/templates/check-binaries.yaml: {}
|
||||
../../common/goss/templates/check-broken-symlinks.yaml: {}
|
||||
../../common/goss/templates/check-ca-certs.yaml: {}
|
||||
../../common/goss/templates/check-directories.yaml: {}
|
||||
../../common/goss/templates/check-files.yaml: {}
|
||||
../../common/goss/templates/check-linked-libraries.yaml: {}
|
||||
../../common/goss/templates/check-sed-in-place.yaml: {}
|
||||
../../common/goss/templates/check-spdx.yaml: {}
|
||||
35
.vib/osclass/goss/osclass.yaml
Normal file
35
.vib/osclass/goss/osclass.yaml
Normal file
@@ -0,0 +1,35 @@
|
||||
command:
|
||||
check-app-version:
|
||||
exec: grep "'version'\s*=>" /opt/bitnami/osclass/oc-content/languages/en_US/index.php
|
||||
exit-status: 0
|
||||
stdout:
|
||||
- "{{ .Env.APP_VERSION }}"
|
||||
check-enabled-modules:
|
||||
exec: php -m
|
||||
exit-status: 0
|
||||
stdout:
|
||||
{{ range $module := .Vars.phpmodules }}
|
||||
- "{{ $module }}"
|
||||
{{ end }}
|
||||
file:
|
||||
# HTTP vhost should have been properly rendered
|
||||
/opt/bitnami/apache/conf/vhosts/osclass-vhost.conf:
|
||||
exists: true
|
||||
filetype: file
|
||||
contains:
|
||||
- /DocumentRoot.*/opt/bitnami/osclass/
|
||||
- 'RewriteRule "^/oc-admin$"'
|
||||
# HTTPS vhost should have been properly rendered
|
||||
/opt/bitnami/apache/conf/vhosts/osclass-https-vhost.conf:
|
||||
exists: true
|
||||
filetype: file
|
||||
contains:
|
||||
- "SSLEngine on"
|
||||
- /DocumentRoot.*/opt/bitnami/osclass/
|
||||
- 'RewriteRule "^/oc-admin$"'
|
||||
group:
|
||||
daemon:
|
||||
exists: true
|
||||
user:
|
||||
daemon:
|
||||
exists: true
|
||||
19
.vib/osclass/goss/vars.yaml
Normal file
19
.vib/osclass/goss/vars.yaml
Normal file
@@ -0,0 +1,19 @@
|
||||
binaries:
|
||||
- apachectl
|
||||
- mariadb
|
||||
- php
|
||||
- render-template
|
||||
directories:
|
||||
- mode: "0775"
|
||||
paths:
|
||||
- /bitnami/osclass
|
||||
- /opt/bitnami/osclass
|
||||
- /opt/bitnami/osclass/oc-content
|
||||
files:
|
||||
- paths: []
|
||||
phpmodules:
|
||||
# Based on Requirements section from https://osclass-classifieds.com/download
|
||||
# Required
|
||||
- mysqli
|
||||
- gd
|
||||
root_dir: /opt/bitnami
|
||||
Reference in New Issue
Block a user