-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: kubernetes chart + dockerfile now using go 1.15 + adding more de…
…bug logs
- Loading branch information
Showing
9 changed files
with
80 additions
and
35 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,11 +1,11 @@ | ||
FROM debian:buster-slim as build | ||
|
||
RUN apt-get update && apt-get install -y curl && \ | ||
curl -sLo pleco.tgz https://github.com/Qovery/pleco/releases/download/v0.1/pleco_0.1_linux_amd64.tar.gz &&\ | ||
tar -xzf pleco.tgz | ||
FROM golang:1.15.5-buster as build | ||
|
||
ADD . /pleco | ||
WORKDIR /pleco | ||
RUN go get && go build -o /pleco.bin main.go | ||
|
||
FROM debian:buster-slim as run | ||
|
||
COPY --from=build /pleco /usr/bin/pleco | ||
CMD ["pleco", "start"] | ||
RUN apt-get update && apt-get install -y ca-certificates && apt-get clean | ||
COPY --from=build /pleco.bin /usr/bin/pleco | ||
CMD ["pleco", "start"] |
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 |
---|---|---|
@@ -1,47 +1,60 @@ | ||
{{- $kubefullname := include "kubernetes.fullname" . }} | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: {{ include "kubernetes.fullname" . }} | ||
labels: | ||
{{- include "kubernetes.labels" . | nindent 4 }} | ||
{{- include "kubernetes.labels" . | nindent 4 }} | ||
spec: | ||
replicas: {{ .Values.replicaCount }} | ||
selector: | ||
matchLabels: | ||
{{- include "kubernetes.selectorLabels" . | nindent 6 }} | ||
{{- include "kubernetes.selectorLabels" . | nindent 6 }} | ||
template: | ||
metadata: | ||
{{- with .Values.podAnnotations }} | ||
annotations: | ||
{{- toYaml . | nindent 8 }} | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
labels: | ||
{{- include "kubernetes.selectorLabels" . | nindent 8 }} | ||
{{- include "kubernetes.selectorLabels" . | nindent 8 }} | ||
spec: | ||
{{- with .Values.imagePullSecrets }} | ||
imagePullSecrets: | ||
{{- toYaml . | nindent 8 }} | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
serviceAccountName: {{ include "kubernetes.serviceAccountName" . }} | ||
securityContext: | ||
{{- toYaml .Values.podSecurityContext | nindent 8 }} | ||
{{- toYaml .Values.podSecurityContext | nindent 8 }} | ||
containers: | ||
- name: {{ .Chart.Name }} | ||
securityContext: | ||
{{- toYaml .Values.securityContext | nindent 12 }} | ||
{{- toYaml .Values.securityContext | nindent 12 }} | ||
image: "{{ .Values.image.repository }}:{{ .Values.image.plecoImageTag | default .Chart.AppVersion }}" | ||
imagePullPolicy: {{ .Values.image.pullPolicy }} | ||
command: [ "pleco", "start" ] | ||
args: | ||
- --level | ||
- "$(LOGLEVEL)" | ||
env: | ||
{{ range $key, $value := .Values.environmentVariables -}} | ||
- name: "{{ $key }}" | ||
valueFrom: | ||
secretKeyRef: | ||
name: {{ $kubefullname }} | ||
key: {{ $key }} | ||
{{ end }} | ||
resources: | ||
{{- toYaml .Values.resources | nindent 12 }} | ||
{{- toYaml .Values.resources | nindent 12 }} | ||
{{- with .Values.nodeSelector }} | ||
nodeSelector: | ||
{{- toYaml . | nindent 8 }} | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
{{- with .Values.affinity }} | ||
affinity: | ||
{{- toYaml . | nindent 8 }} | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
{{- with .Values.tolerations }} | ||
tolerations: | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} |
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 @@ | ||
apiVersion: v1 | ||
kind: Secret | ||
metadata: | ||
name: {{ include "kubernetes.fullname" . }} | ||
labels: | ||
{{- include "kubernetes.labels" . | nindent 4 }} | ||
type: Opaque | ||
stringData: | ||
{{- toYaml .Values.environmentVariables | nindent 2 }} |
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
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