ci: fix workflow stability by using standard actions
This commit is contained in:
@@ -20,9 +20,9 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
run: |
|
uses: actions/checkout@v4
|
||||||
git clone --depth 1 --branch ${{ github.ref_name }} http://gitea:3000/jimmy/nas-tools.git .
|
with:
|
||||||
git checkout ${{ github.sha }}
|
ref: ${{ github.sha }}
|
||||||
|
|
||||||
- name: Resolve image tags
|
- name: Resolve image tags
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
@@ -15,9 +15,9 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
run: |
|
uses: actions/checkout@v4
|
||||||
git clone --depth 1 --branch ${{ github.ref_name }} http://gitea:3000/jimmy/nas-tools.git .
|
with:
|
||||||
git checkout ${{ github.sha }}
|
ref: ${{ github.sha }}
|
||||||
- name: Warm mirror cache for base images
|
- name: Warm mirror cache for base images
|
||||||
run: |
|
run: |
|
||||||
set -u
|
set -u
|
||||||
|
|||||||
@@ -18,13 +18,10 @@ jobs:
|
|||||||
- /var/packages/ContainerManager/target/usr/bin/docker:/usr/bin/docker
|
- /var/packages/ContainerManager/target/usr/bin/docker:/usr/bin/docker
|
||||||
- /volume1/docker/nas-dashboard:/nas-dashboard
|
- /volume1/docker/nas-dashboard:/nas-dashboard
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout exact commit
|
- name: Checkout repository
|
||||||
run: |
|
uses: actions/checkout@v4
|
||||||
set -euo pipefail
|
with:
|
||||||
git init .
|
fetch-depth: 1
|
||||||
git remote add origin http://gitea:3000/jimmy/nas-tools.git
|
|
||||||
git fetch --depth 1 origin "$GITHUB_SHA"
|
|
||||||
git checkout --detach FETCH_HEAD
|
|
||||||
- name: Warm mirror cache for base images
|
- name: Warm mirror cache for base images
|
||||||
run: |
|
run: |
|
||||||
set -u
|
set -u
|
||||||
|
|||||||
+15
-10
@@ -15,9 +15,14 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
run: |
|
uses: actions/checkout@v4
|
||||||
git clone http://gitea:3000/jimmy/nas-tools.git .
|
|
||||||
git checkout ${{ github.sha }}
|
- name: Setup Python
|
||||||
|
uses: actions/setup-python@v5
|
||||||
|
with:
|
||||||
|
python-version: '3.12'
|
||||||
|
cache: 'pip'
|
||||||
|
cache-dependency-path: 'dashboard/backend/requirements*.txt'
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
@@ -46,14 +51,14 @@ jobs:
|
|||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
run: |
|
uses: actions/checkout@v4
|
||||||
git clone http://gitea:3000/jimmy/nas-tools.git .
|
|
||||||
git checkout ${{ github.sha }}
|
|
||||||
|
|
||||||
- name: Install Node.js
|
- name: Setup Node.js
|
||||||
run: |
|
uses: actions/setup-node@v4
|
||||||
curl -fsSL https://deb.nodesource.com/setup_20.x | bash -
|
with:
|
||||||
apt-get install -y nodejs
|
node-version: '20'
|
||||||
|
cache: 'npm'
|
||||||
|
cache-dependency-path: 'dashboard/frontend/package-lock.json'
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
Reference in New Issue
Block a user