Frontend added docker compose

pull/3/head
TZGyn 2 years ago
parent d4f9fcfda8
commit e8ea47e4df
Signed by: TZGyn
GPG Key ID: 122EAF77AE81FD4A

@ -0,0 +1,15 @@
FROM docker.io/oven/bun
RUN mkdir /shortener-frontend
WORKDIR /shortener-frontend
COPY ./package.json ./
COPY ./bun.lockb ./
RUN bun install
COPY . .
RUN bun run build
ENTRYPOINT [ "bun", "run", "preview", "--host" ]

@ -0,0 +1,15 @@
---
# docker-compose.yml
version: '3.9'
services:
app:
image: oven/bun
container_name: linkshortener_vue_dev
# override default entrypoint allows us to do `bun install` before serving
entrypoint: []
# execute bun install before we start the dev server in watch mode
command: /bin/sh -c 'bun install && bun run dev --host'
# expose the right ports
ports: [5173:5173]
# setup a host mounted volume to sync changes to the container
volumes: [./:/home/bun/app]
Loading…
Cancel
Save