Skip to content

tera-api / fix relation between Land and SeedStock #68

tera-api / fix relation between Land and SeedStock

tera-api / fix relation between Land and SeedStock #68

name: 'Deploy to production'
env:
FONTAWESOME_PACKAGE_TOKEN: ${{ secrets.FONTAWESOME_PACKAGE_TOKEN }}
REGISTRY: ghcr.io
on:
push:
branches:
- main
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
buildandpush:
name: 'Build and push docker images'
runs-on: ubuntu-latest
steps:
- uses: 'actions/checkout@v4'
with:
fetch-depth: 0
- name: Set up Moon Toolchain
uses: 'moonrepo/setup-toolchain@v0'
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
run: 'moon ci :production-docker-push'
deploy:
name: 'Deploy to VPS'
runs-on: ubuntu-latest
needs: buildandpush
environment: prod-manual
steps:
- uses: 'actions/checkout@v4'
with:
fetch-depth: 0
- name: Set up Moon Toolchain
uses: 'moonrepo/setup-toolchain@v0'
- name: 'Redeploy from Dokploy on VPS'
env:
DOKPLOY_API_TOKEN: ${{ secrets.DOKPLOY_API_TOKEN }}
DOKPLOY_API_URL: ${{ secrets.DOKPLOY_API_URL }}
run: 'moon ci :production-dokploy-compose-deploy'