Skip to content

Commit 34013dd

Browse files
authored
Merge pull request #70 from LibrePCB/ci
Setup CI to build Windows image
2 parents 8638cf3 + 7a59720 commit 34013dd

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

.github/workflows/main.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: CI
2+
3+
on: [push, pull_request]
4+
5+
env:
6+
REGISTRY: "ghcr.io"
7+
IMAGE: "ghcr.io/librepcb/docker-librepcb-dev"
8+
9+
jobs:
10+
windowsservercore-ltsc2025:
11+
name: Windows Server Core LTSC2025
12+
runs-on: windows-2025
13+
env:
14+
TAG: "windowsservercore-ltsc2025-qt6.6-64bit"
15+
permissions:
16+
contents: read
17+
packages: write
18+
steps:
19+
- uses: actions/checkout@v4
20+
# First we pull the image, hopefully it will act as a cache to speed
21+
# up the build.
22+
- name: Docker Pull
23+
run: docker pull "${{ env.IMAGE }}:${{ env.TAG }}"
24+
continue-on-error: true
25+
- name: Docker Build
26+
run: docker build -t "${{ env.IMAGE }}:${{ env.TAG }}-ci" "${{ env.TAG }}"
27+
- name: Docker Login
28+
if: ${{ success() && (github.event_name == 'push') }}
29+
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login "${{ env.REGISTRY }}" -u "${{ github.actor }}" --password-stdin
30+
- name: Docker Push
31+
if: ${{ success() && (github.event_name == 'push') }}
32+
run: docker push "${{ env.IMAGE }}:${{ env.TAG }}-ci"
33+
- name: Docker Logout
34+
if: ${{ github.event_name == 'push' }}
35+
run: docker logout "${{ env.REGISTRY }}"
36+
continue-on-error: true

0 commit comments

Comments
 (0)