Frank Schroeder
45a9c2be8b
agent: refactor DNS and HTTP server
...
* refactor DNS server to be ready for multiple bind addresses
* drop tcpKeepAliveListener since it is default for the HTTP servers
* add startup timeout watcher for HTTP servers identical to DNS server
2017-05-31 00:29:29 +02:00
Frank Schroeder
6e7cf8c07e
agent: rename *Config vars to 'cfg'
2017-05-31 00:29:24 +02:00
Frank Schroeder
193eec414f
agent: rename *Command vars to 'cmd'
...
'c' is ambigious and it conflicts with 'config'.
2017-05-31 00:29:24 +02:00
Frank Schroeder
76fbe43f56
agent: simplify agent creation
...
This patch creates an agent with just a config struct
and allows for other fields to be set as required.
2017-05-31 00:29:23 +02:00
Frank Schroeder
8d9f5b9a64
agent: move http/dns endpoints into agent
...
Move the HTTP and DNS endpoints into the agent and control
their lifespan via the agent.
This removes the requirement to manage HTTP and DNS servers
indpendent of the agent since the agent is mostly useless
without an endpoint and the endpoints without the agent.
2017-05-31 00:29:23 +02:00
Frank Schroeder
b2670b2d59
agent: fix comment
2017-05-31 00:29:22 +02:00
Frank Schroeder
bc657da280
agent: drop logOutput parameter
...
agent.logOutput is identical to logOutput
2017-05-31 00:29:22 +02:00
Frank Schroeder
3a9f867b9b
agent: drop config argument
...
agent.config and config are identical.
2017-05-31 00:29:22 +02:00
Michael Leow
ec81c18006
agent: add RetryJoin support for Azure
...
Pull #2978 from leowmjw/develop
Resolves #2978
2017-05-24 10:15:38 +02:00
Frank Schroeder
69125e3a58
agent: move isAddrANY to separate package
2017-05-15 22:44:43 +02:00
Frank Schroeder
d6eb1d434f
agent: Replace client/server with delegate interface
...
This patch adds a new internal interface clientServer
which defines the common methods of consul.Client and
consul.Server. This allows to replace the following
code
if a.server != nil {
a.server.do()
} else {
a.client.do()
}
with
a.delegate.do()
In case a specific type is required a type check can
be performed:
if srv, ok := a.delegate.(*consul.Server); ok {
srv.doSrv()
}
2017-05-15 18:35:38 +02:00
Frank Schroeder
27e951d213
agent: use helper for INADDR_ANY
2017-05-11 00:34:14 +02:00
Frank Schroeder
e13f3446ac
agent: drop atlas/scada code
2017-05-10 23:06:36 +02:00
Frank Schroeder
c1cbecfe18
agent: Disallow :: or [::] as advertise or advertise-wan address
2017-05-09 17:56:16 +02:00
Frank Schroeder
66e7b414b0
agent: Disallow 0.0.0.0 as advertise or advertise-wan address
...
Fixes #2961
2017-05-09 17:56:15 +02:00
Frank Schroeder
8213222931
Move GCE discovery code to command/agent/config_gce.go
2017-05-04 01:41:47 +02:00
Frank Schroeder
39fae5eac2
Move AWS discovery code to command/agent/config_aws.go
2017-05-04 01:41:47 +02:00
Frank Schroeder
3ea54c48a8
Move verifyUniqueListeners to command/agent/config.go
2017-05-04 01:41:47 +02:00
Frank Schroeder
f50d6871f9
golint: No stutter
2017-04-25 09:26:13 -07:00
Frank Schroeder
8c7bb7b65a
golint: Rename fields and structs
2017-04-25 09:26:13 -07:00
Frank Schroeder
c7f367af56
golint: Consistent receiver name
...
Ensure the receiver name is consistent
2017-04-25 09:26:13 -07:00
mckennajones
1695506b1d
Added check to see if ui and ui-dir flags are both specified
2017-04-17 17:25:57 -07:00
James Phillips
1129827f91
Merge pull request #2842 from vaLski/supress_sigpipe_logging
...
Supress signal logging on SIGPIPE. Should address #2768
2017-04-13 16:52:29 -07:00
James Phillips
20bf47d2b4
Adds a new -disable-host-node-id option to help when testing with containers.
...
Fixes #2877 .
2017-04-12 22:07:18 -07:00
vaLentin chernoZemski
8aee2b805a
Supress signal logging on SIGPIPE. Should address #2768
...
When consul-template is communicating with consul and the job is done, consul thread receives SIGPIPE.
This cause the logs to be filled "Caught signal: broken pipe" and they does not bring any usefull info with them.
Skipping those.
2017-03-29 09:46:58 +03:00
Kyle Havlovitz
37ea20cb44
Add advanced autopilot features
2017-03-22 15:25:16 -07:00
Kyle Havlovitz
8bcab6c6d7
Add autopilot server health tracking
...
This adds two goroutines to perform autopilot tasks on the leader - one
to monitor the health of servers and another to periodically clean up
dead servers with a limit on removal count. Also adds a new http endpoint,
`/v1/operator/autopilot/health`, for querying this information through an
operator RPC endpoint.
2017-03-06 16:00:10 -08:00
Kyle Havlovitz
77785778bf
Merge pull request #2774 from hashicorp/f-cli-deprecation-docs
...
Add CLI RPC deprecation section to docs
2017-02-28 14:59:48 -08:00
Kyle Havlovitz
3b67c50c1d
Remove the RPC client interface and update docs
2017-02-28 13:41:09 -08:00
Sean Chittenden
63402c6eaa
Follow the lead in 6fc901a8f3
and set the default DisplayName
to Consul
2017-02-26 12:26:14 -08:00
Kyle Havlovitz
953baed324
Convert agent command to use base.Command
2017-02-24 18:11:05 -08:00
Kyle Havlovitz
35d99a81ac
Update docs and give better error for unknown client scheme
2017-02-10 19:55:54 -05:00
Kyle Havlovitz
bdb58adb80
Allow internal watches to use https and unix sockets
2017-02-10 18:38:39 -05:00
Kyle Havlovitz
cc271aa436
Merge branch 'master' into f-prepared-query-nodemeta
2017-01-23 20:17:48 -05:00
Kyle Havlovitz
3cd054e81f
Add tests for node meta in prepared queries and update docs
2017-01-23 19:17:30 -05:00
James Phillips
96bff003b7
Adds basic support for node IDs.
2017-01-17 22:47:59 -08:00
Kyle Havlovitz
ebd37af4ef
Style tweaks and vendor.json cleanup
2017-01-12 16:49:44 -05:00
Kyle Havlovitz
2139dbb029
Merge branch 'master' into f-gce-discovery
2017-01-11 22:57:07 -05:00
Kyle Havlovitz
84b157eade
Condense gce discovery logging a bit
2017-01-11 22:37:22 -05:00
Kyle Havlovitz
821735d175
Merge pull request #2643 from hashicorp/f-node-metadata
...
Node metadata
2017-01-11 20:29:24 -05:00
Kyle Havlovitz
51a1834667
Add -node-meta to agent command line options
2017-01-11 16:09:04 -05:00
Kyle Havlovitz
d77890a011
Validate metadata config earlier and handle multiple filters
2017-01-11 15:12:03 -05:00
Andrew Glen-Young
c78c07d9cb
Pedantic typo fix
2017-01-10 15:44:32 -05:00
Kyle Havlovitz
2a423c6e2c
Add support for setting node metadata fields
2017-01-05 14:10:26 -08:00
Kyle Havlovitz
5d03ab53f3
Don't error if the given data-dir doesn't exist
2016-12-15 12:55:21 -05:00
James Phillips
5a6521c385
Adds exception for data-dir check in -dev mode.
...
This was changed in #2529 .
2016-12-14 22:11:16 -08:00
Kyle Havlovitz
9f81d70d31
Merge pull request #2529 from mckennajones/bug/1838
...
Give a better error message when data-dir is not a directory
2016-12-14 20:21:10 -05:00
Kyle Havlovitz
78455621a1
Handle error from stat on data-dir and shorten error message
2016-12-14 20:06:00 -05:00
Kyle Havlovitz
80a8055d5a
Merge pull request #2553 from mckennajones/bug/ignoresigpipe
...
Ignore sigpipe signals
2016-12-14 15:36:26 -05:00
Kyle Havlovitz
398f4a04ef
Add a notice about deprecation of atlas features
2016-12-14 15:13:51 -05:00