fix: replace awscli/SeaweedFS with Gitea package registry upload
Some checks failed
Build & Sign Wraith / Build Windows + Sign (push) Failing after 46s
Some checks failed
Build & Sign Wraith / Build Windows + Sign (push) Failing after 46s
This commit is contained in:
parent
eda819c0fd
commit
e5cc40df37
@ -55,7 +55,7 @@ jobs:
|
||||
mingw-w64 mingw-w64-tools binutils-mingw-w64 \
|
||||
cmake ninja-build nasm meson \
|
||||
default-jre-headless \
|
||||
python3 awscli
|
||||
python3 curl
|
||||
|
||||
# Node.js
|
||||
if ! command -v node >/dev/null 2>&1; then
|
||||
@ -239,26 +239,33 @@ jobs:
|
||||
cat dist/version.json
|
||||
|
||||
# ===============================================================
|
||||
# Upload release artifacts
|
||||
# Upload to Gitea Package Registry
|
||||
# ===============================================================
|
||||
- name: Upload release artifacts
|
||||
- name: Upload to Gitea packages
|
||||
run: |
|
||||
VERSION="${{ steps.version.outputs.version }}"
|
||||
ENDPOINT="https://files.command.vigilcyber.com"
|
||||
GITEA_URL="https://git.command.vigilcyber.com"
|
||||
OWNER="vstockwell"
|
||||
PACKAGE="wraith"
|
||||
|
||||
echo "=== Uploading Wraith ${VERSION} ==="
|
||||
echo "=== Uploading Wraith ${VERSION} to Gitea packages ==="
|
||||
|
||||
# Versioned path
|
||||
aws s3 cp dist/ "s3://agents/wraith/${VERSION}/windows/amd64/" \
|
||||
--recursive --endpoint-url "$ENDPOINT" --no-sign-request
|
||||
|
||||
# Latest path
|
||||
aws s3 sync dist/ "s3://agents/wraith/latest/windows/amd64/" \
|
||||
--delete --endpoint-url "$ENDPOINT" --no-sign-request
|
||||
# Upload each file as a generic package
|
||||
for file in dist/*; do
|
||||
[ -f "$file" ] || continue
|
||||
FILENAME=$(basename "$file")
|
||||
echo "Uploading: ${FILENAME}"
|
||||
curl -s -X PUT \
|
||||
-H "Authorization: token ${{ secrets.GIT_TOKEN }}" \
|
||||
-H "Content-Type: application/octet-stream" \
|
||||
--data-binary @"$file" \
|
||||
"${GITEA_URL}/api/packages/${OWNER}/generic/${PACKAGE}/${VERSION}/${FILENAME}"
|
||||
echo " Done."
|
||||
done
|
||||
|
||||
echo ""
|
||||
echo "=== Upload complete ==="
|
||||
echo "Versioned: ${ENDPOINT}/agents/wraith/${VERSION}/windows/amd64/"
|
||||
echo "Latest: ${ENDPOINT}/agents/wraith/latest/windows/amd64/"
|
||||
echo "Package: ${GITEA_URL}/${OWNER}/-/packages/generic/${PACKAGE}/${VERSION}"
|
||||
echo ""
|
||||
echo "=== Contents ==="
|
||||
ls -la dist/
|
||||
|
||||
Loading…
Reference in New Issue
Block a user