generated from devops-infra/template-action
-
Notifications
You must be signed in to change notification settings - Fork 10
94 lines (78 loc) · 2.01 KB
/
auto-create-pull-request.yml
File metadata and controls
94 lines (78 loc) · 2.01 KB
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
name: (Auto) Create Pull Request
on:
push:
branches-ignore:
- master
- dependabot/**
permissions:
contents: read
packages: write
pull-requests: write
jobs:
lint:
name: Lint
runs-on: ubuntu-24.04-arm
steps:
- name: Checkout
uses: actions/checkout@v6
with:
fetch-depth: 0
fetch-tags: true
- name: Install Task
uses: arduino/setup-task@v2.0.0
with:
version: 3.x
- name: Run linters
run: task lint
build-and-push:
name: Build and push
runs-on: ubuntu-24.04-arm
needs: [lint]
steps:
- name: Checkout
uses: actions/checkout@v6
with:
fetch-depth: 0
fetch-tags: true
- name: Install Task
uses: arduino/setup-task@v2.0.0
with:
version: 3.x
- name: Install Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Install QEMU
uses: docker/setup-qemu-action@v3
with:
image: tonistiigi/binfmt:latest
platforms: amd64,arm64
- name: Get Docker commands
run: task docker:cmds
- name: Build and push test image
env:
DOCKER_TOKEN: ${{ secrets.DOCKER_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: task docker:push
- name: Inspect image
run: task docker:push:inspect
pull-request:
name: Pull Request
runs-on: ubuntu-24.04-arm
steps:
- name: Checkout
uses: actions/checkout@v6
with:
fetch-depth: 0
fetch-tags: true
- name: Install Task
uses: arduino/setup-task@v2.0.0
with:
version: 3.x
- name: Get template
run: task git:get-pr-template
- name: Create Pull Request
uses: devops-infra/action-pull-request@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
assignee: ${{ github.actor }}
template: .tmp/PULL_REQUEST_TEMPLATE.md
get_diff: true