Files
truecharts/charts/dev/livebook/values.yaml
Michael Ruoss 0a85155bf1 feat(livebook) AWS credentials and data folder (#17555)
**Description**
<!--
Please include a summary of the change and which issue is fixed. Please
also include relevant motivation and context. List any dependencies that
are required for this change.
-->

Followup after #16880. I'm still waiting for the next release of
Livebook before moving this to the stable train as it comes with a fix
for clustering
(https://github.com/phoenixframework/dns_cluster/issues/10).

* Adding variables for AWS credentials
* moved the variables in `questions.yaml` to the `podOptions` section.
This ways I can put secret values inside secrets.
* Run as non-root by default
* Point the `LIVEBOOK_DATA_PATH` to the PVC in order to persist the
config (e.g. aws storage config)

**⚙️ Type of change**

- [x] ⚙️ Feature/App addition
- [ ] 🪛 Bugfix
- [ ] ⚠️ Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [x] 🔃 Refactor of current code

**🧪 How Has This Been Tested?**
<!--
Please describe the tests that you ran to verify your changes. Provide
instructions so we can reproduce. Please also list any relevant details
for your test configuration
-->

Using `helm template` to verify the resulting manifest.

**📃 Notes:**
<!-- Please enter any other relevant information here -->

**✔️ Checklist:**

- [x] ⚖️ My code follows the style guidelines of this project
- [x] 👀 I have performed a self-review of my own code
- [ ] #️⃣ I have commented my code, particularly in hard-to-understand
areas
- [ ] 📄 I have made corresponding changes to the documentation
- [x] ⚠️ My changes generate no new warnings
- [ ] 🧪 I have added tests to this description that prove my fix is
effective or that my feature works
- [x] ⬆️ I increased versions for any altered app according to semantic
versioning

---

_Please don't blindly check all the boxes. Read them and only check
those that apply.
Those checkboxes are there for the reviewer to see what is this all
about and
the status of this PR with a quick glance._
2024-02-03 12:37:54 +02:00

75 lines
2.3 KiB
YAML

image:
pullPolicy: IfNotPresent
repository: ghcr.io/livebook-dev/livebook
tag: 0.12.1@sha256:11c5691efc8e35bf0eee9c336ff029e674bcf4146ec39021b1ef75c1b17fb775
persistence:
data:
enabled: true
mountPath: /data
portal:
open:
enabled: true
securityContext:
container:
readOnlyRootFilesystem: false
runAsGroup: 568
runAsUser: 568
service:
main:
ports:
main:
port: 8787
headless:
enabled: true
primary: false
clusterIP: None
ports:
headless:
enabled: true
port: "{{ .Values.service.main.ports.main.port }}"
workload:
main:
podSpec:
containers:
main:
env:
# A_ because these variables are sorted alphabetically and this one needs to come first.
A_POD_IP:
fieldRef:
fieldPath: status.podIP
LIVEBOOK_CLUSTER: '{{ printf "dns:%s-headless" (include "tc.v1.common.lib.chart.names.fullname" .) }}'
LIVEBOOK_DISTRIBUTION: name
LIVEBOOK_NODE: livebook@$(A_POD_IP)
LIVEBOOK_PORT: "{{ .Values.service.main.ports.main.port }}"
LIVEBOOK_HOME: "{{ .Values.persistence.data.mountPath }}"
LIVEBOOK_DATA_PATH: "{{ .Values.persistence.data.mountPath }}"
LIVEBOOK_SECRET_KEY_BASE:
secretKeyRef:
name: secrets
key: LIVEBOOK_SECRET_KEY_BASE
LIVEBOOK_COOKIE:
secretKeyRef:
name: secrets
key: LIVEBOOK_COOKIE
LIVEBOOK_PASSWORD:
secretKeyRef:
name: secrets
key: LIVEBOOK_PASSWORD
LIVEBOOK_DEBUG: '{{ ternary "true" "false" .Values.livebook.debug }}'
LIVEBOOK_UPDATE_INSTRUCTIONS_URL: "{{ .Values.livebook.updateInstructionsUrl }}"
LIVEBOOK_AWS_CREDENTIALS: '{{ ternary "true" "false" .Values.livebook.awsCredentials.enabled }}'
AWS_ACCESS_KEY_ID: "{{ .Values.livebook.awsCredentials.accessKeyId }}"
AWS_SECRET_ACCESS_KEY:
secretKeyRef:
name: secrets
key: AWS_SECRET_ACCESS_KEY
# default values
livebook:
password: ""
updateInstructionsUrl: ""
debug: false
awsCredentials:
enabled: false
accessKeyId: ""
secretAccessKey: ""