diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md deleted file mode 100644 index 4821f66..0000000 --- a/.github/ISSUE_TEMPLATE.md +++ /dev/null @@ -1,38 +0,0 @@ -[linuxserverurl]: https://linuxserver.io -[![linuxserver.io](https://raw.githubusercontent.com/linuxserver/docker-templates/master/linuxserver.io/img/linuxserver_medium.png)][linuxserverurl] - - - - - - - - ------------------------------- - -## Expected Behavior - - -## Current Behavior - - -## Steps to Reproduce - - -1. -2. -3. -4. - -## Environment -**OS:** -**CPU architecture:** x86_64/arm32/arm64 -**How docker service was installed:** - - - -## Command used to create docker container (run/create/compose/screenshot) - - -## Docker logs - diff --git a/Jenkinsfile b/Jenkinsfile index 3bd4cd3..d782716 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -549,7 +549,7 @@ pipeline { ''' } sh '''#! /bin/bash - for DELETEIMAGE in "${GITHUBIMAGE}" "{GITLABIMAGE}" "${IMAGE}"; do + for DELETEIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${IMAGE}"; do docker rmi \ ${DELETEIMAGE}:${META_TAG} \ ${DELETEIMAGE}:${EXT_RELEASE_TAG} \ diff --git a/roles/generate-jenkins/templates/EXTERNAL_TRIGGER.j2 b/roles/generate-jenkins/templates/EXTERNAL_TRIGGER.j2 index 347fd0b..76d7339 100644 --- a/roles/generate-jenkins/templates/EXTERNAL_TRIGGER.j2 +++ b/roles/generate-jenkins/templates/EXTERNAL_TRIGGER.j2 @@ -74,6 +74,7 @@ jobs: "username": "Github Actions"}' ${{ '{{' }} secrets.DISCORD_WEBHOOK {{ '}}' }} exit 1 fi + EXT_RELEASE=$(echo ${EXT_RELEASE} | sed 's/[~,%@+;:/]//g') echo "**** External version: ${EXT_RELEASE} ****" echo "**** Retrieving last pushed version ****" image="{{ better_vars.LS_USER }}/{{ project_name }}" diff --git a/roles/generate-jenkins/templates/Jenkinsfile.j2 b/roles/generate-jenkins/templates/Jenkinsfile.j2 index 79482a0..ac633c2 100644 --- a/roles/generate-jenkins/templates/Jenkinsfile.j2 +++ b/roles/generate-jenkins/templates/Jenkinsfile.j2 @@ -616,6 +616,15 @@ pipeline { environment name: 'EXIT_STATUS', value: '' } steps { +{% if not project_repo_name == "docker-jenkins-builder" and "docker-baseimage" not in project_repo_name %} + sh '''#! /bin/bash + echo "Packages were updated. Cleaning up the image and exiting." + if [ "${MULTIARCH}" == "true" ]; then + docker rmi ${IMAGE}:amd64-${META_TAG} + else + docker rmi ${IMAGE}:${META_TAG} + fi''' +{% endif %} script{ env.EXIT_STATUS = 'ABORTED' } @@ -633,6 +642,15 @@ pipeline { } } steps { +{% if not project_repo_name == "docker-jenkins-builder" and "docker-baseimage" not in project_repo_name %} + sh '''#! /bin/bash + echo "There are no package updates. Cleaning up the image and exiting." + if [ "${MULTIARCH}" == "true" ]; then + docker rmi ${IMAGE}:amd64-${META_TAG} + else + docker rmi ${IMAGE}:${META_TAG} + fi''' +{% endif %} script{ env.EXIT_STATUS = 'ABORTED' } @@ -723,7 +741,7 @@ pipeline { ''' } sh '''#! /bin/bash - for DELETEIMAGE in "${GITHUBIMAGE}" "{GITLABIMAGE}" "${IMAGE}"; do + for DELETEIMAGE in "${GITHUBIMAGE}" "${GITLABIMAGE}" "${IMAGE}"; do docker rmi \ ${DELETEIMAGE}:${META_TAG} \ ${DELETEIMAGE}:${EXT_RELEASE_TAG} \