You've already forked AstralRinth
forked from didirus/AstralRinth
Fix actions to use build cache
This commit is contained in:
11
.github/workflows/docker-compile-master.yml
vendored
11
.github/workflows/docker-compile-master.yml
vendored
@@ -13,6 +13,17 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
-
|
||||||
|
name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v1
|
||||||
|
-
|
||||||
|
name: Cache Docker layers
|
||||||
|
uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: /tmp/.buildx-cache
|
||||||
|
key: ${{ runner.os }}-buildx-${{ github.sha }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-buildx-
|
||||||
- name: Build and push Docker images
|
- name: Build and push Docker images
|
||||||
uses: docker/build-push-action@v1
|
uses: docker/build-push-action@v1
|
||||||
with:
|
with:
|
||||||
|
|||||||
11
.github/workflows/docker-compile-tag.yml
vendored
11
.github/workflows/docker-compile-tag.yml
vendored
@@ -14,6 +14,17 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
-
|
||||||
|
name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v1
|
||||||
|
-
|
||||||
|
name: Cache Docker layers
|
||||||
|
uses: actions/cache@v2
|
||||||
|
with:
|
||||||
|
path: /tmp/.buildx-cache
|
||||||
|
key: ${{ runner.os }}-buildx-${{ github.sha }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-buildx-
|
||||||
- name: Build and push Docker images
|
- name: Build and push Docker images
|
||||||
uses: docker/build-push-action@v1
|
uses: docker/build-push-action@v1
|
||||||
with:
|
with:
|
||||||
|
|||||||
29
.github/workflows/docker-compile.yml
vendored
29
.github/workflows/docker-compile.yml
vendored
@@ -8,18 +8,29 @@ on:
|
|||||||
env:
|
env:
|
||||||
CARGO_TERM_COLOR: always
|
CARGO_TERM_COLOR: always
|
||||||
SQLX_OFFLINE: true
|
SQLX_OFFLINE: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- name: Build and push Docker images
|
-
|
||||||
uses: docker/build-push-action@v1
|
name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v1
|
||||||
|
-
|
||||||
|
name: Cache Docker layers
|
||||||
|
uses: actions/cache@v2
|
||||||
with:
|
with:
|
||||||
username: ${{ github.actor }}
|
path: /tmp/.buildx-cache
|
||||||
password: ${{ secrets.GITHUB_TOKEN }}
|
key: ${{ runner.os }}-buildx-${{ github.sha }}
|
||||||
registry: docker.pkg.github.com
|
restore-keys: |
|
||||||
repository: modrinth/labrinth/labrinth
|
${{ runner.os }}-buildx-
|
||||||
tag_with_ref: true
|
- name: Build Docker images
|
||||||
tag_with_sha: true
|
uses: docker/build-push-action@v1
|
||||||
|
with:
|
||||||
|
push: false
|
||||||
|
username: ${{ github.actor }}
|
||||||
|
password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
registry: docker.pkg.github.com
|
||||||
|
repository: modrinth/labrinth/labrinth
|
||||||
|
tag_with_ref: true
|
||||||
|
tag_with_sha: true
|
||||||
Reference in New Issue
Block a user