-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.yml
More file actions
30 lines (25 loc) · 780 Bytes
/
build.yml
File metadata and controls
30 lines (25 loc) · 780 Bytes
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
name: CI
on:
push:
branches:
- main
pull_request:
jobs:
build:
runs-on: ubuntu-latest
permissions:
packages: write
steps:
- uses: actions/checkout@v4
- name: Setup production config
run: cp config.production.yaml config.yaml
- name: Docker login
run: echo ${{ secrets.GITHUB_TOKEN }} | docker login -u ${{ github.repository_owner }} --password-stdin ghcr.io
- name: Build and Push
run: |
docker run --rm --privileged \
-v /home/runner/.docker:/root/.docker \
-v /run/docker.sock:/run/docker.sock:rw \
-v $(pwd):/data \
homeassistant/amd64-builder --amd64 --aarch64 -t /data \
--no-cache --docker-hub ghcr.io/${{ github.repository_owner }}