Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ RUN go build -o reverse-watch main.go

FROM gcr.io/distroless/base-debian12

WORKDIR /app
COPY --from=builder /app/reverse-watch /app/reverse-watch
COPY --from=builder /app/static/index.html /app/static/index.html

EXPOSE 80
CMD ["./app/reverse-watch"]
CMD ["./reverse-watch"]
4 changes: 4 additions & 0 deletions server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ func New(cfg config.Config, factory repository.Factory) (*Server, error) {

r.Use(rwmiddleware.FactoryMiddleware(factory))

r.Get("/", func(w http.ResponseWriter, r *http.Request) {
http.ServeFile(w, r, "static/index.html")
})
Comment thread
zedimytch marked this conversation as resolved.

r.Mount("/api", api.Router())

return &Server{
Expand Down
Loading
Loading