diff options
author | Niall Sheridan <nsheridan@gmail.com> | 2016-05-29 14:46:06 +0100 |
---|---|---|
committer | Niall Sheridan <nsheridan@gmail.com> | 2016-05-29 14:46:06 +0100 |
commit | 1a16ff15b87a10b2e7359ba53104ed4bd9fef9e8 (patch) | |
tree | 1f6ea2155189713110bf05dc62af4a560152917c /testdata | |
parent | 2d76d6028d75dda1d239d228d47679b5b35ee1e1 (diff) | |
parent | 46ec48845704b54d395727441edc049b009da774 (diff) |
Merge pull request #10 from nsheridan/hcl
Switch from json to hcl configs
Diffstat (limited to 'testdata')
-rw-r--r-- | testdata/config.go | 54 |
1 files changed, 30 insertions, 24 deletions
diff --git a/testdata/config.go b/testdata/config.go index bb2f511..9ad9394 100644 --- a/testdata/config.go +++ b/testdata/config.go @@ -1,32 +1,38 @@ package testdata -var ServerConfig = []byte(`{ - "server": { - "use_tls": true, - "tls_key": "server.key", - "tls_cert": "server.crt", - "port": 443, - "cookie_secret": "supersecret" +var ServerConfig = []byte(` + server { + use_tls = true + tls_key = "server.key" + tls_cert = "server.crt" + port = 443 + cookie_secret = "supersecret" } -}`) + auth {} + ssh {} +`) -var AuthConfig = []byte(`{ - "auth": { - "provider": "google", - "oauth_client_id": "client_id", - "oauth_client_secret": "secret", - "oauth_callback_url": "https://sshca.example.com/auth/callback", - "provider_opts": { - "domain": "example.com" +var AuthConfig = []byte(` + auth { + provider = "google" + oauth_client_id = "client_id" + oauth_client_secret = "secret" + oauth_callback_url = "https://sshca.example.com/auth/callback" + provider_opts { + domain = "example.com" } } -}`) + server {} + ssh {} +`) -var SSHConfig = []byte(`{ - "ssh": { - "signing_key": "signing_key", - "additional_principals": ["ec2-user", "ubuntu"], - "max_age": "720h", - "permissions": ["permit-pty", "permit-X11-forwarding", "permit-port-forwarding", "permit-user-rc"] +var SSHConfig = []byte(` + ssh { + signing_key = "signing_key" + additional_principals = ["ec2-user", "ubuntu"] + max_age = "720h" + permissions = ["permit-pty", "permit-X11-forwarding", "permit-port-forwarding", "permit-user-rc"] } -}`) + auth {} + server {} +`) |