From 7ed6c4cc7aa42f93d629b3710a814fe82da51405 Mon Sep 17 00:00:00 2001 From: Thomas Moore Date: Fri, 3 Nov 2023 15:27:34 +0000 Subject: [PATCH] Fix dockerfile, attempt to prune with bun --- .github/workflows/deployments.yml | 4 +--- apps/backend/Dockerfile | 6 +++--- apps/frontend/Dockerfile | 6 +++--- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/.github/workflows/deployments.yml b/.github/workflows/deployments.yml index 6f9a16f..2989b25 100644 --- a/.github/workflows/deployments.yml +++ b/.github/workflows/deployments.yml @@ -6,9 +6,7 @@ on: - main pull_request: {} -permissions: - actions: write - contents: read +permissions: write-all env: CI: true diff --git a/apps/backend/Dockerfile b/apps/backend/Dockerfile index 70abc6c..44e02e9 100644 --- a/apps/backend/Dockerfile +++ b/apps/backend/Dockerfile @@ -1,12 +1,12 @@ -FROM node:18-alpine AS node FROM oven/bun:alpine AS bun -FROM base AS builder +FROM bun AS builder RUN apk add --no-cache libc6-compat RUN apk update RUN pip3 install streamlink WORKDIR /app -RUN yarn global add turbo +RUN bun install --global turbo +RUN bunx @turbo/workspaces@latest convert ./ yarn --skip-install COPY . . RUN turbo prune --scope @haishin/backend --docker diff --git a/apps/frontend/Dockerfile b/apps/frontend/Dockerfile index 5d480b4..f1622e7 100644 --- a/apps/frontend/Dockerfile +++ b/apps/frontend/Dockerfile @@ -1,11 +1,11 @@ -FROM node:18-alpine AS node FROM oven/bun:alpine AS bun -FROM node AS builder +FROM bun AS builder RUN apk add --no-cache libc6-compat RUN apk update WORKDIR /app -RUN yarn global add turbo +RUN bun install --global turbo +RUN bunx @turbo/workspaces@latest convert ./ yarn --skip-install COPY . . RUN turbo prune --scope @haishin/frontend --docker