File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed
files/gitlab-config-template
spec/chef/cookbooks/gitlab-kas/recipes Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -2165,6 +2165,9 @@ external_url 'GENERATED_EXTERNAL_URL'
21652165# # 'OWN_PRIVATE_API_CIDR' => '2001:db8:8a2e:370::7334/64', # IPv6 example
21662166# # 'OWN_PRIVATE_API_PORT' => '8155', # if not set, port from private_api_listen_address is used
21672167# # 'OWN_PRIVATE_API_SCHEME' => 'grpc', # use grpcs when using TLS on private API endpoint
2168+ # # OWN_PRIVATE_API_HOST is used to verify the TLS cert hostname.
2169+ # # Set KAS' host name if you want to use TLS for KAS->KAS communication.
2170+ # # 'OWN_PRIVATE_API_HOST' => '<server-name-from-cert>',
21682171# }
21692172
21702173##! Error Reporting and Logging with Sentry
Original file line number Diff line number Diff line change 117117 sentry_dsn : 'https://my_key:my_secret@sentry.io/test_project' ,
118118 sentry_environment : 'production' ,
119119 log_level : 'debug' ,
120+ env : {
121+ 'OWN_PRIVATE_API_HOST' => 'fake-host.example.com'
122+ }
120123 }
121124 )
122125 end
157160 expect ( chef_run ) . to render_file ( "/var/opt/gitlab/gitlab-kas/authentication_secret_file" ) . with_content ( api_secret_key )
158161 expect ( chef_run ) . to render_file ( "/var/opt/gitlab/gitlab-kas/private_api_authentication_secret_file" ) . with_content ( private_api_secret_key )
159162 end
163+
164+ it 'sets OWN_PRIVATE_API_HOST' do
165+ expect ( chef_run ) . to render_file ( '/opt/gitlab/etc/gitlab-kas/env/OWN_PRIVATE_API_HOST' ) . with_content ( 'fake-host.example.com' )
166+ end
160167 end
161168
162169 describe 'gitlab.yml configuration' do
186193 )
187194 end
188195
189- it 'has exernal URL with scheme `ws` instead of `wss`' do
196+ it 'has external URL with scheme `ws` instead of `wss`' do
190197 expect ( gitlab_yml [ :production ] [ :gitlab_kas ] ) . to include (
191198 external_url : 'ws://gitlab.example.com/-/kubernetes-agent/'
192199 )
You can’t perform that action at this time.
0 commit comments