mirror of
https://github.com/crawlab-team/crawlab.git
synced 2026-01-25 17:42:25 +01:00
chore: update Docker configuration and ignore files
- Updated .dockerignore to exclude temporary files, Git directories, and Node modules. - Modified Dockerfile to copy required modules from the parent directory and build the Go application from the backend directory.
This commit is contained in:
@@ -39,3 +39,10 @@ coverage.txt
|
||||
# Temporary files
|
||||
*.tmp
|
||||
*~
|
||||
**/tmp
|
||||
|
||||
# Git directories
|
||||
.git/
|
||||
|
||||
# Node modules
|
||||
**/node_modules
|
||||
|
||||
@@ -2,13 +2,15 @@ FROM golang:1.22.9 AS build
|
||||
|
||||
WORKDIR /go/src/app
|
||||
|
||||
COPY . .
|
||||
# Copy all required modules from parent directory
|
||||
COPY .. .
|
||||
|
||||
ENV GO111MODULE on
|
||||
|
||||
RUN go install -v ./...
|
||||
# Build from the backend directory which contains the main.go
|
||||
RUN cd backend && go install -v ./...
|
||||
|
||||
FROM alpine:3.14
|
||||
|
||||
# copy files
|
||||
# Copy the built binary
|
||||
COPY --from=build /go/bin/crawlab /go/bin/crawlab
|
||||
|
||||
Reference in New Issue
Block a user