Compare commits
2 Commits
master
...
sohail/doc
Author | SHA1 | Date | |
---|---|---|---|
95f6a735a0 | |||
0bb44fc80b |
@ -10,4 +10,4 @@
|
||||
!/LICENSE
|
||||
!/README.md
|
||||
!/go.*
|
||||
!/.env.example
|
||||
!/.env
|
4
.github/workflows/docker.yaml
vendored
4
.github/workflows/docker.yaml
vendored
@ -45,7 +45,9 @@ jobs:
|
||||
with:
|
||||
context: ./
|
||||
file: ./Dockerfile
|
||||
platforms: linux/amd64
|
||||
platforms:
|
||||
- linux/amd64
|
||||
- linux/arm64
|
||||
push: true
|
||||
build-args: |
|
||||
BUILD=${{ env.RELEASE_SHORT_COMMIT }}
|
||||
|
@ -18,7 +18,7 @@ RUN make VISE_PATH=/build/go-vise -B
|
||||
WORKDIR /build
|
||||
RUN echo "Building on $BUILDPLATFORM, building for $TARGETPLATFORM"
|
||||
RUN go mod download
|
||||
RUN go build -tags logtrace -o ussd-africastalking -ldflags="-X main.build=${BUILD} -s -w" cmd/africastalking/main.go
|
||||
RUN go build -o ussd-africastalking -ldflags="-X main.build=${BUILD} -s -w" cmd/africastalking/main.go
|
||||
|
||||
FROM debian:bookworm-slim
|
||||
|
||||
@ -33,8 +33,7 @@ COPY --from=build /build/ussd-africastalking .
|
||||
COPY --from=build /build/LICENSE .
|
||||
COPY --from=build /build/README.md .
|
||||
COPY --from=build /build/services ./services
|
||||
COPY --from=build /build/.env.example .
|
||||
RUN mv .env.example .env
|
||||
COPY --from=build /build/.env .
|
||||
|
||||
EXPOSE 7123
|
||||
|
||||
|
@ -41,13 +41,10 @@ func buildConnStr() string {
|
||||
dbName := initializers.GetEnv("DB_NAME", "")
|
||||
port := initializers.GetEnv("DB_PORT", "5432")
|
||||
|
||||
connString := fmt.Sprintf(
|
||||
return fmt.Sprintf(
|
||||
"postgres://%s:%s@%s:%s/%s",
|
||||
user, password, host, port, dbName,
|
||||
)
|
||||
logg.Debugf("pg conn string", "conn", connString)
|
||||
|
||||
return connString
|
||||
}
|
||||
|
||||
func NewMenuStorageService(dbDir string, resourceDir string) *MenuStorageService {
|
||||
|
Loading…
Reference in New Issue
Block a user