A decentralized music tracking and discovery platform built on AT Protocol 🎵 rocksky.app
spotify atproto lastfm musicbrainz scrobbling listenbrainz

[web] setup docker and caddy server

+48
+9
apps/web/Caddyfile
···
··· 1 + :80 { 2 + root * /usr/share/caddy 3 + file_server 4 + 5 + @notStatic { 6 + not path /index.html /assets/* /favicon.ico 7 + } 8 + rewrite @notStatic /index.html 9 + }
+39
apps/web/Dockerfile
···
··· 1 + FROM node:22 AS builder 2 + 3 + RUN apt-get update && apt-get install -y curl 4 + 5 + RUN curl -fsSL https://bun.sh/install | bash 6 + 7 + RUN npm install -g turbo 8 + 9 + ENV PATH="/root/.bun/bin:${PATH}" 10 + 11 + WORKDIR /app 12 + 13 + COPY ./apps ./apps 14 + 15 + COPY ./crates ./crates 16 + 17 + COPY ./package.json ./package.json 18 + 19 + COPY ./bun.lock ./bun.lock 20 + 21 + COPY ./turbo.json ./turbo.json 22 + 23 + RUN bun install 24 + 25 + ARG VITE_API_URL 26 + 27 + ENV VITE_API_URL=$VITE_API_URL 28 + 29 + RUN turbo build --filter=@rocksky/web 30 + 31 + FROM caddy:alpine 32 + 33 + COPY --from=builder /app/apps/web/dist /usr/share/caddy 34 + 35 + COPY ./apps/web/Caddyfile /etc/caddy/Caddyfile 36 + 37 + EXPOSE 80 38 + 39 + CMD ["caddy", "run", "--config", "/etc/caddy/Caddyfile", "--adapter", "caddyfile"]