parent
bbec111997
commit
470fee2777
2 changed files with 17 additions and 1 deletions
|
@ -28,6 +28,22 @@ jobs:
|
||||||
- uses: https://code.forgejo.org/docker/setup-buildx-action@v3
|
- uses: https://code.forgejo.org/docker/setup-buildx-action@v3
|
||||||
name: Setup Docker BuildX system
|
name: Setup Docker BuildX system
|
||||||
|
|
||||||
|
- name: Set up Crystal cache
|
||||||
|
uses: actions/cache@v4
|
||||||
|
id: crystal-cache
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
~/.cache/crystal
|
||||||
|
lib
|
||||||
|
invidious
|
||||||
|
key: ${{ runner.os }}-crystal-${{ hashFiles('**/shard.lock') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-crystal-
|
||||||
|
|
||||||
|
- name: Install shards
|
||||||
|
if: steps.crystal-cache.outputs.cache-hit != 'true'
|
||||||
|
run: shards check || shards install --production
|
||||||
|
|
||||||
- name: Login to Docker Container Registry
|
- name: Login to Docker Container Registry
|
||||||
uses: https://code.forgejo.org/docker/login-action@v3.1.0
|
uses: https://code.forgejo.org/docker/login-action@v3.1.0
|
||||||
with:
|
with:
|
||||||
|
|
|
@ -21,7 +21,7 @@ COPY ./videojs-dependencies.yml ./videojs-dependencies.yml
|
||||||
|
|
||||||
RUN crystal spec --warnings all \
|
RUN crystal spec --warnings all \
|
||||||
--link-flags "-lxml2 -llzma"
|
--link-flags "-lxml2 -llzma"
|
||||||
RUN --mount=type=cache,target=/root/.cache/crystal if [[ "${release}" == 1 ]] ; then \
|
RUN --mount=type=cache,target=~/.cache/crystal if [[ "${release}" == 1 ]] ; then \
|
||||||
crystal build ./src/invidious.cr \
|
crystal build ./src/invidious.cr \
|
||||||
--release --mcpu=x86-64-v2 \
|
--release --mcpu=x86-64-v2 \
|
||||||
--static --warnings all \
|
--static --warnings all \
|
||||||
|
|
Loading…
Add table
Reference in a new issue