Skip to content

Commit c8ef410

Browse files
committed
lint / check things
1 parent c253d8f commit c8ef410

4 files changed

Lines changed: 38 additions & 7 deletions

File tree

.github/workflows/deploy.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,21 +8,19 @@ on:
88

99
permissions:
1010
id-token: write
11-
contents: write
11+
contents: read
1212

1313
jobs:
1414
build-deploy:
1515
strategy:
1616
matrix:
17-
env: [dev, prod, test]
17+
env: [dev, test, prod]
1818
name: Build Docker
1919
runs-on: ubuntu-latest
2020
environment: ${{ matrix.env }}
2121
steps:
2222
- name: Checkout code
2323
uses: actions/checkout@v6
24-
with:
25-
ref: ${{ github.ref }}
2624

2725
- name: Configure AWS Credentials
2826
uses: aws-actions/configure-aws-credentials@v5
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Lint Workflows
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- '.github/workflows/**'
7+
8+
permissions:
9+
contents: read
10+
11+
jobs:
12+
actionlint:
13+
name: actionlint
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v4
17+
- name: Run actionlint
18+
uses: rhysd/actionlint@v1
19+
20+
yamllint:
21+
name: yamllint
22+
runs-on: ubuntu-latest
23+
steps:
24+
- uses: actions/checkout@v4
25+
- name: Run yamllint
26+
run: yamllint .github/workflows/

.github/workflows/pr.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,17 +4,18 @@ on:
44
pull_request:
55
workflow_call:
66

7+
permissions:
8+
contents: read
9+
710
jobs:
811
docker-build:
912
name: Build Docker
1013
runs-on: ubuntu-latest
1114
steps:
1215
- name: Checkout code
1316
uses: actions/checkout@v6
14-
with:
15-
ref: ${{ github.ref }}
1617

17-
- name: Build, tag, and push the image to Amazon ECR
18+
- name: Build Docker image (local only)
1819
id: build-image
1920
env:
2021
ECR_REGISTRY: local.test

.yamllint.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
extends: default
2+
rules:
3+
line-length:
4+
max: 120
5+
truthy:
6+
allowed-values: ['true', 'false', 'on', 'off']

0 commit comments

Comments
 (0)