kind: pipeline type: docker name: Build and Push Docker Image steps: - name: Setup Build image: gitea.bsidesolutions.net/bside-solutions/docker-compose-v2-alpine:latest commands: - docker container prune -f - docker image prune -f volumes: - name: docker_sock path: /var/run/docker.sock when: branch: - main - test - feature/* - name: Build and Push Container Image (Staging) image: plugins/docker settings: username: from_secret: DOCKER_USERNAME password: from_secret: DOCKER_PASSWORD repo: gitea.bsidesolutions.net/bside-solutions/bside-webhook-proxy registry: gitea.bsidesolutions.net dockerfile: ./Dockerfile force_tag: true tags: - dev when: branch: - test - name: Build and Push Container Image (Production) image: plugins/docker settings: username: from_secret: DOCKER_USERNAME password: from_secret: DOCKER_PASSWORD repo: gitea.bsidesolutions.net/bside-solutions/bside-webhook-proxy registry: gitea.bsidesolutions.net dockerfile: ./Dockerfile force_tag: true tags: - latest when: branch: - main volumes: - name: docker_sock host: path: /var/run/docker.sock --- kind: pipeline type: docker name: Deploy to Coolify steps: - name: Deploy Application (Staging) image: alpine/curl:latest environment: STAGING_COOLIFY_WEBHOOK_URL: from_secret: STAGING_COOLIFY_WEBHOOK_URL COOLIFY_DEPLOY_TOKEN: from_secret: COOLIFY_DEPLOY_TOKEN commands: - >- curl -X GET $STAGING_COOLIFY_WEBHOOK_URL -H "Authorization: Bearer $COOLIFY_DEPLOY_TOKEN" --fail-with-body when: branch: - test - name: Deploy Application (Production) image: alpine/curl:latest environment: PRODUCTION_COOLIFY_WEBHOOK_URL: from_secret: PRODUCTION_COOLIFY_WEBHOOK_URL COOLIFY_DEPLOY_TOKEN: from_secret: COOLIFY_DEPLOY_TOKEN commands: - >- curl -X GET $PRODUCTION_COOLIFY_WEBHOOK_URL -H "Authorization: Bearer $COOLIFY_DEPLOY_TOKEN" --fail-with-body when: branch: - main