feat: 默认api应用的host和path
continuous-integration/drone/push Build is passing Details

master
icechen 2022-01-05 16:59:02 +08:00
parent 9d1867e70f
commit 3bbe609404
3 changed files with 17 additions and 1 deletions

View File

@ -10,7 +10,7 @@ ADD . .
RUN go mod tidy
RUN CGO_ENABLED=0 GOOS=linux go build -ldflags="-s -w" -o main
FROM alpine as drone_plugin
FROM reg.icechen.cn/alpine as drone_plugin
WORKDIR /go/src
#LABEL maintainer "The Prometheus Authors <prometheus-developers@googlegroups.com>"
COPY --from=builder /usr/share/zoneinfo /usr/share/zoneinfo

View File

@ -43,8 +43,16 @@ steps:
- image=reg.icechen.cn/{{ .NameSpace }}/api-{{ .Name }}
- imageTag=${DRONE_TAG}
- port={{ .Port }}
{{ if .Host }}
- host={{ .Host }}
{{ else }}
- host=api.zeus.seamlesser.com
{{ end }}
{{ if .Path }}
- path={{ .Path }}
{{ else }}
- path=/{{ .NameSpace }}/{{ .Name }}
{{ end }}
volumes:
- name: docker

View File

@ -43,8 +43,16 @@ steps:
- image=reg.icechen.cn/{{ .NameSpace }}/api-{{ .Name }}
- imageTag=${DRONE_COMMIT:0:8}
- port={{ .Port }}
{{ if .Host }}
- host=t{{ .Host }}
{{ else }}
- host=tapi.zeus.seamlesser.com
{{ end }}
{{ if .Path }}
- path={{ .Path }}
{{ else }}
- path=/{{ .NameSpace }}/{{ .Name }}
{{ end }}
volumes:
- name: docker