Skip to content

Commit 8191f59

Browse files
committed
[wip] set up github.com as an oauth provider
1 parent e6cd957 commit 8191f59

File tree

2 files changed

+37
-0
lines changed

2 files changed

+37
-0
lines changed

k8s/production/gitlab/release.yaml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,31 @@ spec:
121121
# to 90 from its default of 30.
122122
graphQlTimeout: 90
123123

124+
omniauth:
125+
enabled: true
126+
127+
providers:
128+
- secret: gitlab-omniauth-github
129+
key: provider
130+
131+
# Sync github profile data to users' gitlab accounts
132+
syncProfileFromProvider: ['github']
133+
134+
# Make github an "external provider", i.e. users logging in via GitHub
135+
# will not have access to internal GitLab projects
136+
externalProviders: ['github']
137+
138+
# Allow single sign on from GitHub
139+
allowSingleSignOn: true
140+
141+
# If a user is logging in via GitHub for the first time and already has an account
142+
# on Spack GitLab, automatically link the accounts
143+
autoLinkUser: true
144+
145+
# Block auto-created users from logging in until an admin has approved them
146+
# TODO: do we want to do this?
147+
blockAutoCreatedUsers: true
148+
124149
antiAffinity: hard
125150
### END OF GLOBAL SECTION
126151

k8s/production/gitlab/secrets.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
apiVersion: v1
2+
kind: Secret
3+
metadata:
4+
name: gitlab-omniauth-github
5+
namespace: gitlab
6+
stringData:
7+
provider: |
8+
{
9+
"name": "github",
10+
"app_id": "id",
11+
"app_secret": "secret"
12+
}

0 commit comments

Comments
 (0)