mirror of
https://github.com/amir20/dozzle.git
synced 2025-12-24 14:31:44 +01:00
* WIP vue3 * WIP vue3 * WIP vue3 * Migrates to vitejs * Fixes js tests and removes not needed modules * Fixes unmount * Updates to use css instead for space * Fixes tests and rebases one more time * Uses orgua * Fixes migrations bugs with oruga and fixes scroll * Fixes v-deep * Fixes icons to prod * Fixes icons to prod * Adds favicon back * Transitions some to composition api * Updates another component to comp api * Cleans defineProps * Updates log messages * Moves more to compose api * Cleans up styles and rewrites event source * Tries to fix DOMPurify * Removes postcss * WIP typescript * Improves importing * Converts all to ts * Converts main to ts * Makes changes for tsconfig * Moves more to ts * Adds typing to store * More typing * Updates to ts * Updates the rest to ts * Fixes computes * Fixes unmount * Adds cypress with custom base fixed * Fixes jest tests * Fixes golang tests * Adds gitignore for cypress * Removes int in favor of e2e with cypress * Tries to fix int tests again * Adds title * Updates e2e tests * Uses vue for isMobile * Removes app spec * Cleans up docker * Adds drop down for settings * Fixes bug with restart * Fixes scroll up bug * Adds tests for light mode
59 lines
1.1 KiB
Docker
59 lines
1.1 KiB
Docker
# Build assets
|
|
FROM node:17-alpine as node
|
|
|
|
RUN apk add --no-cache git openssh make g++ util-linux curl python3 && curl -f https://get.pnpm.io/v6.16.js | node - add --global pnpm
|
|
|
|
WORKDIR /build
|
|
|
|
# Install dependencies from lock file
|
|
COPY pnpm-lock.yaml ./
|
|
RUN pnpm fetch --prod
|
|
|
|
# Copy files
|
|
COPY package.json .* vite.config.ts index.html ./
|
|
|
|
# Copy assets to build
|
|
COPY assets ./assets
|
|
|
|
# Install dependencies
|
|
RUN pnpm install -r --offline --prod
|
|
|
|
# Do the build
|
|
RUN pnpm build
|
|
|
|
FROM golang:1.17.3-alpine AS builder
|
|
|
|
RUN apk add --no-cache git ca-certificates && mkdir /dozzle
|
|
|
|
WORKDIR /dozzle
|
|
|
|
# Copy go mod files
|
|
COPY go.* ./
|
|
RUN go mod download
|
|
|
|
# Copy assets built with node
|
|
COPY --from=node /build/dist ./dist
|
|
|
|
# Copy all other files
|
|
COPY analytics ./analytics
|
|
COPY docker ./docker
|
|
COPY web ./web
|
|
COPY main.go ./
|
|
|
|
# Args
|
|
ARG TAG=dev
|
|
|
|
# Build binary
|
|
RUN CGO_ENABLED=0 go build -ldflags "-s -w -X main.version=$TAG" -o dozzle
|
|
|
|
FROM scratch
|
|
|
|
ENV PATH=/bin
|
|
|
|
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt
|
|
COPY --from=builder /dozzle/dozzle /dozzle
|
|
|
|
EXPOSE 8080
|
|
|
|
ENTRYPOINT ["/dozzle"]
|