Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

Default to fluxctl use for getting git deploy key #1548

Merged
merged 2 commits into from
Nov 26, 2018
Merged
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
5 changes: 3 additions & 2 deletions chart/flux/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -154,10 +154,11 @@ The [configuration](#configuration) section lists all the parameters that can be
#### Setup Git deploy

At startup Flux generates a SSH key and logs the public key.
Find the SSH public key with:
Find the SSH public key by installing [fluxctl](../../site/fluxctl.md) and
running:

```sh
kubectl -n flux logs deployment/flux | grep identity.pub | cut -d '"' -f2
fluxctl identity
```

In order to sync your cluster state with GitHub you need to copy the public key and
Expand Down
25 changes: 8 additions & 17 deletions chart/flux/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -1,19 +1,10 @@
1. Get the application URL by running these commands:
{{- if contains "NodePort" .Values.service.type }}
export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ template "flux.fullname" . }})
export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}")
echo http://$NODE_IP:$NODE_PORT
{{- else if contains "LoadBalancer" .Values.service.type }}
NOTE: It may take a few minutes for the LoadBalancer IP to be available.
You can watch the status of by running 'kubectl get svc -w {{ template "flux.fullname" . }}'
export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ template "flux.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}')
echo http://$SERVICE_IP:{{ .Values.service.port }}
{{- else if contains "ClusterIP" .Values.service.type }}
export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app={{ template "flux.name" . }},release={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
kubectl -n {{ .Release.Namespace }} port-forward $POD_NAME 8080:3030 &
{{- end }}
Get the Git deploy key by either (a) running

2. Get the Git deploy key by running these commands:
export FLUX_POD=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app={{ template "flux.name" . }},release={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}")
kubectl -n {{ .Release.Namespace }} logs $FLUX_POD | grep identity.pub | cut -d '"' -f2
kubectl -n {{ .Release.Namespace }} logs deployment/{{ .Release.Name }} | grep identity.pub | cut -d '"' -f2

or by (b) installing fluxctl through
https://github.com/weaveworks/flux/blob/master/site/fluxctl.md#installing-fluxctl
and running:

fluxctl identity

8 changes: 3 additions & 5 deletions site/get-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,15 +74,13 @@ watch kubectl get pods --all-namespaces
## Giving write access

At startup Flux generates a SSH key and logs the public key. Find
the SSH public key with:
the SSH public key by installing [fluxctl](./fluxctl.md) and
runnning:

```sh
kubectl logs deployment/flux | grep identity.pub | cut -d '"' -f2
fluxctl identity
```

*Note:* If you have downloaded [fluxctl](./fluxctl.md) already, you can use
`fluxctl identity` as well.

In order to sync your cluster state with git you need to copy the
public key and create a deploy key with write access on your GitHub
repository.
Expand Down
5 changes: 3 additions & 2 deletions site/helm-get-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,11 @@ that you will need to add a deploy key to your fork of the
repository.

This is pretty straight-forward as Flux generates a SSH key and
logs the public key at startup. Find the SSH public key with:
logs the public key at startup. Find the SSH public key by
installing [fluxctl](./fluxctl.md) and running:

```sh
kubectl -n flux logs deployment/flux | grep identity.pub | cut -d '"' -f2
fluxctl identity
```

In order to sync your cluster state with git you need to copy the
Expand Down