Skip to content
Snippets Groups Projects
Commit 6e165ab1 authored by Robert Marshall's avatar Robert Marshall
Browse files

Merge branch 'smh-update-default-templatet' into 'master'

Update default configuration template for Gitaly and Praefect

See merge request https://gitlab.com/gitlab-org/omnibus-gitlab/-/merge_requests/6714



Merged-by: default avatarRobert Marshall <rmarshall@gitlab.com>
Approved-by: default avatarRobert Marshall <rmarshall@gitlab.com>
Approved-by: default avatarHossein Pursultani <hpursultani@gitlab.com>
Co-authored-by: default avatarSami Hiltunen <shiltunen@gitlab.com>
parents 4f3d947c b32c1ffb
No related branches found
No related tags found
2 merge requests!102heptapod#1237: making 0.38 the new oldstable,!92Merging upstream 15.10.0+ce.0
......@@ -2406,7 +2406,7 @@
################################################################################
## Gitaly
##! Docs:
##! Docs: https://docs.gitlab.com/ee/administration/gitaly/configure_gitaly.html
################################################################################
# The gitaly['enable'] option exists for the purpose of cluster
......@@ -2426,24 +2426,4 @@
# 'WRAPPER_JSON_LOGGING' => true
# }
# gitaly['runtime_dir'] = "/var/opt/gitlab/gitaly/run"
# gitaly['socket_path'] = "/var/opt/gitlab/gitaly/gitaly.socket"
# gitaly['listen_addr'] = "localhost:8075"
# gitaly['tls_listen_addr'] = "localhost:9075"
# gitaly['certificate_path'] = "/var/opt/gitlab/gitaly/certificate.pem"
# gitaly['key_path'] = "/var/opt/gitlab/gitaly/key.pem"
# gitaly['gpg_signing_key_path'] = "/var/opt/gitlab/gitaly/signing_key.gpg"
# gitaly['prometheus_listen_addr'] = "localhost:9236"
# gitaly['logging_level'] = "warn"
# gitaly['logging_format'] = "json"
# gitaly['logging_sentry_dsn'] = "https://<key>:<secret>@sentry.io/<project>"
# gitaly['logging_ruby_sentry_dsn'] = "https://<key>:<secret>@sentry.io/<project>"
# gitaly['logging_sentry_environment'] = "production"
# gitaly['prometheus_grpc_latency_buckets'] = "[0.001, 0.005, 0.025, 0.1, 0.5, 1.0, 10.0, 30.0, 60.0, 300.0, 1500.0]"
# gitaly['auth_token'] = '<secret>'
# gitaly['auth_transitioning'] = false # When true, auth is logged to Prometheus but NOT enforced
# gitaly['graceful_restart_timeout'] = '1m' # Grace time for a gitaly process to finish ongoing requests
# gitaly['git_catfile_cache_size'] = 100 # Number of 'git cat-file' processes kept around for re-use
# gitaly['git_bin_path'] = "/opt/gitlab/embedded/bin/git" # A custom path for the 'git' executable
# gitaly['use_bundled_git'] = true # Whether to use bundled Git.
# gitaly['open_files_ulimit'] = 15000 # Maximum number of open files allowed for the gitaly process
......@@ -2449,58 +2429,5 @@
# gitaly['open_files_ulimit'] = 15000 # Maximum number of open files allowed for the gitaly process
# gitaly['ruby_max_rss'] = 300000000 # RSS threshold in bytes for triggering a gitaly-ruby restart
# gitaly['ruby_graceful_restart_timeout'] = '10m' # Grace time for a gitaly-ruby process to finish ongoing requests
# gitaly['ruby_restart_delay'] = '5m' # Period of sustained high RSS that needs to be observed before restarting gitaly-ruby
# gitaly['ruby_num_workers'] = 3 # Number of gitaly-ruby worker processes. Minimum 2, default 2.
# gitaly['concurrency'] = [
# {
# 'rpc' => "/gitaly.SmartHTTPService/PostReceivePack",
# 'max_per_repo' => 20
# }, {
# 'rpc' => "/gitaly.SSHService/SSHUploadPack",
# 'max_per_repo' => 5
# }
# ]
# gitaly['rate_limiting'] = [
# {
# 'rpc' => "/gitaly.SmartHTTPService/PostReceivePack",
# 'interval' => '1m',
# 'burst' => 10
# }, {
# 'rpc' => "/gitaly.SSHService/SSHUploadPack",
# 'interval' => '1m',
# 'burst' => 5
# }
# ]
#
## Gitaly knows to set up the required default configuration for spawned Git
## commands automatically. It should thus not be required to configure anything
## here, except in very special situations where you must e.g. tweak specific
## performance-related settings or enable debugging facilities. It is not safe in
## general to set Git configuration that may change Git output in ways that are
## unexpected by Gitaly.
# gitaly['gitconfig'] = [
# { 'section': 'pack', 'key': 'threads', 'value': '4' }
# { 'section': 'http', 'subsection': 'http://example.com', 'key': 'proxy', 'value': 'http://example.proxy.com' }
# ]
#
# gitaly['daily_maintenance_start_hour'] = 22
# gitaly['daily_maintenance_start_minute'] = 30
# gitaly['daily_maintenance_duration'] = '30m'
# gitaly['daily_maintenance_storages'] = ["default"]
# gitaly['daily_maintenance_disabled'] = false
# gitaly['cgroups_mountpoint'] = '/sys/fs/cgroup'
# gitaly['cgroups_hierarchy_root'] = 'gitaly'
# gitaly['cgroups_memory_bytes'] = 1048576
# gitaly['cgroups_cpu_shares'] = 512
# gitaly['cgroups_repositories_count'] = 1000
# gitaly['cgroups_repositories_memory_bytes'] = 12884901888
# gitaly['cgroups_repositories_cpu_shares'] = 128
# gitaly['pack_objects_cache_enabled'] = true
# gitaly['pack_objects_cache_dir'] = '/var/opt/gitlab/git-data/repositories/+gitaly/PackObjectsCache'
# gitaly['pack_objects_cache_max_age'] = '5m'
# gitaly['custom_hooks_dir'] = "/var/opt/gitlab/gitaly/custom_hooks"
##! Service name used to register Gitaly as a Consul service
# gitaly['consul_service_name'] = 'gitaly'
##! Semantic metadata used when registering Gitaly as a Consul service
# gitaly['consul_service_meta'] = {}
......@@ -2503,7 +2430,103 @@
##! Service name used to register Gitaly as a Consul service
# gitaly['consul_service_name'] = 'gitaly'
##! Semantic metadata used when registering Gitaly as a Consul service
# gitaly['consul_service_meta'] = {}
# gitaly['configuration'] = {
# socket_path: '/var/opt/gitlab/gitaly/gitaly.socket',
# runtime_dir: '/var/opt/gitlab/gitaly/run',
# listen_addr: 'localhost:8075',
# prometheus_listen_addr: 'localhost:9236',
# tls_listen_addr: 'localhost:9075',
# tls: {
# certificate_path: '/var/opt/gitlab/gitaly/certificate.pem',
# key_path: '/var/opt/gitlab/gitaly/key.pem',
# },
# graceful_restart_timeout: '1m', # Grace time for a gitaly process to finish ongoing requests
# logging: {
# level: 'warn',
# format: 'json',
# sentry_dsn: 'https://<key>:<secret>@sentry.io/<project>',
# ruby_sentry_dsn: 'https://<key>:<secret>@sentry.io/<project>',
# sentry_environment: 'production',
# },
# prometheus: {
# grpc_latency_buckets: [0.001, 0.005, 0.025, 0.1, 0.5, 1.0, 10.0, 30.0, 60.0, 300.0, 1500.0],
# },
# auth: {
# token: '<secret>',
# transitioning: false, # When true, auth is logged to Prometheus but NOT enforced
# },
# git: {
# catfile_cache_size: 100, # Number of 'git cat-file' processes kept around for re-use
# bin_path: '/opt/gitlab/embedded/bin/git', # A custom path for the 'git' executable
# use_bundled_binaries: true, # Whether to use bundled Git.
# signing_key: '/var/opt/gitlab/gitaly/signing_key.gpg',
# ## Gitaly knows to set up the required default configuration for spawned Git
# ## commands automatically. It should thus not be required to configure anything
# ## here, except in very special situations where you must e.g. tweak specific
# ## performance-related settings or enable debugging facilities. It is not safe in
# ## general to set Git configuration that may change Git output in ways that are
# ## unexpected by Gitaly.
# config: [
# { key: 'pack.threads', value: '4' },
# { key: 'http.http://example.com.proxy', value: 'http://example.proxy.com' },
# ],
# },
# 'gitaly-ruby': {
# max_rss: 300000000, # RSS threshold in bytes for triggering a gitaly-ruby restart
# graceful_restart_timeout: '10m', # Grace time for a gitaly-ruby process to finish ongoing requests
# restart_delay: '5m', # Period of sustained high RSS that needs to be observed before restarting gitaly-ruby
# num_workers: 3, # Number of gitaly-ruby worker processes. Minimum 2, default 2.
# },
# hooks: {
# custom_hooks_dir: '/var/opt/gitlab/gitaly/custom_hooks',
# },
# daily_maintenance: {
# disabled: false,
# start_hour: 22,
# start_minute: 30,
# duration: '30m',
# storages: ['default'],
# },
# cgroups: {
# mountpoint: '/sys/fs/cgroup',
# hierarchy_root: 'gitaly',
# memory_bytes: 1048576,
# cpu_shares: 512,
# repositories: {
# count: 1000,
# memory_bytes: 12884901888,
# cpu_shares: 128,
# },
# },
# concurrency: [
# {
# rpc: '/gitaly.SmartHTTPService/PostReceivePack',
# max_per_repo: 20,
# },
# {
# rpc: '/gitaly.SSHService/SSHUploadPack',
# max_per_repo: 5,
# },
# ],
# rate_limiting: [
# {
# rpc: '/gitaly.SmartHTTPService/PostReceivePack',
# interval: '1m',
# burst: 10,
# },
# {
# rpc: '/gitaly.SSHService/SSHUploadPack',
# interval: '1m',
# burst: 5,
# },
# ],
# pack_objects_cache: {
# enabled: true,
# dir: '/var/opt/gitlab/git-data/repositories/+gitaly/PackObjectsCache',
# max_age: '5m',
# },
# }
################################################################################
## Praefect
......@@ -2507,7 +2530,7 @@
################################################################################
## Praefect
##! Docs: https://gitlab.com/gitlab-org/gitaly/blob/master/doc/design_ha.md
##! Docs: https://docs.gitlab.com/ee/administration/gitaly/praefect.html
################################################################################
# praefect['enable'] = false
......@@ -2520,46 +2543,4 @@
# 'WRAPPER_JSON_LOGGING' => true
# }
# praefect['wrapper_path'] = "/opt/gitlab/embedded/bin/gitaly-wrapper"
# praefect['failover_enabled'] = true
# praefect['auth_token'] = ""
# praefect['auth_transitioning'] = false
# praefect['listen_addr'] = "localhost:2305"
# praefect['tls_listen_addr'] = "localhost:3305"
# praefect['certificate_path'] = "/var/opt/gitlab/prafect/certificate.pem"
# praefect['key_path'] = "/var/opt/gitlab/prafect/key.pem"
# praefect['prometheus_listen_addr'] = "localhost:9652"
# praefect['prometheus_grpc_latency_buckets'] = "[0.001, 0.005, 0.025, 0.1, 0.5, 1.0, 10.0, 30.0, 60.0, 300.0, 1500.0]"
# praefect['logging_level'] = "warn"
# praefect['logging_format'] = "json"
# praefect['virtual_storages'] = {
# 'default' => {
# 'default_replication_factor' => 3,
# 'nodes' => {
# 'praefect-internal-0' => {
# 'address' => 'tcp://10.23.56.78:8075',
# 'token' => 'abc123'
# },
# 'praefect-internal-1' => {
# 'address' => 'tcp://10.76.23.31:8075',
# 'token' => 'xyz456'
# }
# }
# },
# 'alternative' => {
# 'nodes' => {
# 'praefect-internal-2' => {
# 'address' => 'tcp://10.34.1.16:8075',
# 'token' => 'abc321'
# },
# 'praefect-internal-3' => {
# 'address' => 'tcp://10.23.18.6:8075',
# 'token' => 'xyz890'
# }
# }
# }
# }
# praefect['background_verification_verification_interval'] = "72h"
# praefect['background_verification_delete_invalid_records'] = false
# praefect['sentry_dsn'] = "https://<key>:<secret>@sentry.io/<project>"
# praefect['sentry_environment'] = "production"
# praefect['auto_migrate'] = true
......@@ -2565,27 +2546,5 @@
# praefect['auto_migrate'] = true
# praefect['database_host'] = 'postgres.external'
# praefect['database_port'] = 6432
# praefect['database_user'] = 'praefect'
# praefect['database_password'] = 'secret'
# praefect['database_dbname'] = 'praefect_production'
# praefect['database_sslmode'] = 'disable'
# praefect['database_sslcert'] = '/path/to/client-cert'
# praefect['database_sslkey'] = '/path/to/client-key'
# praefect['database_sslrootcert'] = '/path/to/rootcert'
# praefect['reconciliation_scheduling_interval'] = '5m'
# praefect['reconciliation_histogram_buckets'] = '[0.001, 0.005, 0.025, 0.1, 0.5, 1.0, 10.0]'
# praefect['database_direct_host'] = 'postgres.internal'
# praefect['database_direct_port'] = 5432
# praefect['database_direct_user'] = 'praefect'
# praefect['database_direct_password'] = 'secret'
# praefect['database_direct_dbname'] = 'praefect_production_direct'
# praefect['database_direct_sslmode'] = 'disable'
# praefect['database_direct_sslcert'] = '/path/to/client-cert'
# praefect['database_direct_sslkey'] = '/path/to/client-key'
# praefect['database_direct_sslrootcert'] = '/path/to/rootcert'
# praefect['graceful_stop_timeout'] = '1m'
##! Service name used to register Praefect as a Consul service
# praefect['consul_service_name'] = 'praefect'
##! Semantic metadata used when registering Praefect as a Consul service
# praefect['consul_service_meta'] = {}
......@@ -2588,7 +2547,98 @@
##! Service name used to register Praefect as a Consul service
# praefect['consul_service_name'] = 'praefect'
##! Semantic metadata used when registering Praefect as a Consul service
# praefect['consul_service_meta'] = {}
# praefect['configuration'] = {
# listen_addr: 'localhost:2305',
# prometheus_listen_addr: 'localhost:9652',
# tls_listen_addr: 'localhost:3305',
# auth: {
# token: '',
# transitioning: false,
# },
# logging: {
# format: 'json',
# level: 'warn',
# },
# failover: {
# enabled: true,
# },
# background_verification: {
# delete_invalid_records: false,
# verification_interval: '72h',
# },
# reconciliation: {
# scheduling_interval: '5m',
# histogram_buckets: [0.001, 0.005, 0.025, 0.1, 0.5, 1.0, 10.0],
# },
# tls: {
# certificate_path: '/var/opt/gitlab/prafect/certificate.pem',
# key_path: '/var/opt/gitlab/prafect/key.pem',
# },
# database: {
# host: 'postgres.external',
# port: 6432,
# user: 'praefect',
# password: 'secret',
# dbname: 'praefect_production',
# sslmode: 'disable',
# sslcert: '/path/to/client-cert',
# sslkey: '/path/to/client-key',
# sslrootcert: '/path/to/rootcert',
# session_pooled: {
# host: 'postgres.internal',
# port: 5432,
# user: 'praefect',
# password: 'secret',
# dbname: 'praefect_production_direct',
# sslmode: 'disable',
# sslcert: '/path/to/client-cert',
# sslkey: '/path/to/client-key',
# sslrootcert: '/path/to/rootcert',
# },
# },
# sentry: {
# sentry_dsn: 'https://<key>:<secret>@sentry.io/<project>',
# sentry_environment: 'production',
# },
# prometheus: {
# grpc_latency_buckets: [0.001, 0.005, 0.025, 0.1, 0.5, 1.0, 10.0, 30.0, 60.0, 300.0, 1500.0],
# },
# graceful_stop_timeout: '1m',
# virtual_storage: [
# {
# name: 'default',
# default_replication_factor: 3,
# node: [
# {
# storage: 'praefect-internal-0',
# address: 'tcp://10.23.56.78:8075',
# token: 'abc123',
# },
# {
# storage: 'praefect-internal-1',
# address: 'tcp://10.76.23.31:8075',
# token: 'xyz456',
# },
# ],
# },
# {
# name: 'alternative',
# node: [
# {
# storage: 'praefect-internal-2',
# address: 'tcp://10.34.1.16:8075',
# token: 'abc321',
# },
# {
# storage: 'praefect-internal-3',
# address: 'tcp://10.23.18.6:8075',
# token: 'xyz890',
# },
# ],
# },
# ],
# }
################################################################################
# Storage check
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment