Skip to content

Commit 2d862dd

Browse files
committed
fork current master to 3.12
1 parent 0c1e360 commit 2d862dd

File tree

6 files changed

+29
-29
lines changed

6 files changed

+29
-29
lines changed

.github/workflows/external_trigger.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@ on:
44
workflow_dispatch:
55

66
jobs:
7-
external-trigger-master:
7+
external-trigger-3-12:
88
runs-on: ubuntu-latest
99
steps:
1010
- uses: actions/checkout@v2.3.3
1111

1212
- name: External Trigger
13-
if: github.ref == 'refs/heads/master'
13+
if: github.ref == 'refs/heads/3.12'
1414
run: |
1515
echo "**** No external release, exiting ****"
1616
exit 0

.github/workflows/greetings.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@ jobs:
88
steps:
99
- uses: actions/first-interaction@v1
1010
with:
11-
issue-message: 'Thanks for opening your first issue here! Be sure to follow the [issue template](https://github.com/linuxserver/docker-baseimage-alpine-nginx/blob/master/.github/ISSUE_TEMPLATE.md)!'
11+
issue-message: 'Thanks for opening your first issue here! Be sure to follow the [bug](https://github.com/linuxserver/docker-baseimage-alpine-nginx/blob/master/.github/ISSUE_TEMPLATE/issue.bug.md) or [feature](https://github.com/linuxserver/docker-baseimage-alpine-nginx/blob/master/.github/ISSUE_TEMPLATE/issue.feature.md) issue templates!'
1212
pr-message: 'Thanks for opening this pull request! Be sure to follow the [pull request template](https://github.com/linuxserver/docker-baseimage-alpine-nginx/blob/master/.github/PULL_REQUEST_TEMPLATE.md)!'
1313
repo-token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/package_trigger.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,25 +4,25 @@ on:
44
workflow_dispatch:
55

66
jobs:
7-
package-trigger-master:
7+
package-trigger-3-12:
88
runs-on: ubuntu-latest
99
steps:
1010
- uses: actions/checkout@v2.3.3
1111

1212
- name: Package Trigger
13-
if: github.ref == 'refs/heads/master'
13+
if: github.ref == 'refs/heads/3.12'
1414
run: |
15-
if [ -n "${{ secrets.PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_NGINX_MASTER }}" ]; then
16-
echo "**** Github secret PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_NGINX_MASTER is set; skipping trigger. ****"
15+
if [ -n "${{ secrets.PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_NGINX_3_12 }}" ]; then
16+
echo "**** Github secret PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_NGINX_3_12 is set; skipping trigger. ****"
1717
exit 0
1818
fi
19-
if [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-baseimage-alpine-nginx/job/master/lastBuild/api/json | jq -r '.building') == "true" ]; then
19+
if [ $(curl -s https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-baseimage-alpine-nginx/job/3.12/lastBuild/api/json | jq -r '.building') == "true" ]; then
2020
echo "**** There already seems to be an active build on Jenkins; skipping package trigger ****"
2121
exit 0
2222
fi
23-
echo "**** Package trigger running off of master branch. To disable, set a Github secret named \"PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_NGINX_MASTER\". ****"
23+
echo "**** Package trigger running off of 3.12 branch. To disable, set a Github secret named \"PAUSE_PACKAGE_TRIGGER_BASEIMAGE_ALPINE_NGINX_3_12\". ****"
2424
response=$(curl -iX POST \
25-
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-baseimage-alpine-nginx/job/master/buildWithParameters?PACKAGE_CHECK=true \
25+
https://ci.linuxserver.io/job/Docker-Pipeline-Builders/job/docker-baseimage-alpine-nginx/job/3.12/buildWithParameters?PACKAGE_CHECK=true \
2626
--user ${{ secrets.JENKINS_USER }}:${{ secrets.JENKINS_TOKEN }} | grep -i location | sed "s|^[L|l]ocation: \(.*\)|\1|")
2727
echo "**** Jenkins job queue url: ${response%$'\r'} ****"
2828
echo "**** Sleeping 10 seconds until job starts ****"

.github/workflows/package_trigger_scheduler.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Package Trigger Scheduler
22

33
on:
44
schedule:
5-
- cron: '01 6 * * 6'
5+
- cron: '43 5 * * 4'
66
workflow_dispatch:
77

88
jobs:

