fix: curl not installed???

This commit is contained in:
Winter_Myst 2024-09-22 01:55:02 +02:00
commit ad9e7ec7ab

View File

@ -8,6 +8,7 @@ compile:
image: ubuntu:latest image: ubuntu:latest
before_script: before_script:
# Install Node.js v21.7.3 manually # Install Node.js v21.7.3 manually
- apt-get update && apt-get install -y curl
- curl -fsSL https://deb.nodesource.com/setup_21.x | bash - - curl -fsSL https://deb.nodesource.com/setup_21.x | bash -
- apt-get install -y nodejs - apt-get install -y nodejs
- node -v # Verify the correct Node.js version - node -v # Verify the correct Node.js version
@ -26,6 +27,7 @@ release:
image: ubuntu:latest # Or any other basic image image: ubuntu:latest # Or any other basic image
before_script: before_script:
# Install Node.js v21.7.3 manually # Install Node.js v21.7.3 manually
- apt-get update && apt-get install -y curl
- curl -fsSL https://deb.nodesource.com/setup_21.x | bash - - curl -fsSL https://deb.nodesource.com/setup_21.x | bash -
- apt-get install -y nodejs - apt-get install -y nodejs
- node -v # Verify the correct Node.js version - node -v # Verify the correct Node.js version
@ -41,13 +43,15 @@ release:
- ssh-keyscan gitlab.com >> ~/.ssh/known_hosts - ssh-keyscan gitlab.com >> ~/.ssh/known_hosts
script: script:
# Check if VERSION is provided # Check if VERSION is provided
- if [ -z "$VERSION" ]; then echo "Error: VERSION variable is required." && exit 1; fi - |
if [ -z "$VERSION" ]; then echo "Error: VERSION variable is required." && exit 1; fi
# Run Gulp release task (includes zipping) # Run Gulp release task (includes zipping)
- gulp release - gulp release
# Create a release on GitLab # Create a release on GitLab
- export RELEASE_RESPONSE=$(curl --request POST \ - |
export RELEASE_RESPONSE=$(curl --request POST \
--header "PRIVATE-TOKEN: $GITLAB_TOKEN" \ --header "PRIVATE-TOKEN: $GITLAB_TOKEN" \
--header "Content-Type: application/json" \ --header "Content-Type: application/json" \
--data '{ --data '{
@ -69,7 +73,8 @@ release:
- export RELEASE_URL=$(echo $RELEASE_RESPONSE | jq -r '.assets.links[0].url') - export RELEASE_URL=$(echo $RELEASE_RESPONSE | jq -r '.assets.links[0].url')
# Update the system.json file with the release URL # Update the system.json file with the release URL
- sed -i "s|\"download\":.*|\"download\": \"$RELEASE_URL\",|" system.json - |
sed -i "s|\"download\":.*|\"download\": \"$RELEASE_URL\",|" system.json
# Commit the updated system.json and push it to master # Commit the updated system.json and push it to master
- git config --global user.name "GitLab CI" - git config --global user.name "GitLab CI"
@ -79,7 +84,8 @@ release:
- git push origin master - git push origin master
# Publish the release to the Foundry API # Publish the release to the Foundry API
- curl -X POST https://api.foundryvtt.com/_api/packages/release_version/ \ - |
curl -X POST https://api.foundryvtt.com/_api/packages/release_version/ \
-H "Authorization: $FOUNDRY_API_KEY" \ -H "Authorization: $FOUNDRY_API_KEY" \
-H "Content-Type: application/json" \ -H "Content-Type: application/json" \
-d '{ -d '{