Skip to content

Commit

Permalink
And finally, the experiment. it did not work as i hoped
Browse files Browse the repository at this point in the history
  • Loading branch information
thecodebeneath committed Dec 20, 2023
1 parent 2cfede8 commit 3c93807
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 3 deletions.
24 changes: 21 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ cat /tmp/realm.json

Ref to use the "GitHub pages" feature to behave as a file server: https://github.com/technosophos/tscharts/tree/master

Package and publish chart
## Package and publish chart
```
helm package ./chart
mv helm-file-get-0.1.0.tgz docs
Expand All @@ -39,13 +39,31 @@ git commit -m "New chart index"
git push
```

One-timer to add GitHub page as a helm repo. This makes the `./docs` directory the repo url.
## One-timer to add GitHub page as a helm repo.
This makes the `./docs` directory the repo url.
```
helm repo add codebeneath https://thecodebeneath.github.io/helm-files-get
```

Use the repo to pull the remote chart
## Use the repo to pull the remote chart
```
helm repo update codebeneath
```

## Try a default install
```
cd install-from-repo
helm install myapp codebeneath/helm-file-get
```

> **this uses the chart packaged assets/realm.json file (the default)**
## Try to override using a file from local filesystem
```
helm install myapp codebeneath/helm-file-get --values override-values.yaml --version 0.2.0
```
> **this uses the chart packaged assets/junk.json file (from the override-values file).**
> **it does NOT take the local directory assets/junk.json file as I hoped.**
> **bummer.**
6 changes: 6 additions & 0 deletions install-from-repo/assets/junk.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"codebeneath-override": {
"id": "junk",
"value": "junk"
}
}
24 changes: 24 additions & 0 deletions install-from-repo/override-values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
replicaCount: 1
image:
repository: "hello-world"
tag: "1.0"
pullPolicy: IfNotPresent
service:
type: NodePort
port: 80

secrets:
realm-secret:
stringData:
realm.json: '{{ .Files.Get "assets/junk.json" }}'

extraVolumes: |-
- name: realm-vol
secret:
secretName: realm-secret
extraVolumeMounts: |-
- name: realm-vol
mountPath: /tmp/realm.json
subPath: realm.json

0 comments on commit 3c93807

Please sign in to comment.