Skip to content

Commit

Permalink
fix: clean up default-queue secret
Browse files Browse the repository at this point in the history
There were some ugly leftovers from an earlier time.

Signed-off-by: Nick Mitchell <nickm@us.ibm.com>
  • Loading branch information
starpit committed Aug 4, 2024
1 parent 443c1f5 commit b1ab849
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 5 deletions.
10 changes: 5 additions & 5 deletions charts/templates/default-queue.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ metadata:
app.kubernetes.io/component: taskqueue
app.kubernetes.io/instance: {{ .Release.Name }}
type: Opaque
data:
bucket: {{ .Values.taskqueue.bucket | default .Values.taskqueue.dataset | b64enc }}
endpoint: {{ .Values.taskqueue.endpoint | default .Values.global.s3Endpoint | b64enc }}
accessKeyID: {{ .Values.taskqueue.accessKey | default .Values.global.s3AccessKey | b64enc }}
secretAccessKey: {{ .Values.taskqueue.secretKey | default .Values.global.s3SecretKey | b64enc }}
stringData:
bucket: {{ .Values.taskqueue.bucket }}
endpoint: {{ .Values.taskqueue.endpoint }}
accessKeyID: {{ .Values.taskqueue.accessKey }}
secretAccessKey: {{ .Values.taskqueue.secretKey }}
9 changes: 9 additions & 0 deletions pkg/fe/linker/configure.go
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,15 @@ func Configure(appname, runname, namespace, templatePath string, internalS3Port
runnameMax40 = runname[:40]
}

if queueSpec.Endpoint == "" {
queueSpec.Endpoint = fmt.Sprintf("http://%s-lunchpail-s3.%s.svc.cluster.local:%d", runnameMax40, systemNamespace, internalS3Port)
queueSpec.AccessKey = "lunchpail"
queueSpec.SecretKey = "lunchpail"
}
if queueSpec.Bucket == "" {
queueSpec.Bucket = queueSpec.Name
}

yaml := fmt.Sprintf(`
global:
unused: %s # "" (1)
Expand Down

0 comments on commit b1ab849

Please sign in to comment.