reorganize goss-tests

This commit is contained in:
prilka 2019-08-03 14:07:27 +02:00
parent 177c0955be
commit 8a636a7f50
4 changed files with 5 additions and 5 deletions

2
.gitignore vendored
View file

@ -2,4 +2,4 @@
.\#*
\#*\#
.config/
goss.yaml
/goss.yaml

View file

@ -1,6 +1,8 @@
#!/bin/bash
set -e
cd $(dirname $0)
images=('alpine' 'debian')
if [ "$(docker version --format '{{.Server.Experimental}}')" = 'true' ]; then
@ -15,12 +17,10 @@ for image in "${images[@]}"; do
docker build -t $tag -f $image.Dockerfile .
echo "Testing image"
cp goss-default.yaml goss.yaml
dgoss run $tag
GOSS_FILES_PATH=./tests/default dgoss run $tag
echo "Testing again with UID and GID"
cp goss-uid-test.yaml goss.yaml
dgoss run -e UID=1001 -e GID=101 $tag
GOSS_FILES_PATH=./tests/uid-test dgoss run -e UID=1001 -e GID=101 $tag
done