mirror of
https://github.com/AmruthPillai/Reactive-Resume.git
synced 2025-11-10 04:22:27 +10:00
29 lines
751 B
YAML
29 lines
751 B
YAML
name: Deploy Latest Version on DigitalOcean
|
|
|
|
on:
|
|
workflow_run:
|
|
workflows:
|
|
- Build and Push Docker Image
|
|
types:
|
|
- completed
|
|
|
|
jobs:
|
|
on-success:
|
|
runs-on: ubuntu-latest
|
|
if: ${{ github.event.workflow_run.conclusion == 'success' }}
|
|
steps:
|
|
- name: Install DigitalOcean CLI
|
|
uses: digitalocean/action-doctl@v2.2.0
|
|
with:
|
|
token: ${{ secrets.DIGITALOCEAN_TOKEN }}
|
|
|
|
- name: Create Deployment with Latest Version
|
|
run: doctl apps create-deployment ${{ secrets.DIGITALOCEAN_APP_ID }} --wait --force-rebuild
|
|
|
|
on-failure:
|
|
runs-on: ubuntu-latest
|
|
if: ${{ github.event.workflow_run.conclusion == 'failure' }}
|
|
steps:
|
|
- name: Abruptly end the worklfow
|
|
run: exit 1
|