↳
In-reply-to
»
ASCIIFlow This is kind of cool π
β€ Read More
Unfortunately the resulting Docker image for the older version of tldraw is 1.7GB π±
$ docker images | grep tldraw
r.mills.io/prologic/tldraw latest 5b0e374ed1cc 8 minutes ago 1.69GB
if anyone knows anything about this shitty Javascript/NPM/Yarn ecosystem and how to make this smaller, do let me know π
Hereβs the Dockerfile
:
# Written by Ange Cesari
# Use official Node.js based on Alpine
FROM node:16-alpine
# Install Yarn
RUN apk add --no-cache yarn
# Create dir for application
WORKDIR /usr/src/app
# Copy files from apps/www to workdir
COPY apps/www .
# Change workdir to apps/www
WORKDIR /usr/src/app/apps/www
# Install dependencies with yarn
RUN yarn
# Expose application port (5420 for the tldraw/example)
EXPOSE 3000
# Run application in dev mode
CMD ["yarn", "dev"]