forked from galalmounir/openwrt-image-builder
-
Notifications
You must be signed in to change notification settings - Fork 0
48 lines (43 loc) · 1.12 KB
/
router-image.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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: OpenWRT Image Build
on:
push:
branches: ['release', 'main']
paths:
- Dockerfile
- devices/**
pull_request:
branches: [ "main" ]
paths:
- Dockerfile
- devices/**
env:
REGISTRY: ghcr.io
IMAGE_NAME: "openwrt-image"
jobs:
OpenWRT-Image-Build:
#runs-on: ubuntu-latest
runs-on: jenkins
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
with:
images: ${{ env.REGISTRY }}/NinuxBasilicata/${{ env.IMAGE_NAME }}
- name: Build image
uses: docker/[email protected]
with:
push: false
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
outputs: type=local,dest=image
build-args: SHOULD_ADD_HAASMESH=1
- name: Archive Built router image
uses: actions/upload-artifact@v3
with:
name: ${{ env.IMAGE_NAME }}
path: image