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 \
|
mingw-w64 mingw-w64-tools binutils-mingw-w64 \
|
||||||
cmake ninja-build nasm meson \
|
cmake ninja-build nasm meson \
|
||||||
default-jre-headless \
|
default-jre-headless \
|
||||||
python3 awscli
|
python3 curl
|
||||||
|
|
||||||
# Node.js
|
# Node.js
|
||||||
if ! command -v node >/dev/null 2>&1; then
|
if ! command -v node >/dev/null 2>&1; then
|
||||||
@ -239,26 +239,33 @@ jobs:
|
|||||||
cat dist/version.json
|
cat dist/version.json
|
||||||
|
|
||||||
# ===============================================================
|
# ===============================================================
|
||||||
# Upload release artifacts
|
# Upload to Gitea Package Registry
|
||||||
# ===============================================================
|
# ===============================================================
|
||||||
- name: Upload release artifacts
|
- name: Upload to Gitea packages
|
||||||
run: |
|
run: |
|
||||||
VERSION="${{ steps.version.outputs.version }}"
|
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
|
# Upload each file as a generic package
|
||||||
aws s3 cp dist/ "s3://agents/wraith/${VERSION}/windows/amd64/" \
|
for file in dist/*; do
|
||||||
--recursive --endpoint-url "$ENDPOINT" --no-sign-request
|
[ -f "$file" ] || continue
|
||||||
|
FILENAME=$(basename "$file")
|
||||||
# Latest path
|
echo "Uploading: ${FILENAME}"
|
||||||
aws s3 sync dist/ "s3://agents/wraith/latest/windows/amd64/" \
|
curl -s -X PUT \
|
||||||
--delete --endpoint-url "$ENDPOINT" --no-sign-request
|
-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 "=== Upload complete ==="
|
||||||
echo "Versioned: ${ENDPOINT}/agents/wraith/${VERSION}/windows/amd64/"
|
echo "Package: ${GITEA_URL}/${OWNER}/-/packages/generic/${PACKAGE}/${VERSION}"
|
||||||
echo "Latest: ${ENDPOINT}/agents/wraith/latest/windows/amd64/"
|
|
||||||
echo ""
|
echo ""
|
||||||
echo "=== Contents ==="
|
echo "=== Contents ==="
|
||||||
ls -la dist/
|
ls -la dist/
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user