Fix Gitea Actions checkout for subpath
This commit is contained in:
parent
f7d683c467
commit
8ddf71ad96
|
|
@ -11,9 +11,15 @@ jobs:
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Check out repository
|
- name: Check out repository
|
||||||
uses: actions/checkout@v4
|
run: |
|
||||||
with:
|
set -euo pipefail
|
||||||
fetch-depth: 0
|
|
||||||
|
find . -mindepth 1 -maxdepth 1 -exec rm -rf -- {} +
|
||||||
|
git init
|
||||||
|
git remote add origin https://lab2025.duckdns.org/git/jv/my-homelab-configs.git
|
||||||
|
git fetch --prune origin +refs/heads/main:refs/remotes/origin/main +refs/tags/*:refs/tags/*
|
||||||
|
git checkout --force "${{ gitea.sha }}"
|
||||||
|
git config --global --add safe.directory "$PWD"
|
||||||
|
|
||||||
- name: Verify Debian runner guardrails
|
- name: Verify Debian runner guardrails
|
||||||
run: |
|
run: |
|
||||||
|
|
|
||||||
2
lab.sh
2
lab.sh
|
|
@ -544,7 +544,7 @@ install_gitea_runner() {
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
for package in ca-certificates curl git python3; do
|
for package in ca-certificates curl git nodejs python3; do
|
||||||
if ! dpkg-query -W -f='${Status}' "$package" 2>/dev/null | grep -q "install ok installed"; then
|
if ! dpkg-query -W -f='${Status}' "$package" 2>/dev/null | grep -q "install ok installed"; then
|
||||||
missing_packages="$missing_packages $package"
|
missing_packages="$missing_packages $package"
|
||||||
fi
|
fi
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue