Skip to content

Commit

Permalink
Updated deploy_test.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Sander Johansen committed Mar 5, 2025
1 parent 3575b0b commit 1aa3455
Showing 1 changed file with 3 additions and 15 deletions.
18 changes: 3 additions & 15 deletions .github/workflows/deploy_test.yml
Original file line number Diff line number Diff line change
@@ -1,28 +1,16 @@
name: Deploy to TDT4242 server
name: Deploy Dev Environment

on:
push:
branches:
- dev # Deploy Dev when pushing to `dev`
- staging # Deploy Staging when pushing to `staging`
- main # Deploy Prod when pushing to `main`
- main
workflow_dispatch:
inputs:
config:
description: "Which compose config file to deploy"
required: true
default: "docker-compose.dev.yml"
type: choice
options:
- "docker-compose.dev.yml"
- "docker-compose.stag.yml"
- "docker-compose.yml"

jobs:
deploy:
runs-on: self-hosted
env:
COMPOSE_FILE: ${{ github.ref == 'refs/heads/main' && 'docker-compose.yml' || github.ref == 'refs/heads/staging' && 'docker-compose.stag.yml' || 'docker-compose.dev.yml' }}
COMPOSE_FILE: 'docker-compose.dev.yml'

steps:
- name: Checkout repository
Expand Down

0 comments on commit 1aa3455

Please sign in to comment.