-
Notifications
You must be signed in to change notification settings - Fork 0
32 lines (27 loc) · 922 Bytes
/
run-docker.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: Run Project with Docker
# Trigger on push to main branch or on pull requests targeting main
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build-and-run-docker:
runs-on: ubuntu-latest
steps:
# Step 1: Checkout the repository code
- name: Checkout repository
uses: actions/checkout@v3
# Step 2: Build the Docker image
# This will use the Dockerfile at the root of your repo to build the image
- name: Build Docker image
run: docker build -t mzn-app .
# Step 3: Run the Docker container
# This runs your entire project as defined by CMD in the Dockerfile
- name: Run Docker container
run: docker run --rm -v ${{ github.workspace }}/res:/app/res mzn-app "16-12"
- name: Upload results
uses: actions/upload-artifact@v4
with:
name: mzn-results
path: ./res