Jenkinsfile

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -117,10 +117,10 @@ pipeline {
117117
}
118118
}
119119
}
120-
// If this is a master build use live docker endpoints
120+
// If this is a 3.12 build use live docker endpoints
121121
stage("Set ENV live build"){
122122
when {
123-
branch "master"
123+
branch "3.12"
124124
environment name: 'CHANGE_ID', value: ''
125125
}
126126
steps {
@@ -142,7 +142,7 @@ pipeline {
142142
// If this is a dev build use dev docker endpoints
143143
stage("Set ENV dev build"){
144144
when {
145-
not {branch "master"}
145+
not {branch "3.12"}
146146
environment name: 'CHANGE_ID', value: ''
147147
}
148148
steps {
@@ -217,7 +217,7 @@ pipeline {
217217
// Use helper containers to render templated files
218218
stage('Update-Templates') {
219219
when {
220-
branch "master"
220+
branch "3.12"
221221
environment name: 'CHANGE_ID', value: ''
222222
expression {
223223
env.CONTAINER_NAME != null
@@ -228,15 +228,15 @@ pipeline {
228228
set -e
229229
TEMPDIR=$(mktemp -d)
230230
docker pull ghcr.io/linuxserver/jenkins-builder:latest
231-
docker run --rm -e CONTAINER_NAME=${CONTAINER_NAME} -e GITHUB_BRANCH=master -v ${TEMPDIR}:/ansible/jenkins ghcr.io/linuxserver/jenkins-builder:latest
231+
docker run --rm -e CONTAINER_NAME=${CONTAINER_NAME} -e GITHUB_BRANCH=3.12 -v ${TEMPDIR}:/ansible/jenkins ghcr.io/linuxserver/jenkins-builder:latest
232232
CURRENTHASH=$(grep -hs ^ ${TEMPLATED_FILES} | md5sum | cut -c1-8)
233233
cd ${TEMPDIR}/docker-${CONTAINER_NAME}
234234
NEWHASH=$(grep -hs ^ ${TEMPLATED_FILES} | md5sum | cut -c1-8)
235235
if [[ "${CURRENTHASH}" != "${NEWHASH}" ]]; then
236236
mkdir -p ${TEMPDIR}/repo
237237
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/repo/${LS_REPO}
238238
cd ${TEMPDIR}/repo/${LS_REPO}
239-
git checkout -f master
239+
git checkout -f 3.12
240240
cd ${TEMPDIR}/docker-${CONTAINER_NAME}
241241
mkdir -p ${TEMPDIR}/repo/${LS_REPO}/.github/workflows
242242
mkdir -p ${TEMPDIR}/repo/${LS_REPO}/.github/ISSUE_TEMPLATE
@@ -253,7 +253,7 @@ pipeline {
253253
fi
254254
mkdir -p ${TEMPDIR}/gitbook
255255
git clone https://github.com/linuxserver/docker-documentation.git ${TEMPDIR}/gitbook/docker-documentation
256-
if [[ "${BRANCH_NAME}" == "master" ]] && [[ (! -f ${TEMPDIR}/gitbook/docker-documentation/images/docker-${CONTAINER_NAME}.md) || ("$(md5sum ${TEMPDIR}/gitbook/docker-documentation/images/docker-${CONTAINER_NAME}.md | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/docker-${CONTAINER_NAME}.md | awk '{ print $1 }')") ]]; then
256+
if [[ ("${BRANCH_NAME}" == "master") || ("${BRANCH_NAME}" == "main") ]] && [[ (! -f ${TEMPDIR}/gitbook/docker-documentation/images/docker-${CONTAINER_NAME}.md) || ("$(md5sum ${TEMPDIR}/gitbook/docker-documentation/images/docker-${CONTAINER_NAME}.md | awk '{ print $1 }')" != "$(md5sum ${TEMPDIR}/docker-${CONTAINER_NAME}/docker-${CONTAINER_NAME}.md | awk '{ print $1 }')") ]]; then
257257
cp ${TEMPDIR}/docker-${CONTAINER_NAME}/docker-${CONTAINER_NAME}.md ${TEMPDIR}/gitbook/docker-documentation/images/
258258
cd ${TEMPDIR}/gitbook/docker-documentation/
259259
git add images/docker-${CONTAINER_NAME}.md
@@ -271,7 +271,7 @@ pipeline {
271271
// Exit the build if the Templated files were just updated
272272
stage('Template-exit') {
273273
when {
274-
branch "master"
274+
branch "3.12"
275275
environment name: 'CHANGE_ID', value: ''
276276
environment name: 'FILES_UPDATED', value: 'true'
277277
expression {
@@ -380,7 +380,7 @@ pipeline {
380380
// Take the image we just built and dump package versions for comparison
381381
stage('Update-packages') {
382382
when {
383-
branch "master"
383+
branch "3.12"
384384
environment name: 'CHANGE_ID', value: ''
385385
environment name: 'EXIT_STATUS', value: ''
386386
}
@@ -408,7 +408,7 @@ pipeline {
408408
echo "Package tag sha from current packages in buit container is ${NEW_PACKAGE_TAG} comparing to old ${PACKAGE_TAG} from github"
409409
if [ "${NEW_PACKAGE_TAG}" != "${PACKAGE_TAG}" ]; then
410410
git clone https://github.com/${LS_USER}/${LS_REPO}.git ${TEMPDIR}/${LS_REPO}
411-
git --git-dir ${TEMPDIR}/${LS_REPO}/.git checkout -f master
411+
git --git-dir ${TEMPDIR}/${LS_REPO}/.git checkout -f 3.12
412412
cp ${TEMPDIR}/package_versions.txt ${TEMPDIR}/${LS_REPO}/
413413
cd ${TEMPDIR}/${LS_REPO}/
414414
wait
@@ -432,7 +432,7 @@ pipeline {
432432
// Exit the build if the package file was just updated
433433
stage('PACKAGE-exit') {
434434
when {
435-
branch "master"
435+
branch "3.12"
436436
environment name: 'CHANGE_ID', value: ''
437437
environment name: 'PACKAGE_UPDATED', value: 'true'
438438
environment name: 'EXIT_STATUS', value: ''
@@ -446,7 +446,7 @@ pipeline {
446446
// Exit the build if this is just a package check and there are no changes to push
447447
stage('PACKAGECHECK-exit') {
448448
when {
449-
branch "master"
449+
branch "3.12"
450450
environment name: 'CHANGE_ID', value: ''
451451
environment name: 'PACKAGE_UPDATED', value: 'false'
452452
environment name: 'EXIT_STATUS', value: ''
@@ -638,7 +638,7 @@ pipeline {
638638
// If this is a public release tag it in the LS Github
639639
stage('Github-Tag-Push-Release') {
640640
when {
641-
branch "master"
641+
branch "3.12"
642642
expression {
643643
env.LS_RELEASE != env.EXT_RELEASE_CLEAN + '-ls' + env.LS_TAG_NUMBER
644644
}
@@ -650,17 +650,17 @@ pipeline {
650650
sh '''curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/git/tags \
651651
-d '{"tag":"'${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}'",\
652652
"object": "'${COMMIT_SHA}'",\
653-
"message": "Tagging Release '${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}' to master",\
653+
"message": "Tagging Release '${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}' to 3.12",\
654654
"type": "commit",\
655655
"tagger": {"name": "LinuxServer Jenkins","email": "jenkins@linuxserver.io","date": "'${GITHUB_DATE}'"}}' '''
656656
echo "Pushing New release for Tag"
657657
sh '''#! /bin/bash
658658
echo "Updating base packages to ${PACKAGE_TAG}" > releasebody.json
659659
echo '{"tag_name":"'${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}'",\
660-
"target_commitish": "master",\
660+
"target_commitish": "3.12",\
661661
"name": "'${EXT_RELEASE_CLEAN}'-ls'${LS_TAG_NUMBER}'",\
662662
"body": "**LinuxServer Changes:**\\n\\n'${LS_RELEASE_NOTES}'\\n**OS Changes:**\\n\\n' > start
663-
printf '","draft": false,"prerelease": false}' >> releasebody.json
663+
printf '","draft": false,"prerelease": true}' >> releasebody.json
664664
paste -d'\\0' start releasebody.json > releasebody.json.done
665665
curl -H "Authorization: token ${GITHUB_TOKEN}" -X POST https://api.github.com/repos/${LS_USER}/${LS_REPO}/releases -d @releasebody.json.done'''
666666
}

jenkins-vars.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
# jenkins variables
44
project_name: docker-baseimage-alpine-nginx
55
external_type: os
6-
release_type: stable
6+
release_type: prerelease
77
release_tag: "3.12"
8-
ls_branch: master
8+
ls_branch: 3.12
99
repo_vars:
1010
- BUILD_VERSION_ARG = 'OS'
1111
- LS_USER = 'linuxserver'

0 commit comments

Comments
 (0)