-
Notifications
You must be signed in to change notification settings - Fork 0
31 lines (27 loc) · 843 Bytes
/
build-linters.yml
File metadata and controls
31 lines (27 loc) · 843 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
31
name: build-push linters cache
on:
push:
branches: [main]
env:
REPO: ${{ github.repository }}
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: downcase REPO
run: |
echo "REPO=${GITHUB_REPOSITORY,,}" >>${GITHUB_ENV}
- uses: actions/checkout@v4
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build docker image
env:
TAG: ghcr.io/${{ env.REPO }}_linters:beta
DOCKER_BUILDKIT: '1'
run: |
echo $TAG
docker build --push --target=runtime -f .docker/lint.Dockerfile . -t $TAG --cache-to type=gha,mode=max --cache-from $TAG --build-arg BUILDKIT_INLINE_CACHE=1