-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f26bba3
commit 986ae33
Showing
1 changed file
with
14 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,23 @@ | ||
FROM golang:1.21-alpine | ||
FROM golang:1.21-alpine as builder | ||
|
||
WORKDIR /contracts-mon-bot | ||
WORKDIR /src | ||
|
||
COPY . . | ||
|
||
WORKDIR /contracts-mon-bot/user-contracts-mon | ||
WORKDIR /src/user-contracts-mon | ||
|
||
RUN go mod tidy | ||
RUN go mod tidy | ||
|
||
RUN go build -o contractsmon main.go | ||
|
||
|
||
FROM alpine | ||
|
||
WORKDIR /app | ||
|
||
COPY --from=builder /src/user-contracts-mon/contractsmon . | ||
|
||
COPY --from=builder /src/user-contracts-mon/.env . | ||
|
||
CMD ./contractsmon -e .env | ||
|