Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert to helm chart #3

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1 @@
keys*.yaml

23 changes: 23 additions & 0 deletions .helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*.orig
*~
# Various IDEs
.project
.idea/
*.tmproj
.vscode/
23 changes: 23 additions & 0 deletions Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
apiVersion: v2
name: dssh
description: Keep your authorized keys up to date on a Kubernetes cluster.

# A chart can be either an 'application' or a 'library' chart.
#
# Application charts are a collection of templates that can be packaged into versioned archives
# to be deployed.
#
# Library charts provide useful utilities or functions for the chart developer. They're included as
# a dependency of application charts to inject those utilities and functions into the rendering
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
type: application

# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.1.0

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
appVersion: 1.16.0
19 changes: 3 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,31 +10,18 @@ while you are working on it.
### Deploying Your Public Keys

```
cp keys.yaml.example keys.yaml

# Edit keys.yaml to include your public keys

kubectl apply -f daemonset.yaml
kubectl apply -f keys.yaml
helm install dssh . --set "keys={ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMQWiTqUTFVUMASTPpWLd+tYqQD1BW3AKCZfaczsQvP5 user2@hostname,$(cat ~/.ssh/id_rsa.pub)}"
```

### Updating Your Public Keys

```
# Edit keys.yaml to update your public keys

kubectl apply -f keys.yaml
```

### Updating dssh

```
kubectl apply -f daemonset.yaml
helm upgrade dssh . --set "keys={ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMQWiTqUTFVUMASTPpWLd+tYqQD1BW3AKCZfaczsQvP5 user2@hostname,$(cat ~/.ssh/id_rsa.pub)}"
```

### Removing dssh
```
kubectl delete daemonset -n kube-system root-ssh-manager
helm delete dssh
```

### Notes
Expand Down
Empty file added charts/.gitkeep
Empty file.
8 changes: 0 additions & 8 deletions keys.yaml.example

This file was deleted.

Empty file added templates/NOTES.txt
Empty file.
Empty file added templates/_helpers.tpl
Empty file.
File renamed without changes.
9 changes: 9 additions & 0 deletions templates/keys.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: root-ssh-pubkeys
namespace: kube-system
data:
{{- range $index, $key := .Values.keys }}
mykey{{ $index }}: {{ $key | quote }}
{{- end }}
1 change: 1 addition & 0 deletions values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
keys: []