~juju-qa/ubuntu/xenial/juju/xenial-2.0-beta3

« back to all changes in this revision

Viewing changes to src/github.com/juju/juju/provider/azure/environprovider.go

  • Committer: Martin Packman
  • Date: 2016-03-30 19:31:08 UTC
  • mfrom: (1.1.41)
  • Revision ID: martin.packman@canonical.com-20160330193108-h9iz3ak334uk0z5r
Merge new upstream source 2.0~beta3

Show diffs side-by-side

added added

removed removed

Lines of Context:
78
78
// will be copied across to a hosted environment's initial configuration.
79
79
func (prov *azureEnvironProvider) RestrictedConfigAttributes() []string {
80
80
        return []string{
81
 
                configAttrSubscriptionId,
82
 
                configAttrTenantId,
83
 
                configAttrAppId,
84
 
                configAttrAppPassword,
85
81
                configAttrLocation,
 
82
                configAttrEndpoint,
86
83
                configAttrControllerResourceGroup,
87
 
                configAttrStorageAccountType,
 
84
                configAttrStorageEndpoint,
88
85
        }
89
86
}
90
87
 
97
94
        return env.initResourceGroup()
98
95
}
99
96
 
100
 
// PrepareForBootstrap is specified in the EnvironProvider interface.
101
 
func (prov *azureEnvironProvider) PrepareForBootstrap(ctx environs.BootstrapContext, args environs.PrepareForBootstrapParams) (environs.Environ, error) {
102
 
 
 
97
// BootstrapConfig is specified in the EnvironProvider interface.
 
98
func (prov *azureEnvironProvider) BootstrapConfig(args environs.BootstrapConfigParams) (*config.Config, error) {
103
99
        // Ensure that internal configuration is not specified, and then set
104
100
        // what we can now. We only need to do this during bootstrap. Validate
105
101
        // will check for changes later.
131
127
        if err != nil {
132
128
                return nil, errors.Annotate(err, "updating config")
133
129
        }
 
130
        return cfg, nil
 
131
}
134
132
 
 
133
// PrepareForBootstrap is specified in the EnvironProvider interface.
 
134
func (prov *azureEnvironProvider) PrepareForBootstrap(ctx environs.BootstrapContext, cfg *config.Config) (environs.Environ, error) {
135
135
        env, err := prov.Open(cfg)
136
136
        if err != nil {
137
137
                return nil, errors.Trace(err)