mirror of
https://github.com/hoellen/docker-nextcloud.git
synced 2025-04-22 13:39:25 +00:00
Merge 35725bd4eb89af3016cace57e7b3a8cbdc57e1bc into 1ee6c08552e3fc0ba1dfdcdac0604f86eab04d8c
This commit is contained in:
commit
0e5a57cf13
12
.github/workflows/build.yml
vendored
12
.github/workflows/build.yml
vendored
@ -3,7 +3,9 @@ name: build
|
|||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
push:
|
push:
|
||||||
branches: [ master ]
|
branches:
|
||||||
|
- master
|
||||||
|
- version-*
|
||||||
schedule:
|
schedule:
|
||||||
# Build the image regularly (each Friday)
|
# Build the image regularly (each Friday)
|
||||||
- cron: '23 04 * * 5'
|
- cron: '23 04 * * 5'
|
||||||
@ -27,6 +29,12 @@ jobs:
|
|||||||
|
|
||||||
- name: Extract version for tags
|
- name: Extract version for tags
|
||||||
run: |
|
run: |
|
||||||
|
if [[ "$GITHUB_REF" == refs/heads/* ]]; then
|
||||||
|
BRANCH="${GITHUB_REF#refs/heads/}"
|
||||||
|
if [ "$BRANCH" = "master" ]; then
|
||||||
|
echo "BRANCH_VERSION=latest" >> $GITHUB_ENV
|
||||||
|
fi
|
||||||
|
fi
|
||||||
echo "FULL_VERSION=$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c6)" >> $GITHUB_ENV
|
echo "FULL_VERSION=$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c6)" >> $GITHUB_ENV
|
||||||
echo "MAJOR_VERSION=$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c2)" >> $GITHUB_ENV
|
echo "MAJOR_VERSION=$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c2)" >> $GITHUB_ENV
|
||||||
|
|
||||||
@ -53,7 +61,7 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
||||||
tags: |
|
tags: |
|
||||||
latest
|
${{ env.BRANCH_VERSION }}
|
||||||
${{ env.FULL_VERSION }}
|
${{ env.FULL_VERSION }}
|
||||||
${{ env.MAJOR_VERSION }}
|
${{ env.MAJOR_VERSION }}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user