Skip to content

Commit c30ca95

Browse files
committed
REORG/MEDIUM: snake case for HCL and YAML keys in configuration files
1 parent cd4f849 commit c30ca95

File tree

7 files changed

+201
-201
lines changed

7 files changed

+201
-201
lines changed

configuration/configuration.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,9 +105,9 @@ type ClusterConfiguration struct {
105105
APIBasePath AtomicString `yaml:"api_base_path,omitempty" group:"cluster" save:"true"`
106106
APINodesPath AtomicString `yaml:"api_nodes_path,omitempty" group:"cluster" save:"true"`
107107
APIRegisterPath AtomicString `yaml:"api_register_path,omitempty" group:"cluster" save:"true"`
108-
StorageDir AtomicString `yaml:"storage-dir,omitempty" group:"cluster" save:"true"`
109-
CertificateDir AtomicString `yaml:"cert-path,omitempty" group:"cluster" save:"true"`
110-
CertificateFetched AtomicBool `yaml:"cert-fetched,omitempty" group:"cluster" save:"true" example:"false"`
108+
StorageDir AtomicString `yaml:"storage_dir,omitempty" group:"cluster" save:"true"`
109+
CertificateDir AtomicString `yaml:"cert_path,omitempty" group:"cluster" save:"true"`
110+
CertificateFetched AtomicBool `yaml:"cert_fetched,omitempty" group:"cluster" save:"true" example:"false"`
111111
Name AtomicString `yaml:"name,omitempty" group:"cluster" save:"true"`
112112
Description AtomicString `yaml:"description,omitempty" group:"cluster" save:"true"`
113113
}

configuration/configuration_generated.go

Lines changed: 57 additions & 57 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

configuration/examples/example-dataplaneapi.hcl

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,18 @@ dataplaneapi {
1010
}
1111

1212
resources {
13-
maps-dir = "/etc/haproxy/maps"
14-
ssl-certs-dir = "/etc/haproxy/ssl"
15-
spoe-dir = "/etc/haproxy/spoe"
13+
maps_dir = "/etc/haproxy/maps"
14+
ssl_certs_dir = "/etc/haproxy/ssl"
15+
spoe_dir = "/etc/haproxy/spoe"
1616
}
1717
}
1818

1919
haproxy {
20-
config-file = "/etc/haproxy/haproxy.cfg"
21-
haproxy-bin = "/usr/local/sbin/haproxy"
20+
config_file = "/etc/haproxy/haproxy.cfg"
21+
haproxy_bin = "/usr/local/sbin/haproxy"
2222

2323
reload {
24-
reload-cmd = "kill -SIGUSR2 1"
25-
restart-cmd = "kill -SIGUSR2 1"
24+
reload_cmd = "kill -SIGUSR2 1"
25+
restart_cmd = "kill -SIGUSR2 1"
2626
}
2727
}

configuration/examples/example-dataplaneapi.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,12 @@ dataplaneapi:
77
insecure: true
88
password: adminpwd
99
resources:
10-
maps-dir: /etc/haproxy/maps
11-
ssl-certs-dir: /etc/haproxy/ssl
12-
spoe-dir: /etc/haproxy/spoe
10+
maps_dir: /etc/haproxy/maps
11+
ssl_certs_dir: /etc/haproxy/ssl
12+
spoe_dir: /etc/haproxy/spoe
1313
haproxy:
14-
config-file: /etc/haproxy/haproxy.cfg
15-
haproxy-bin: /usr/local/sbin/haproxy
14+
config_file: /etc/haproxy/haproxy.cfg
15+
haproxy_bin: /usr/local/sbin/haproxy
1616
reload:
17-
reload-cmd: kill -SIGUSR2 1
18-
restart-cmd: kill -SIGUSR2 1
17+
reload_cmd: kill -SIGUSR2 1
18+
restart_cmd: kill -SIGUSR2 1

0 commit comments

Comments
 (0)