Ultimos detalles
Some checks failed
CD for startPage / build (push) Successful in 1m5s
CD for startPage / deploy (push) Failing after 4s

This commit is contained in:
2023-07-01 03:54:37 -04:00
parent c945b13af1
commit 3d69f0e0ba

View File

@@ -10,34 +10,34 @@ jobs:
container: catthehacker/ubuntu:act-latest
steps:
- uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: https://github.com/docker/setup-buildx-action@v2
- name: Login to Docker Hub
uses: docker/login-action@v2
- uses: docker/login-action@v2
with:
registry: git.skrd.fun
username: ${{ github.repository_owner }}
password: ${{ secrets.REGISTRY_ACCESS_TOKEN }}
- name: Build and push
uses: docker/build-push-action@master
- uses: https://github.com/docker/setup-buildx-action@v2
- uses: docker/build-push-action@master
with:
context: .
file: ./Dockerfile
push: true
tags: git.skrd.fun/skrd/start.skrd.fun:latest
#
#
# deploy:
# needs: build
# runs-on: ubuntu-latest
#
# steps:
# - uses: actions/checkout@v3
# - name: Run build step
# run: ./build.sh
# - name: Configure Server
# run: |
# apt update && apt install rsync -y
# echo "${{ secrets.SERVER_PRIVATE_KEY }}" > private_key && chmod 600 private_key
# export SSH_COMMAND="ssh -o StrictHostKeyChecking=no -i private_key -p ${{ secrets.SSH_PORT || 22 }}"
# rsync -vrz -e "$SSH_COMMAND" public/ ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }}:/var/www/start.skrd.fun/
deploy:
needs: build
runs-on: ubuntu-latest
steps:
- uses: docker/login-action@v2
with:
registry: git.skrd.fun
username: ${{ github.repository_owner }}
password: ${{ secrets.REGISTRY_ACCESS_TOKEN }}
- name: Configure connection to server
run: |
echo "${{ secrets.SERVER_PRIVATE_KEY }}" > private_key && chmod 600 private_key
ssh -o StrictHostKeyChecking=no -i private_key ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} -p ${{ secrets.SSH_PORT || 22 }} '
docker compose pull
docker compose up -d
'