forked from seekr-osint/seekr
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
37 lines (24 loc) · 782 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# Use the official Go image as the base image
FROM golang:1.20-alpine3.16 AS build
# Set the working directory inside the container
WORKDIR /app
# Copy the source code to the container
COPY . .
RUN go mod download
RUN apk add --no-cache nodejs npm
# Install TypeScript
RUN npm install -g typescript
RUN go generate ./...
RUN tsc --project web --watch false
# Build the Go binary
RUN go build -o seekr main.go
# Use a lightweight base image
FROM alpine:3.18
# Copy the Seekr binary from the build container to the final container
COPY --from=build /app/seekr /bin/seekr
# Set the working directory inside the container
WORKDIR /app
# Expose the ports that the application will run on
EXPOSE 8569
# Start the Seekr app
CMD ["/bin/seekr","--ip","0.0.0.0","--port","8569"]