aboutsummaryrefslogtreecommitdiff
path: root/Earthfile
diff options
context:
space:
mode:
Diffstat (limited to 'Earthfile')
-rw-r--r--Earthfile10
1 files changed, 9 insertions, 1 deletions
diff --git a/Earthfile b/Earthfile
index 6d4e33fe..830ffd31 100644
--- a/Earthfile
+++ b/Earthfile
@@ -5,8 +5,12 @@ FROM oven/bun:1.0.15-alpine
WORKDIR /due
all:
+ RUN apk add --update --no-cache git
+
+ COPY .git .git
+
BUILD +lint
- BUILD +docker
+ BUILD +docker --GIT_SHORT_SHA=$(git rev-parse --short HEAD)
BUILD +git
dev:
@@ -27,8 +31,12 @@ lint:
RUN bun --bun run check
docker:
+ ARG GIT_SHORT_SHA
+
COPY +build/build .
+ RUN echo "PUBLIC_GIT_SHORT_SHA=$GIT_SHORT_SHA" > .env
+
CMD ["bun", "--bun", "./index.js"]
SAVE IMAGE --push fuwn/due-next:latest