kopia lustrzana https://github.com/linuxserver/docker-cloud9
rodzic
d99aaae0de
commit
1c840b3554
|
@ -18,7 +18,7 @@ jobs:
|
|||
fi
|
||||
echo "**** External trigger running off of master branch. To disable this trigger, set a Github secret named \"PAUSE_EXTERNAL_TRIGGER_CLOUD9_MASTER\". ****"
|
||||
echo "**** Retrieving external version ****"
|
||||
EXT_RELEASE=$(curl -u "${{ secrets.CR_USER }}:${{ secrets.CR_PAT }}" -sX GET "https://api.github.com/repos/linuxserver/docker-docker-compose/releases/latest" | jq -r '. | .tag_name')
|
||||
EXT_RELEASE=$(curl -u ${{ secrets.CR_USER }}:${{ secrets.CR_PAT }} -sX GET https://api.github.com/repos/linuxserver/docker-docker-compose/releases/latest | jq -r '.tag_name' | sed 's|-ls.*||')
|
||||
if [ -z "${EXT_RELEASE}" ] || [ "${EXT_RELEASE}" == "null" ]; then
|
||||
echo "**** Can't retrieve external version, exiting ****"
|
||||
FAILURE_REASON="Can't retrieve external version for cloud9 branch master"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
ARG COMPOSE_VERSION="latest"
|
||||
ARG COMPOSE_VERSION="1.29.2"
|
||||
|
||||
# docker compose
|
||||
FROM ghcr.io/linuxserver/docker-compose:amd64-${COMPOSE_VERSION} as compose
|
||||
FROM ghcr.io/linuxserver/docker-compose:amd64-version-${COMPOSE_VERSION} as compose
|
||||
|
||||
# runtime stage
|
||||
FROM ghcr.io/linuxserver/baseimage-cloud9:latest
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
ARG COMPOSE_VERSION="latest"
|
||||
ARG COMPOSE_VERSION="1.29.2"
|
||||
|
||||
# docker compose
|
||||
FROM ghcr.io/linuxserver/docker-compose:arm64v8-${COMPOSE_VERSION} as compose
|
||||
FROM ghcr.io/linuxserver/docker-compose:arm64v8-version-${COMPOSE_VERSION} as compose
|
||||
|
||||
# runtime stage
|
||||
FROM ghcr.io/linuxserver/baseimage-cloud9:arm64v8-latest
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
ARG COMPOSE_VERSION="latest"
|
||||
ARG COMPOSE_VERSION="1.29.2"
|
||||
|
||||
# docker compose
|
||||
FROM ghcr.io/linuxserver/docker-compose:arm32v7-${COMPOSE_VERSION} as compose
|
||||
FROM ghcr.io/linuxserver/docker-compose:arm32v7-version-${COMPOSE_VERSION} as compose
|
||||
|
||||
# runtime stage
|
||||
FROM ghcr.io/linuxserver/baseimage-cloud9:arm32v7-latest
|
||||
|
|
|
@ -101,21 +101,14 @@ pipeline {
|
|||
/* ########################
|
||||
External Release Tagging
|
||||
######################## */
|
||||
// If this is a stable github release use the latest endpoint from github to determine the ext tag
|
||||
stage("Set ENV github_stable"){
|
||||
// If this is a custom command to determine version use that command
|
||||
stage("Set tag custom bash"){
|
||||
steps{
|
||||
script{
|
||||
env.EXT_RELEASE = sh(
|
||||
script: '''curl -H "Authorization: token ${GITHUB_TOKEN}" -s https://api.github.com/repos/${EXT_USER}/${EXT_REPO}/releases/latest | jq -r '. | .tag_name' ''',
|
||||
script: ''' curl -sX GET https://api.github.com/repos/linuxserver/docker-docker-compose/releases/latest | jq -r '.tag_name' | sed 's|-ls.*||' ''',
|
||||
returnStdout: true).trim()
|
||||
}
|
||||
}
|
||||
}
|
||||
// If this is a stable or devel github release generate the link for the build message
|
||||
stage("Set ENV github_link"){
|
||||
steps{
|
||||
script{
|
||||
env.RELEASE_LINK = 'https://github.com/' + env.EXT_USER + '/' + env.EXT_REPO + '/releases/tag/' + env.EXT_RELEASE
|
||||
env.RELEASE_LINK = 'custom_command'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -800,11 +793,11 @@ pipeline {
|
|||
"tagger": {"name": "LinuxServer Jenkins","email": "jenkins@linuxserver.io","date": "'${GITHUB_DATE}'"}}' '''
|
||||
echo "Pushing New release for Tag"
|
||||
sh '''#! /bin/bash
|
||||
curl -H "Authorization: token ${GITHUB_TOKEN}" -s https://api.github.com/repos/${EXT_USER}/${EXT_REPO}/releases/latest | jq '. |.body' | sed 's:^.\\(.*\\).$:\\1:' > releasebody.json
|
||||
echo "Updating to ${EXT_RELEASE_CLEAN}" > releasebody.json
|
||||
echo '{"tag_name":"'${META_TAG}'",\
|
||||
"target_commitish": "master",\
|
||||
"name": "'${META_TAG}'",\
|
||||
"body": "**LinuxServer Changes:**\\n\\n'${LS_RELEASE_NOTES}'\\n\\n**'${EXT_REPO}' Changes:**\\n\\n' > start
|
||||
"body": "**LinuxServer Changes:**\\n\\n'${LS_RELEASE_NOTES}'\\n\\n**Remote Changes:**\\n\\n' > start
|
||||
printf '","draft": false,"prerelease": false}' >> releasebody.json
|
||||
paste -d'\\0' start releasebody.json > releasebody.json.done
|
||||
curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/releases -d @releasebody.json.done'''
|
||||
|
|
|
@ -2,7 +2,8 @@
|
|||
|
||||
# jenkins variables
|
||||
project_name: docker-cloud9
|
||||
external_type: github_stable
|
||||
external_type: na
|
||||
custom_version_command: "curl -sX GET https://api.github.com/repos/linuxserver/docker-docker-compose/releases/latest | jq -r '.tag_name' | sed 's|-ls.*||'"
|
||||
release_type: stable
|
||||
release_tag: latest
|
||||
ls_branch: master
|
||||
|
|
Ładowanie…
Reference in New Issue