mirror of
https://github.com/devilbox/docker-php-fpm.git
synced 2025-12-14 21:11:14 +00:00
Fix GitHub Actions nightly workflow
This commit is contained in:
2
.github/workflows/linting.yml
vendored
2
.github/workflows/linting.yml
vendored
@@ -18,7 +18,7 @@ jobs:
|
||||
job: [gen-dockerfiles]
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v1
|
||||
uses: actions/checkout@v2
|
||||
- name: Diff generated Docker files
|
||||
run: |
|
||||
make "${JOB}"
|
||||
|
||||
19
.github/workflows/php-ci.yml
vendored
19
.github/workflows/php-ci.yml
vendored
@@ -32,7 +32,7 @@ jobs:
|
||||
fail-fast: False
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v1
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Show environment
|
||||
run: |
|
||||
@@ -91,18 +91,19 @@ jobs:
|
||||
- name: Set variables
|
||||
id: vars
|
||||
run: |
|
||||
# Set git branch or git tag as slug
|
||||
if [[ ${GITHUB_REF} =~ ^refs\/tags\/ ]]; then
|
||||
# Detached from branch
|
||||
if [ "$( git rev-parse --abbrev-ref HEAD )" = "HEAD" ]; then
|
||||
GIT_TYPE=TAG
|
||||
GIT_SLUG="${GITHUB_REF/refs\/tags\//}"
|
||||
GIT_SLUG="$( git tag --points-at HEAD | head -1 )"
|
||||
else
|
||||
GIT_TYPE=BRANCH
|
||||
if [ -n "${GITHUB_HEAD_REF}" ]; then
|
||||
GIT_SLUG="${GITHUB_HEAD_REF}"
|
||||
else
|
||||
GIT_SLUG="${GITHUB_REF/refs\/heads\//}"
|
||||
fi
|
||||
GIT_SLUG="$( git rev-parse --abbrev-ref HEAD )"
|
||||
fi
|
||||
|
||||
# Output
|
||||
echo "GIT_TYPE=${GIT_TYPE}"
|
||||
echo "GIT_SLUG=${GIT_SLUG}"
|
||||
|
||||
# Export variable
|
||||
# https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-commands-for-github-actions#environment-files
|
||||
echo "GIT_TYPE=${GIT_TYPE}" >> $GITHUB_ENV
|
||||
|
||||
19
.github/workflows/php-nightly.yml
vendored
19
.github/workflows/php-nightly.yml
vendored
@@ -26,7 +26,7 @@ jobs:
|
||||
fail-fast: False
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v1
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Show environment
|
||||
run: |
|
||||
@@ -82,7 +82,7 @@ jobs:
|
||||
- '8.1'
|
||||
refs:
|
||||
- 'master'
|
||||
- '0.114'
|
||||
- '0.118'
|
||||
steps:
|
||||
|
||||
# ------------------------------------------------------------
|
||||
@@ -97,16 +97,19 @@ jobs:
|
||||
- name: Set variables
|
||||
id: vars
|
||||
run: |
|
||||
# Set git branch or git tag as slug
|
||||
if [ -n "$( git tag --points-at HEAD )" ]; then
|
||||
# Detached from branch
|
||||
if [ "$( git rev-parse --abbrev-ref HEAD )" = "HEAD" ]; then
|
||||
GIT_TYPE=TAG
|
||||
GIT_SLUG="$( git tag --points-at HEAD )"
|
||||
elif [ "$( git rev-parse --abbrev-ref HEAD )" != "HEAD" ]; then
|
||||
GIT_SLUG="$( git tag --points-at HEAD | head -1 )"
|
||||
else
|
||||
GIT_TYPE=BRANCH
|
||||
GIT_SLUG="$( git rev-parse --abbrev-ref HEAD )"
|
||||
else
|
||||
false
|
||||
fi
|
||||
|
||||
# Output
|
||||
echo "GIT_TYPE=${GIT_TYPE}"
|
||||
echo "GIT_SLUG=${GIT_SLUG}"
|
||||
|
||||
# Export variable
|
||||
# https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-commands-for-github-actions#environment-files
|
||||
echo "GIT_TYPE=${GIT_TYPE}" >> $GITHUB_ENV
|
||||
|
||||
Reference in New Issue
Block a user