* MOD: finalize test stage
build_and_push / build_and_push (push) Failing after 2s

Signed-off-by: Uwe Hermann <uh@uleenucks.de>
This commit is contained in:
2024-01-20 13:14:24 +01:00
parent e387a7b0b7
commit 7ae231a204
4 changed files with 27 additions and 21 deletions
+15
View File
@@ -0,0 +1,15 @@
---
name: build_and_push
on:
- push
jobs:
lint:
name: build_and_push
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install docker
run: curl -fsSL https://get.docker.com -o get-docker.sh | sh
- name: build_and_push
run: ./build-all.sh
-16
View File
@@ -1,16 +0,0 @@
---
name: tests
on:
- push
- pull_request
jobs:
lint:
name: check and test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install shellcheck
run: apt update && apt install -y shellcheck
- name: test
run: ./shellcheck.sh
+5 -5
View File
@@ -11,9 +11,9 @@ DOCKERFILESPATH="${HOME}/dockerfiles"
ERRORS="$(pwd)/errors" ERRORS="$(pwd)/errors"
dcleanup(){ dcleanup(){
${DOCKER} rm $(${DOCKER} ps -aq 2>/dev/null) 2>/dev/null "${DOCKER}" rm $("${DOCKER}" ps -aq 2>/dev/null) 2>/dev/null
${DOCKER} rm -v $(${DOCKER} ps --filter status=exited -q 2>/dev/null) 2>/dev/null "${DOCKER}" rm -v $("${DOCKER}" ps --filter status=exited -q 2>/dev/null) 2>/dev/null
${DOCKER} rmi $(${DOCKER} images --filter dangling=true -q 2>/dev/null) 2>/dev/null "${DOCKER}" rmi $("${DOCKER}" images --filter dangling=true -q 2>/dev/null) 2>/dev/null
} }
build_and_push_kaniko(){ build_and_push_kaniko(){
@@ -23,7 +23,7 @@ build_and_push_kaniko(){
echo "Building ${REPO_URL}/${base}:${suite} for context ${build_dir}" echo "Building ${REPO_URL}/${base}:${suite} for context ${build_dir}"
docker run \ docker run \
-v "${HOME}/config.json:/kaniko/.docker/config.json:ro" \ -v "$(pwd)/config.json:/kaniko/.docker/config.json:ro" \
-v "$(pwd)/${build_dir}:/workspace" \ -v "$(pwd)/${build_dir}:/workspace" \
gcr.io/kaniko-project/executor:debug \ gcr.io/kaniko-project/executor:debug \
--destination "${REPO_URL}/${base}:${suite}" --force \ --destination "${REPO_URL}/${base}:${suite}" --force \
@@ -92,6 +92,6 @@ run(){
fi fi
} }
prescript #prescript
run $@ run $@
dcleanup dcleanup
+7
View File
@@ -0,0 +1,7 @@
{
"auths": {
"https://index.docker.io/v1/": {
"auth": "$DOCKERAUTH"
}
}
}