Skip to content

Commit 2123f20

Browse files
committed
Bump chart
1 parent 3c7a72f commit 2123f20

File tree

4 files changed

+89
-26
lines changed

4 files changed

+89
-26
lines changed

README.md

Lines changed: 47 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,13 @@ config:
3636
auth:
3737
hmac_key: a-very-strong-key
3838
cookies_key: another-strong-key
39+
allow_email_login: true
40+
registration_approval: true
41+
42+
adminUser:
43+
create: true
44+
45+
password: your-super-secret-password
3946
```
4047
4148
In order to expose your TFStater instance you also need to enable the Ingress resource:
@@ -72,7 +79,7 @@ config:
7279
bucket: my-s3-bucket
7380
access_key: ""
7481
secret_key: ""
75-
path_prefix: terraform/states
82+
# path_prefix: terraform/states
7683
```
7784

7885
For S3-compatible providers, you might need to specify the endpoint:
@@ -122,6 +129,9 @@ Create an OAuth application within your Github organization. Set the callback ur
122129

123130
```yaml
124131
config:
132+
auth:
133+
allow_email_login: false
134+
125135
idp:
126136
github:
127137
client_id: your-gh-app-client-id
@@ -144,7 +154,42 @@ config:
144154

145155
#### Use email login
146156

147-
*Feature still in development*
157+
TFStater provides also a standard email signup flow. In order to verify new signups, you have 2 options: manual approval, and email verification.
158+
159+
In order to setup manual approval, you also need to create your fist user:
160+
161+
```yaml
162+
config:
163+
auth:
164+
allow_email_login: true
165+
registration_approval: true
166+
167+
adminUser:
168+
create: true
169+
170+
password: your-super-secret-password
171+
```
172+
173+
using this configuration, you can manually approve users through the settings page.
174+
175+
The email verification flow requires domain restriction and to setup an smtp server to allow TFStater to send verifications:
176+
177+
```yaml
178+
config:
179+
auth:
180+
allow_email_login: true
181+
registration_verification: true
182+
restrict_email_domain: "@my.tld"
183+
184+
smtp:
185+
186+
server: smtp.my.tld
187+
username: tfstater
188+
password: super-secret-password
189+
# port: 25
190+
# use_tls: false
191+
# use_ssl: false
192+
```
148193

149194
## Usage
150195

charts/tfstater/Chart.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ type: application
33
name: tfstater
44
description: An HTTP Terraform state backend with locking support
55

6-
version: 0.1.4
7-
appVersion: 0.1.2
6+
version: 0.2.0
7+
appVersion: 0.2.0
88
kubeVersion: ">=1.14.0-0"
99

1010
home: https://github.com/gi0baro/tfstater

charts/tfstater/templates/secret.yaml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,14 @@ stringData:
4646
path_prefix: {{ $objStoreConfig.path_prefix | quote }}
4747
encrypt_data: {{ $objStoreConfig.encrypt_data }}
4848
49-
auth: {{ .Values.config.auth | toYaml | nindent 6 }}
49+
{{ with .Values.config.auth -}}
50+
auth: {{ . | toYaml | nindent 6 }}
51+
{{- end }}
5052
51-
idp: {{ .Values.config.idp | toYaml | nindent 6 }}
53+
{{ with .Values.config.smtp -}}
54+
smtp: {{ . | toYaml | nindent 6 }}
55+
{{- end }}
56+
57+
{{ with .Values.config.idp -}}
58+
idp: {{ . | toYaml | nindent 6 }}
59+
{{- end }}

charts/tfstater/values.yaml

Lines changed: 30 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -137,13 +137,6 @@ config:
137137
password: ""
138138
pool_size: 10
139139

140-
auth:
141-
hmac_key:
142-
cookies_key:
143-
allow_email_login: true
144-
restrict_email_domain:
145-
registration_verification: true
146-
147140
object_storage:
148141
access_key:
149142
secret_key:
@@ -152,19 +145,36 @@ config:
152145
path_prefix:
153146
encrypt_data: false
154147

155-
idp:
156-
github:
157-
# client_id:
158-
# client_secret:
159-
# organization:
160-
# claim_roles: []
161-
# claim_teams: []
162-
# match_role:
163-
# admin: maintainer
164-
# match_teams:
165-
# team: maintainer
148+
auth:
149+
hmac_key:
150+
cookies_key:
151+
allow_email_login: false
152+
restrict_email_domain:
153+
registration_approval: false
154+
registration_verification: false
155+
156+
smtp: {}
157+
# sender: "[email protected]"
158+
# server: ""
159+
# port: 25
160+
# username: tfstater
161+
# password: ""
162+
# use_tls: false
163+
# use_ssl: false
164+
165+
idp: {}
166+
# github:
167+
# client_id:
168+
# client_secret:
169+
# organization:
170+
# claim_roles: []
171+
# claim_teams: []
172+
# match_role:
173+
# admin: maintainer
174+
# match_teams:
175+
# team: maintainer
166176

167177
adminUser:
168178
create: false
169-
email: ""
170-
password: ""
179+
# email: ""
180+
# password: ""

0 commit comments

Comments
 (0)