Skip to content

Commit

Permalink
site.gitserverSSH -> cluster.gitserver.ssh
Browse files Browse the repository at this point in the history
  • Loading branch information
beyang committed May 23, 2018
1 parent 2d9111f commit f5a6cee
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 6 deletions.
2 changes: 1 addition & 1 deletion docs/install.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,6 @@ while deploying:
```bash
helm install --name sourcegraph -f values.yaml \
--set "site.awsCodeCommit[0].secretAccessKey"="$(cat secretAccessKeyFile)" \
--set "site.gitserverSSH.known_hosts"="$(cat known_hosts)" \
--set "cluster.gitserver.ssh.known_hosts"="$(cat known_hosts)" \
https://github.com/sourcegraph/datacenter/archive/latest.tar.gz
```
6 changes: 3 additions & 3 deletions templates/gitserver/gitserver-ssh.Secret.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{{if .Values.site.gitserverSSH }}
{{if .Values.cluster.gitserver.ssh }}
apiVersion: v1
data:
id_rsa: {{ include "expandedString" (dict "str" .Values.site.gitserverSSH.id_rsa "Files" .Files) | b64enc}}
known_hosts: {{ include "expandedString" (dict "str" .Values.site.gitserverSSH.known_hosts "Files" .Files) | b64enc }}
id_rsa: {{ include "expandedString" (dict "str" .Values.cluster.gitserver.ssh.id_rsa "Files" .Files) | b64enc}}
known_hosts: {{ include "expandedString" (dict "str" .Values.cluster.gitserver.ssh.known_hosts "Files" .Files) | b64enc }}
kind: Secret
metadata:
name: gitserver-ssh
Expand Down
4 changes: 2 additions & 2 deletions templates/gitserver/gitserver.Deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ spec:
name: sg-config
- mountPath: /data/repos
name: repos
{{- if $global.Values.site.gitserverSSH }}
{{- if $global.Values.cluster.gitserver.ssh }}
- mountPath: /root/.ssh
name: ssh
{{ end }}
Expand All @@ -70,7 +70,7 @@ spec:
- name: repos
persistentVolumeClaim:
claimName: gitserver-{{ add1 $gitserverIndex }}
{{- if $global.Values.site.gitserverSSH }}
{{- if $global.Values.cluster.gitserver.ssh }}
- name: ssh
secret:
defaultMode: 384
Expand Down
6 changes: 6 additions & 0 deletions values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,12 @@ cluster:
shards: 1
# Size of disk of each gitserver shard. If you change this, you should also change indexedSearch.diskSize.
diskSize: 200Gi
# # ssh is a map that describes the structure of gitserver's .ssh directory. If you have configured Sourcegraph
# # to index a private git repository and clone via SSH, you'll need to add the appropriate files to this
# # field.
# ssh:
# known_hosts: "Set this to the desired value for the SSH known_hosts file."
# id_rsa: "Set this to the value of a private key authorized to clone repositories from the code host."
containers:
gitserver:
limits:
Expand Down

0 comments on commit f5a6cee

Please sign in to comment.