mirror of
https://github.com/neondatabase/neon.git
synced 2025-12-26 07:39:58 +00:00
CI: miscellaneous cleanups (#8073)
## Problem There are a couple of small CI cleanups that seem too small for dedicated PRs ## Summary of changes - Create release PR with the title that matches the title in the description - Tune error message for disallowing `ubuntu-latest` to explicitly mention what to do - Remove junit output from pytest, we use allure instead
This commit is contained in:
committed by
GitHub
parent
558a57b15b
commit
c789ec21f6
@@ -183,8 +183,7 @@ runs:
|
|||||||
|
|
||||||
# Run the tests.
|
# Run the tests.
|
||||||
#
|
#
|
||||||
# The junit.xml file allows CI tools to display more fine-grained test information
|
# --alluredir saves test results in Allure format (in a specified directory)
|
||||||
# in its "Tests" tab in the results page.
|
|
||||||
# --verbose prints name of each test (helpful when there are
|
# --verbose prints name of each test (helpful when there are
|
||||||
# multiple tests in one file)
|
# multiple tests in one file)
|
||||||
# -rA prints summary in the end
|
# -rA prints summary in the end
|
||||||
@@ -193,7 +192,6 @@ runs:
|
|||||||
#
|
#
|
||||||
mkdir -p $TEST_OUTPUT/allure/results
|
mkdir -p $TEST_OUTPUT/allure/results
|
||||||
"${cov_prefix[@]}" ./scripts/pytest \
|
"${cov_prefix[@]}" ./scripts/pytest \
|
||||||
--junitxml=$TEST_OUTPUT/junit.xml \
|
|
||||||
--alluredir=$TEST_OUTPUT/allure/results \
|
--alluredir=$TEST_OUTPUT/allure/results \
|
||||||
--tb=short \
|
--tb=short \
|
||||||
--verbose \
|
--verbose \
|
||||||
|
|||||||
9
.github/workflows/actionlint.yml
vendored
9
.github/workflows/actionlint.yml
vendored
@@ -36,15 +36,16 @@ jobs:
|
|||||||
fail_on_error: true
|
fail_on_error: true
|
||||||
filter_mode: nofilter
|
filter_mode: nofilter
|
||||||
level: error
|
level: error
|
||||||
- run: |
|
|
||||||
|
- name: Disallow 'ubuntu-latest' runners
|
||||||
|
run: |
|
||||||
PAT='^\s*runs-on:.*-latest'
|
PAT='^\s*runs-on:.*-latest'
|
||||||
if grep -ERq $PAT .github/workflows
|
if grep -ERq $PAT .github/workflows; then
|
||||||
then
|
|
||||||
grep -ERl $PAT .github/workflows |\
|
grep -ERl $PAT .github/workflows |\
|
||||||
while read -r f
|
while read -r f
|
||||||
do
|
do
|
||||||
l=$(grep -nE $PAT .github/workflows/release.yml | awk -F: '{print $1}' | head -1)
|
l=$(grep -nE $PAT .github/workflows/release.yml | awk -F: '{print $1}' | head -1)
|
||||||
echo "::error file=$f,line=$l::Please, do not use ubuntu-latest images to run on, use LTS instead."
|
echo "::error file=$f,line=$l::Please use 'ubuntu-22.04' instead of 'ubuntu-latest'"
|
||||||
done
|
done
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|||||||
12
.github/workflows/release.yml
vendored
12
.github/workflows/release.yml
vendored
@@ -52,13 +52,15 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ secrets.CI_ACCESS_TOKEN }}
|
GH_TOKEN: ${{ secrets.CI_ACCESS_TOKEN }}
|
||||||
run: |
|
run: |
|
||||||
|
TITLE="Storage & Compute release ${RELEASE_DATE}"
|
||||||
|
|
||||||
cat << EOF > body.md
|
cat << EOF > body.md
|
||||||
## Storage & Compute release ${RELEASE_DATE}
|
## ${TITLE}
|
||||||
|
|
||||||
**Please merge this Pull Request using 'Create a merge commit' button**
|
**Please merge this Pull Request using 'Create a merge commit' button**
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
gh pr create --title "Release ${RELEASE_DATE}" \
|
gh pr create --title "${TITLE}" \
|
||||||
--body-file "body.md" \
|
--body-file "body.md" \
|
||||||
--head "${RELEASE_BRANCH}" \
|
--head "${RELEASE_BRANCH}" \
|
||||||
--base "release"
|
--base "release"
|
||||||
@@ -91,13 +93,15 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ secrets.CI_ACCESS_TOKEN }}
|
GH_TOKEN: ${{ secrets.CI_ACCESS_TOKEN }}
|
||||||
run: |
|
run: |
|
||||||
|
TITLE="Proxy release ${RELEASE_DATE}"
|
||||||
|
|
||||||
cat << EOF > body.md
|
cat << EOF > body.md
|
||||||
## Proxy release ${RELEASE_DATE}
|
## ${TITLE}
|
||||||
|
|
||||||
**Please merge this Pull Request using 'Create a merge commit' button**
|
**Please merge this Pull Request using 'Create a merge commit' button**
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
gh pr create --title "Proxy release ${RELEASE_DATE}" \
|
gh pr create --title "${TITLE}" \
|
||||||
--body-file "body.md" \
|
--body-file "body.md" \
|
||||||
--head "${RELEASE_BRANCH}" \
|
--head "${RELEASE_BRANCH}" \
|
||||||
--base "release-proxy"
|
--base "release-proxy"
|
||||||
|
|||||||
Reference in New Issue
Block a user