fix: caddy setup in dockerfile
This commit is contained in:
@@ -18,9 +18,10 @@ WORKDIR /usr/share/caddy
|
||||
# Copy built static files from the builder stage
|
||||
COPY --from=builder /app/dist .
|
||||
|
||||
# Expose the port Caddy will listen on
|
||||
# Copy our local Caddyfile config
|
||||
COPY Caddyfile /etc/caddy/Caddyfile
|
||||
|
||||
EXPOSE 3000
|
||||
|
||||
# Start Caddy as a file server with SPA support
|
||||
# It serves files from the current dir and redirects unknown paths to index.html
|
||||
CMD ["caddy", "file-server", "--listen", ":3000", "--try-files", "index.html"]
|
||||
# Start caddy using the config file
|
||||
CMD ["caddy", "run", "--config", "/etc/caddy/Caddyfile", "--adapter", "caddyfile"]
|
||||
|
||||
Reference in New Issue
Block a user