~wallyworld/juju-core/ssh-keys-plugin

« back to all changes in this revision

Viewing changes to state/api/params/params.go

[r=thumper] Make the syslog udp port configurable.

Instead of having the syslog port hard-coded to 514 it makes
sense to make this configurable.

Any existing config that doesn't specify one will get the default,
which is 514.

This config port is passed through the cloud init machine config
structure so the syslog config that is written out forwards to the
correct port. This syslog port is needed, so a number of tests had
to be updated to make this work.

The (rather generic) 'suite' test in environs/config_test was updated
to use the LoggingSuite base to silence the logging that was leaked
out when running just the package tests.

The port number is now a template param in the rsyslog config.

The only other place where this was needed was with the deployer.
It was making multiple calls to get the state and api addresses.
Instead of adding another call, we now make one call to the api
to get the address information we need.

https://codereview.appspot.com/29990045/

Show diffs side-by-side

added added

removed removed

Lines of Context:
479
479
        ProviderType            string
480
480
        AuthorizedKeys          string
481
481
        SSLHostnameVerification bool
 
482
        SyslogPort              int
482
483
}
483
484
 
484
485
type MachineConfigParams struct {
517
518
type SetEnvironAgentVersion struct {
518
519
        Version version.Number
519
520
}
 
521
 
 
522
// DeployerConnectionValues containers the result of deployer.ConnectionInfo
 
523
// API call.
 
524
type DeployerConnectionValues struct {
 
525
        StateAddresses []string
 
526
        APIAddresses   []string
 
527
        SyslogPort     int
 
528
}