This repository was archived by the owner on Nov 9, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 5 files changed +46
-40
lines changed Expand file tree Collapse file tree 5 files changed +46
-40
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ FROM golang:1.15-buster AS build
2+
3+ RUN apt-get update && apt-get install -y --no-install-recommends bash curl git ca-certificates
4+ RUN curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
5+
6+ WORKDIR /go/src/github.com/analogj/lodestone-publisher/
7+
8+ ADD Gopkg.toml ./
9+ ADD Gopkg.lock ./
10+ ADD cmd ./cmd
11+ ADD pkg ./pkg
12+
13+ RUN dep ensure
14+ RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o ./bin/lodestone-email-publisher ./cmd/email-publisher/email-publisher.go
15+ RUN mkdir tmp
16+
17+ FROM scratch
18+ COPY --from=build /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/
19+ COPY --from=build /go/src/github.com/analogj/lodestone-publisher/tmp /tmp
20+ COPY --from=build /go/src/github.com/analogj/lodestone-publisher/bin/lodestone-email-publisher /lodestone-email-publisher
21+ CMD ["/lodestone-email-publisher"]
Original file line number Diff line number Diff line change 1+ FROM golang:1.15-buster AS build
2+
3+ RUN apt-get update && apt-get install -y --no-install-recommends bash curl git
4+ RUN curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
5+
6+ WORKDIR /go/src/github.com/analogj/lodestone-publisher/
7+
8+ ADD Gopkg.toml ./
9+ ADD Gopkg.lock ./
10+ ADD cmd ./cmd
11+ ADD pkg ./pkg
12+
13+ RUN dep ensure
14+ RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o lodestone-fs-publisher ./cmd/fs-publisher/fs-publisher.go
15+
16+ FROM scratch
17+ COPY --from=build /go/src/github.com/analogj/lodestone-publisher/lodestone-fs-publisher /lodestone-fs-publisher
18+ CMD ["/lodestone-fs-publisher"]
Original file line number Diff line number Diff line change 11# lodestone-publisher
22
33
4- # Local Development
4+ # How to build
55
6- ```
7- docker build --tag= lodestone-publisher .
8- docker run -v `pwd`:/go/src/github.com/analogj/ lodestone-publisher/ lodestone -publisher
6+ ``` bash
7+ docker build -f Dockerfile.fs -t lodestone-fs -publisher .
8+ docker run lodestone-fs -publisher
99
10+ docker build -f Dockerfile.email -t lodestone-email-publisher .
11+ docker run lodestone-email-processor
1012```
13+
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments