Update .gitlab-ci.yml

This commit is contained in:
Sean "Solao Bajiuik" Stoves 2020-08-15 13:10:10 -04:00
parent 14237b35c3
commit ca7f6913a6

View File

@ -43,9 +43,6 @@ build:
- hawkeye - hawkeye
script: script:
- 'dotnet build --no-restore' - 'dotnet build --no-restore'
artifacts:
paths:
- bin/
tests: tests:
stage: test stage: test
@ -71,14 +68,14 @@ release:
- master - master
dependencies: dependencies:
- tests - tests
artifacts:
paths:
- publish/
tags: tags:
- docker - docker
- hawkeye - hawkeye
script: script:
- 'dotnet publish -c Release -o ../publish ChaosBot/ChaosBot.csproj' - 'dotnet publish -c Release -r linux-musl-x64 -o ../build --self-contained true'
artifacts:
paths:
- build/*
deploy: deploy:
stage: deploy stage: deploy
@ -97,5 +94,5 @@ deploy:
- 'mkdir ~/.ssh' - 'mkdir ~/.ssh'
- 'ssh-keyscan -p 2303 panel.chaoticlogic.us >> ~/.ssh/known_hosts' - 'ssh-keyscan -p 2303 panel.chaoticlogic.us >> ~/.ssh/known_hosts'
- 'echo "LFTP needs to be fixed"' - 'echo "LFTP needs to be fixed"'
# - 'lftp sftp://$SFTP_USER:$SFTP_PASS@$SFTP_HOST -e "mirror -X .* -X .*/ -X *.db -X appsettings.json --reverse --verbose --delete --parallel=8 ../publish/ ./; bye"' - 'lftp sftp://$SFTP_USER:$SFTP_PASS@$SFTP_HOST -e "mirror -X .* -X .*/ -X *.db -X appsettings.json --reverse --verbose --delete --parallel=8 build/ ./; bye"'
- 'curl -X POST $API_URI/api/endpoints/$ENDPOINT_URI/docker/containers/$CONTAINER_ID/restart -H "Authorization: Bearer `curl -X POST $API_URI/api/auth -H "Content-Type: application/json" -d "{\"Username\": \"$API_USER\", \"Password\": \"$API_PASS\"}"" | jq -r ".jwt"`"' - 'curl -X POST $API_URI/api/endpoints/$ENDPOINT_URI/docker/containers/$CONTAINER_ID/restart -H "Authorization: Bearer `curl -X POST $API_URI/api/auth -H "Content-Type: application/json" -d "{\"Username\": \"$API_USER\", \"Password\": \"$API_PASS\"}"" | jq -r ".jwt"`"'