AtomicOs

gtilab.json

Jun 24th, 2021 (edited)
379
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
JSON 3.97 KB | None | 0 0
  1. external_url 'https://gitlab.example.com'
  2.  
  3. # git_data_dirs get configured for the Praefect virtual storage
  4. # Address is Interal Load Balancer for Praefect
  5. # Token is praefect_external_token
  6. git_data_dirs({
  7.   "default" => {
  8.     "gitaly_address" => "tcp://10.6.0.40:2305", # internal load balancer IP
  9.     "gitaly_token" => '<praefect_external_token>'
  10.   }
  11. })
  12.  
  13. ## Disable components that will not be on the GitLab application server
  14. roles(['application_role'])
  15. gitaly['enable'] = true
  16. nginx['enable'] = true
  17. sidekiq['enable'] = true
  18.  
  19. ## PostgreSQL connection details
  20. # Disable PostgreSQL on the application node
  21. postgresql['enable'] = true
  22. gitlab_rails['db_host'] = '10.6.0.20' # internal load balancer IP
  23. gitlab_rails['db_port'] = 7674
  24. gitlab_rails['db_password'] = '<postgresql_user_password>'
  25. # Prevent database migrations from running on upgrade automatically
  26. gitlab_rails['auto_migrate'] = false
  27.  
  28. ## Redis connection details
  29. ## First cluster that will host the cache
  30. gitlab_rails['redis_cache_instance'] = 'redis://:<REDIS_PRIMARY_PASSWORD_OF_FIRST_CLUSTER>@gitlab-redis-cache'
  31.  
  32. gitlab_rails['redis_cache_sentinels'] = [
  33.   {host: '10.6.0.71', port: 26480},
  34.   {host: '10.6.0.72', port: 26480},
  35.   {host: '10.6.0.73', port: 26480},
  36. ]
  37.  
  38. ## Second cluster that will host the queues, shared state, and actionable
  39. gitlab_rails['redis_queues_instance'] = 'redis://:<REDIS_PRIMARY_PASSWORD_OF_SECOND_CLUSTER>@gitlab-redis-persistent'
  40. gitlab_rails['redis_shared_state_instance'] = 'redis://:<REDIS_PRIMARY_PASSWORD_OF_SECOND_CLUSTER>@gitlab-redis-persistent'
  41. gitlab_rails['redis_actioncable_instance'] = 'redis://:<REDIS_PRIMARY_PASSWORD_OF_SECOND_CLUSTER>@gitlab-redis-persistent'
  42.  
  43. gitlab_rails['redis_queues_sentinels'] = [
  44.   {host: '10.6.0.81', port: 9431},
  45.   {host: '10.6.0.82', port: 9431},
  46.   {host: '10.6.0.83', port: 9431},
  47. ]
  48. gitlab_rails['redis_shared_state_sentinels'] = [
  49.   {host: '10.6.0.81', port: 4003},
  50.   {host: '10.6.0.82', port: 4003},
  51.   {host: '10.6.0.83', port: 4003},
  52. ]
  53. gitlab_rails['redis_actioncable_sentinels'] = [
  54.   {host: '10.6.0.81', port: 8001},
  55.   {host: '10.6.0.82', port: 8001},
  56.   {host: '10.6.0.83', port: 8001},
  57. ]
  58.  
  59. # Set the network addresses that the exporters used for monitoring will listen on
  60. node_exporter['listen_address'] = '127.0.0.1:9001'
  61. gitlab_workhorse['prometheus_listen_addr'] = '127.0.0.1:4001'
  62. puma['listen'] = '0.0.0.0'
  63.  
  64. # Add the monitoring node's IP address to the monitoring whitelist and allow it to
  65. # scrape the NGINX metrics
  66. gitlab_rails['monitoring_whitelist'] = ['10.6.0.151/32', '127.0.0.0/8']
  67. nginx['status']['options']['allow'] = ['10.6.0.151/32', '127.0.0.0/8']
  68.  
  69. #############################
  70. ###     Object storage    ###
  71. #############################
  72.  
  73. # This is an example for configuring Object Storage on GCP
  74. # Replace this config with your chosen Object Storage provider as desired
  75. gitlab_rails['object_store']['connection'] = {
  76.  'provider' => 'Google',
  77.  'google_project' => '<gcp-project-name>',
  78.  'google_json_key_location' => '<path-to-gcp-service-account-key>'
  79. }
  80. gitlab_rails['object_store']['objects']['artifacts']['bucket'] = "<gcp-artifacts-bucket-name>"
  81. gitlab_rails['object_store']['objects']['external_diffs']['bucket'] = "<gcp-external-diffs-bucket-name>"
  82. gitlab_rails['object_store']['objects']['lfs']['bucket'] = "<gcp-lfs-bucket-name>"
  83. gitlab_rails['object_store']['objects']['uploads']['bucket'] = "<gcp-uploads-bucket-name>"
  84. gitlab_rails['object_store']['objects']['packages']['bucket'] = "<gcp-packages-bucket-name>"
  85. gitlab_rails['object_store']['objects']['dependency_proxy']['bucket'] = "<gcp-dependency-proxy-bucket-name>"
  86. gitlab_rails['object_store']['objects']['terraform_state']['bucket'] = "<gcp-terraform-state-bucket-name>"
  87.  
  88. gitlab_rails['backup_upload_connection'] = {
  89.  'provider' => 'Google',
  90.  'google_project' => '<gcp-project-name>',
  91.  'google_json_key_location' => '<path-to-gcp-service-account-key>'
  92. }
  93. gitlab_rails['backup_upload_remote_directory'] = "<gcp-backups-state-bucket-name>"
  94.  
Add Comment
Please, Sign In to add comment