mirror of
https://github.com/gravitational/teleport
synced 2024-10-21 01:34:01 +00:00
Nicer parsing of "auth_servers" config option
This commit is contained in:
parent
1bcd32e5ca
commit
45f1986d88
|
@ -126,7 +126,11 @@ func ApplyFileConfig(fc *FileConfig, cfg *service.Config) error {
|
|||
if len(fc.AuthServers) > 0 {
|
||||
cfg.AuthServers = make([]utils.NetAddr, 0, len(fc.AuthServers))
|
||||
for _, as := range fc.AuthServers {
|
||||
addr, err := utils.ParseAddr(as)
|
||||
addr, err := utils.ParseHostPortAddr(as, defaults.AuthListenPort)
|
||||
if err != nil {
|
||||
return trace.Wrap(err)
|
||||
}
|
||||
|
||||
if err != nil {
|
||||
return trace.Errorf("cannot parse auth server address: '%v'", as)
|
||||
}
|
||||
|
|
|
@ -121,7 +121,7 @@ teleport:
|
|||
advertise_ip: 10.5.5.5
|
||||
nodename: hvostongo.example.org
|
||||
auth_servers:
|
||||
- tcp://auth.server.example.org:3024
|
||||
- auth.server.example.org:3024
|
||||
auth_token: xxxyyy
|
||||
log:
|
||||
output: stderr
|
||||
|
|
2
vagrant/libvirt/Vagrantfile
vendored
2
vagrant/libvirt/Vagrantfile
vendored
|
@ -13,7 +13,7 @@
|
|||
NODES = {
|
||||
"a-auth" => "10.0.10.10",
|
||||
# "a-proxy" => "10.0.10.11",
|
||||
# "a-node" => "10.0.10.12",
|
||||
"a-node" => "10.0.10.12",
|
||||
|
||||
"b-auth" => "10.0.10.20",
|
||||
# "b-proxy" => "10.0.10.21",
|
||||
|
|
|
@ -8,6 +8,8 @@ teleport:
|
|||
auth_service:
|
||||
enabled: yes
|
||||
cluster_name: cluster-a
|
||||
tokens:
|
||||
- "node:hello"
|
||||
trusted_clusters:
|
||||
- key_file: /opt/shared/cluster-b
|
||||
allow_logins: root,vagrant
|
||||
|
|
17
vagrant/libvirt/data/opt/a-node.yaml
Normal file
17
vagrant/libvirt/data/opt/a-node.yaml
Normal file
|
@ -0,0 +1,17 @@
|
|||
# Node for cluster-A
|
||||
teleport:
|
||||
nodename: node
|
||||
auth_token: hello
|
||||
auth_servers: [a-auth]
|
||||
log:
|
||||
output: stderr
|
||||
severity: INFO
|
||||
|
||||
auth_service:
|
||||
enabled: no
|
||||
|
||||
ssh_service:
|
||||
enabled: yes
|
||||
|
||||
proxy_service:
|
||||
enabled: no
|
Loading…
Reference in a new issue