Remove cache step from cuttingedge workflow, set --platform to TARGETPLATFORM instead
This commit is contained in:
parent
a9fcc93670
commit
34c62e8658
19
.github/workflows/docker-image-cuttingedge.yml
vendored
19
.github/workflows/docker-image-cuttingedge.yml
vendored
@ -12,25 +12,6 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Clear cache
|
|
||||||
uses: actions/github-script@v6
|
|
||||||
with:
|
|
||||||
script: |
|
|
||||||
console.log("About to clear")
|
|
||||||
const caches = await github.rest.actions.getActionsCacheList({
|
|
||||||
owner: context.repo.owner,
|
|
||||||
repo: context.repo.repo,
|
|
||||||
})
|
|
||||||
for (const cache of caches.data.actions_caches) {
|
|
||||||
console.log(cache)
|
|
||||||
github.rest.actions.deleteActionsCacheById({
|
|
||||||
owner: context.repo.owner,
|
|
||||||
repo: context.repo.repo,
|
|
||||||
cache_id: cache.id,
|
|
||||||
})
|
|
||||||
}
|
|
||||||
console.log("Clear completed")
|
|
||||||
|
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
# syntax=docker/dockerfile:1
|
# syntax=docker/dockerfile:1
|
||||||
ARG DOTNET=8.0
|
ARG DOTNET=8.0
|
||||||
|
|
||||||
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/runtime:$DOTNET AS base
|
FROM --platform=$TARGETPLATFORM mcr.microsoft.com/dotnet/runtime:$DOTNET AS base
|
||||||
WORKDIR /publish
|
WORKDIR /publish
|
||||||
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true
|
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true
|
||||||
ENV PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium
|
ENV PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium
|
||||||
@ -10,7 +10,7 @@ RUN apt-get update \
|
|||||||
&& apt-get autopurge -y \
|
&& apt-get autopurge -y \
|
||||||
&& apt-get autoclean -y
|
&& apt-get autoclean -y
|
||||||
|
|
||||||
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:$DOTNET AS build-env
|
FROM --platform=$TARGETPLATFORM mcr.microsoft.com/dotnet/sdk:$DOTNET AS build-env
|
||||||
WORKDIR /src
|
WORKDIR /src
|
||||||
|
|
||||||
COPY Tranga.sln /src
|
COPY Tranga.sln /src
|
||||||
@ -22,7 +22,7 @@ RUN dotnet restore /src/Tranga.sln
|
|||||||
COPY . /src/
|
COPY . /src/
|
||||||
RUN dotnet publish -c Release --property:OutputPath=/publish -maxcpucount:1
|
RUN dotnet publish -c Release --property:OutputPath=/publish -maxcpucount:1
|
||||||
|
|
||||||
FROM --platform=$BUILDPLATFORM base AS runtime
|
FROM --platform=$TARGETPLATFORM base AS runtime
|
||||||
EXPOSE 6531
|
EXPOSE 6531
|
||||||
ARG UNAME=tranga
|
ARG UNAME=tranga
|
||||||
ARG UID=1000
|
ARG UID=1000
|
||||||
|
Loading…
Reference in New Issue
Block a user