forked from JonasHiltl/openchangelog
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dockerize app & make config path configurable
- Loading branch information
Jonas Hiltl
committed
Jul 25, 2024
1 parent
026e06e
commit 7f7c143
Showing
9 changed files
with
99 additions
and
31 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 |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# copy of .gitignore | ||
tmp | ||
node_modules | ||
|
||
*.pem | ||
.env | ||
openchangelog.yml | ||
|
||
go.work* | ||
*.txt | ||
|
||
test.db | ||
.cache | ||
|
||
# extras | ||
.testdata | ||
.air.toml | ||
openchangelog.example.yml |
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 |
---|---|---|
|
@@ -3,7 +3,7 @@ node_modules | |
|
||
*.pem | ||
.env | ||
config.yaml | ||
openchangelog.yml | ||
|
||
go.work* | ||
*.txt | ||
|
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 |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# Non alpine because of CGO glibc dependency | ||
FROM golang:1.22 AS builder | ||
|
||
WORKDIR /build | ||
ENV CGO_ENABLED=1 | ||
COPY go.mod . | ||
COPY go.sum . | ||
RUN go mod download | ||
|
||
COPY . . | ||
RUN go build -buildvcs=false -ldflags "-s -w -extldflags '-static'" -o ./openchangelog cmd/server.go | ||
|
||
FROM alpine | ||
|
||
WORKDIR /app | ||
COPY --from=builder /build/openchangelog ./openchangelog | ||
|
||
ENTRYPOINT ["/app/openchangelog"] |
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
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
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
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
services: | ||
openchangelog: | ||
build: . | ||
ports: | ||
- "80:80" | ||
volumes: | ||
- type: bind | ||
source: openchangelog.yml | ||
target: /etc/openchangelog.yml |
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
File renamed without changes.