-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
➕Create (check-update-alpine-base-os-container-armhf.yml)
- Loading branch information
1 parent
e650eea
commit aa2cfad
Showing
1 changed file
with
31 additions
and
0 deletions.
There are no files selected for viewing
31 changes: 31 additions & 0 deletions
31
.github/workflows/check-update-alpine-base-os-container-armhf.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Check Update Alpine BaseOS Container -armhf | ||
|
||
on: | ||
#schedule: | ||
#- cron: '0 0 * * 0' | ||
workflow_dispatch: | ||
|
||
jobs: | ||
check_version: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: ➡️ Get Alpine version from URL | ||
run: | | ||
URL_BASE="https://dl-cdn.alpinelinux.org/alpine/v3.20/releases/armhf/" | ||
FILE=$(curl -s $URL_BASE | grep -oP 'alpine-minirootfs-[0-9]{1}.[0-9]{2}.[0-9]{1}') | ||
FULL_URL="${URL_BASE}${FILE}" | ||
LAST_VERSION=$(echo $FULL_URL | grep -oP '([0-9]{1}\.[0-9]{2}\.[0-9]{1})' | tail -n 1) | ||
echo $LAST_VERSION >> alpine/armhf/last_version.txt | ||
- name: ✔️ Commit and push changes | ||
run: | | ||
git config --global user.name "github-actions[bot]" | ||
git config --global user.email "github-actions[bot]@users.noreply.github.com" | ||
git add . | ||
git commit -m "💫Update (Alpine BaseOS Container $LAST_VERSION-armhf)" | ||
git push | ||