Skip to content

Commit 0410718

Browse files
committed
Expose AutomaticOSUpgradeProperties to VM Image
1 parent 7bbbb22 commit 0410718

File tree

41 files changed

+487
-483
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+487
-483
lines changed

src/ResourceManager/Compute/Commands.Compute/Common/ComputeAutoMapperProfile.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ private static void Initialize()
171171

172172
// Usage => PSUsage
173173
cfg.CreateMap<FROM.Usage, TO.PSUsage>()
174-
.ForMember(c => c.Unit, o => o.MapFrom(r => Microsoft.Azure.Management.Compute.Models.Usage.Unit));
174+
.ForMember(c => c.Unit, o => o.MapFrom(r => FROM.Usage.Unit));
175175

176176
cfg.CreateMap<AzureOperationResponse<FROM.Usage>, TO.PSUsage>()
177177
.ForMember(c => c.StatusCode, o => o.MapFrom(r => r.Response.StatusCode));

src/ResourceManager/Compute/Commands.Compute/Extension/Diagnostics/AddAzureRmVmssDiagnosticsExtension.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -120,19 +120,19 @@ protected override void ProcessRecord()
120120
// VirtualMachineProfile
121121
if (this.VirtualMachineScaleSet.VirtualMachineProfile == null)
122122
{
123-
this.VirtualMachineScaleSet.VirtualMachineProfile = new Microsoft.Azure.Management.Compute.Models.VirtualMachineScaleSetVMProfile();
123+
this.VirtualMachineScaleSet.VirtualMachineProfile = new VirtualMachineScaleSetVMProfile();
124124
}
125125

126126
// ExtensionProfile
127127
if (this.VirtualMachineScaleSet.VirtualMachineProfile.ExtensionProfile == null)
128128
{
129-
this.VirtualMachineScaleSet.VirtualMachineProfile.ExtensionProfile = new Microsoft.Azure.Management.Compute.Models.VirtualMachineScaleSetExtensionProfile();
129+
this.VirtualMachineScaleSet.VirtualMachineProfile.ExtensionProfile = new VirtualMachineScaleSetExtensionProfile();
130130
}
131131

132132
// Extensions
133133
if (this.VirtualMachineScaleSet.VirtualMachineProfile.ExtensionProfile.Extensions == null)
134134
{
135-
this.VirtualMachineScaleSet.VirtualMachineProfile.ExtensionProfile.Extensions = new List<Microsoft.Azure.Management.Compute.Models.VirtualMachineScaleSetExtension>();
135+
this.VirtualMachineScaleSet.VirtualMachineProfile.ExtensionProfile.Extensions = new List<VirtualMachineScaleSetExtension>();
136136
}
137137

138138
bool shouldContinue = true;
@@ -162,7 +162,7 @@ protected override void ProcessRecord()
162162
// Parse configs, and auto fill incomplete parts
163163
Tuple<Hashtable, Hashtable> settings = DiagnosticsHelper.GetConfigurationsFromFiles(this.SettingFilePath, this.ProtectedSettingFilePath, this.VirtualMachineScaleSet.Id, this, storageClient);
164164

165-
var newDiagnosticsExtension = new Microsoft.Azure.Management.Compute.Models.VirtualMachineScaleSetExtension();
165+
var newDiagnosticsExtension = new VirtualMachineScaleSetExtension();
166166

167167
newDiagnosticsExtension.Name = this.Name;
168168
newDiagnosticsExtension.Publisher = DiagnosticsExtensionConstants.ExtensionPublisher;

src/ResourceManager/Compute/Commands.Compute/Generated/ContainerService/Config/AddAzureRmContainerServiceAgentPoolProfileCommand.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,10 +77,10 @@ private void Run()
7777
// AgentPoolProfiles
7878
if (this.ContainerService.AgentPoolProfiles == null)
7979
{
80-
this.ContainerService.AgentPoolProfiles = new List<Microsoft.Azure.Management.Compute.Models.ContainerServiceAgentPoolProfile>();
80+
this.ContainerService.AgentPoolProfiles = new List<ContainerServiceAgentPoolProfile>();
8181
}
8282

83-
var vAgentPoolProfiles = new Microsoft.Azure.Management.Compute.Models.ContainerServiceAgentPoolProfile();
83+
var vAgentPoolProfiles = new ContainerServiceAgentPoolProfile();
8484

8585
vAgentPoolProfiles.Name = this.MyInvocation.BoundParameters.ContainsKey("Name") ? this.Name : null;
8686
vAgentPoolProfiles.Count = this.Count;

src/ResourceManager/Compute/Commands.Compute/Generated/ContainerService/Config/NewAzureRmContainerServiceConfigCommand.cs

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -127,31 +127,31 @@ protected override void ProcessRecord()
127127
private void Run()
128128
{
129129
// OrchestratorProfile
130-
Microsoft.Azure.Management.Compute.Models.ContainerServiceOrchestratorProfile vOrchestratorProfile = null;
130+
ContainerServiceOrchestratorProfile vOrchestratorProfile = null;
131131

132132
// CustomProfile
133-
Microsoft.Azure.Management.Compute.Models.ContainerServiceCustomProfile vCustomProfile = null;
133+
ContainerServiceCustomProfile vCustomProfile = null;
134134

135135
// ServicePrincipalProfile
136-
Microsoft.Azure.Management.Compute.Models.ContainerServiceServicePrincipalProfile vServicePrincipalProfile = null;
136+
ContainerServiceServicePrincipalProfile vServicePrincipalProfile = null;
137137

138138
// MasterProfile
139-
Microsoft.Azure.Management.Compute.Models.ContainerServiceMasterProfile vMasterProfile = null;
139+
ContainerServiceMasterProfile vMasterProfile = null;
140140

141141
// WindowsProfile
142-
Microsoft.Azure.Management.Compute.Models.ContainerServiceWindowsProfile vWindowsProfile = null;
142+
ContainerServiceWindowsProfile vWindowsProfile = null;
143143

144144
// LinuxProfile
145-
Microsoft.Azure.Management.Compute.Models.ContainerServiceLinuxProfile vLinuxProfile = null;
145+
ContainerServiceLinuxProfile vLinuxProfile = null;
146146

147147
// DiagnosticsProfile
148-
Microsoft.Azure.Management.Compute.Models.ContainerServiceDiagnosticsProfile vDiagnosticsProfile = null;
148+
ContainerServiceDiagnosticsProfile vDiagnosticsProfile = null;
149149

150150
if (this.MyInvocation.BoundParameters.ContainsKey("OrchestratorType"))
151151
{
152152
if (vOrchestratorProfile == null)
153153
{
154-
vOrchestratorProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceOrchestratorProfile();
154+
vOrchestratorProfile = new ContainerServiceOrchestratorProfile();
155155
}
156156
vOrchestratorProfile.OrchestratorType = this.OrchestratorType.Value;
157157
}
@@ -160,7 +160,7 @@ private void Run()
160160
{
161161
if (vCustomProfile == null)
162162
{
163-
vCustomProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceCustomProfile();
163+
vCustomProfile = new ContainerServiceCustomProfile();
164164
}
165165
vCustomProfile.Orchestrator = this.CustomProfileOrchestrator;
166166
}
@@ -169,7 +169,7 @@ private void Run()
169169
{
170170
if (vServicePrincipalProfile == null)
171171
{
172-
vServicePrincipalProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceServicePrincipalProfile();
172+
vServicePrincipalProfile = new ContainerServiceServicePrincipalProfile();
173173
}
174174
vServicePrincipalProfile.ClientId = this.ServicePrincipalProfileClientId;
175175
}
@@ -178,7 +178,7 @@ private void Run()
178178
{
179179
if (vServicePrincipalProfile == null)
180180
{
181-
vServicePrincipalProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceServicePrincipalProfile();
181+
vServicePrincipalProfile = new ContainerServiceServicePrincipalProfile();
182182
}
183183
vServicePrincipalProfile.Secret = this.ServicePrincipalProfileSecret;
184184
}
@@ -187,7 +187,7 @@ private void Run()
187187
{
188188
if (vMasterProfile == null)
189189
{
190-
vMasterProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceMasterProfile();
190+
vMasterProfile = new ContainerServiceMasterProfile();
191191
}
192192
vMasterProfile.Count = this.MasterCount;
193193
}
@@ -196,7 +196,7 @@ private void Run()
196196
{
197197
if (vMasterProfile == null)
198198
{
199-
vMasterProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceMasterProfile();
199+
vMasterProfile = new ContainerServiceMasterProfile();
200200
}
201201
vMasterProfile.DnsPrefix = this.MasterDnsPrefix;
202202
}
@@ -205,7 +205,7 @@ private void Run()
205205
{
206206
if (vWindowsProfile == null)
207207
{
208-
vWindowsProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceWindowsProfile();
208+
vWindowsProfile = new ContainerServiceWindowsProfile();
209209
}
210210
vWindowsProfile.AdminUsername = this.WindowsProfileAdminUsername;
211211
}
@@ -214,7 +214,7 @@ private void Run()
214214
{
215215
if (vWindowsProfile == null)
216216
{
217-
vWindowsProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceWindowsProfile();
217+
vWindowsProfile = new ContainerServiceWindowsProfile();
218218
}
219219
vWindowsProfile.AdminPassword = this.WindowsProfileAdminPassword;
220220
}
@@ -223,7 +223,7 @@ private void Run()
223223
{
224224
if (vLinuxProfile == null)
225225
{
226-
vLinuxProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceLinuxProfile();
226+
vLinuxProfile = new ContainerServiceLinuxProfile();
227227
}
228228
vLinuxProfile.AdminUsername = this.AdminUsername;
229229
}
@@ -233,31 +233,31 @@ private void Run()
233233
{
234234
if (vLinuxProfile == null)
235235
{
236-
vLinuxProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceLinuxProfile();
236+
vLinuxProfile = new ContainerServiceLinuxProfile();
237237
}
238238
if (vLinuxProfile.Ssh == null)
239239
{
240-
vLinuxProfile.Ssh = new Microsoft.Azure.Management.Compute.Models.ContainerServiceSshConfiguration();
240+
vLinuxProfile.Ssh = new ContainerServiceSshConfiguration();
241241
}
242242
if (vLinuxProfile.Ssh.PublicKeys == null)
243243
{
244-
vLinuxProfile.Ssh.PublicKeys = new List<Microsoft.Azure.Management.Compute.Models.ContainerServiceSshPublicKey>();
244+
vLinuxProfile.Ssh.PublicKeys = new List<ContainerServiceSshPublicKey>();
245245
}
246246
foreach (var element in this.SshPublicKey)
247247
{
248-
var vPublicKeys = new Microsoft.Azure.Management.Compute.Models.ContainerServiceSshPublicKey();
248+
var vPublicKeys = new ContainerServiceSshPublicKey();
249249
vPublicKeys.KeyData = element;
250250
vLinuxProfile.Ssh.PublicKeys.Add(vPublicKeys);
251251
}
252252
}
253253

254254
if (vDiagnosticsProfile == null)
255255
{
256-
vDiagnosticsProfile = new Microsoft.Azure.Management.Compute.Models.ContainerServiceDiagnosticsProfile();
256+
vDiagnosticsProfile = new ContainerServiceDiagnosticsProfile();
257257
}
258258
if (vDiagnosticsProfile.VmDiagnostics == null)
259259
{
260-
vDiagnosticsProfile.VmDiagnostics = new Microsoft.Azure.Management.Compute.Models.ContainerServiceVMDiagnostics();
260+
vDiagnosticsProfile.VmDiagnostics = new ContainerServiceVMDiagnostics();
261261
}
262262

263263
vDiagnosticsProfile.VmDiagnostics.Enabled = this.VmDiagnosticsEnabled;

src/ResourceManager/Compute/Commands.Compute/Generated/Disk/Config/NewAzureRmDiskConfigCommand.cs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -132,19 +132,19 @@ protected override void ProcessRecord()
132132
private void Run()
133133
{
134134
// Sku
135-
Microsoft.Azure.Management.Compute.Models.DiskSku vSku = null;
135+
DiskSku vSku = null;
136136

137137
// CreationData
138-
Microsoft.Azure.Management.Compute.Models.CreationData vCreationData = null;
138+
CreationData vCreationData = null;
139139

140140
// EncryptionSettings
141-
Microsoft.Azure.Management.Compute.Models.EncryptionSettings vEncryptionSettings = null;
141+
EncryptionSettings vEncryptionSettings = null;
142142

143143
if (this.MyInvocation.BoundParameters.ContainsKey("SkuName"))
144144
{
145145
if (vSku == null)
146146
{
147-
vSku = new Microsoft.Azure.Management.Compute.Models.DiskSku();
147+
vSku = new DiskSku();
148148
}
149149
vSku.Name = this.SkuName;
150150
}
@@ -153,7 +153,7 @@ private void Run()
153153
{
154154
if (vCreationData == null)
155155
{
156-
vCreationData = new Microsoft.Azure.Management.Compute.Models.CreationData();
156+
vCreationData = new CreationData();
157157
}
158158
vCreationData.CreateOption = this.CreateOption;
159159
}
@@ -162,7 +162,7 @@ private void Run()
162162
{
163163
if (vCreationData == null)
164164
{
165-
vCreationData = new Microsoft.Azure.Management.Compute.Models.CreationData();
165+
vCreationData = new CreationData();
166166
}
167167
vCreationData.StorageAccountId = this.StorageAccountId;
168168
}
@@ -171,7 +171,7 @@ private void Run()
171171
{
172172
if (vCreationData == null)
173173
{
174-
vCreationData = new Microsoft.Azure.Management.Compute.Models.CreationData();
174+
vCreationData = new CreationData();
175175
}
176176
vCreationData.ImageReference = this.ImageReference;
177177
}
@@ -180,7 +180,7 @@ private void Run()
180180
{
181181
if (vCreationData == null)
182182
{
183-
vCreationData = new Microsoft.Azure.Management.Compute.Models.CreationData();
183+
vCreationData = new CreationData();
184184
}
185185
vCreationData.SourceUri = this.SourceUri;
186186
}
@@ -189,7 +189,7 @@ private void Run()
189189
{
190190
if (vCreationData == null)
191191
{
192-
vCreationData = new Microsoft.Azure.Management.Compute.Models.CreationData();
192+
vCreationData = new CreationData();
193193
}
194194
vCreationData.SourceResourceId = this.SourceResourceId;
195195
}
@@ -198,7 +198,7 @@ private void Run()
198198
{
199199
if (vEncryptionSettings == null)
200200
{
201-
vEncryptionSettings = new Microsoft.Azure.Management.Compute.Models.EncryptionSettings();
201+
vEncryptionSettings = new EncryptionSettings();
202202
}
203203
vEncryptionSettings.Enabled = this.EncryptionSettingsEnabled;
204204
}
@@ -207,7 +207,7 @@ private void Run()
207207
{
208208
if (vEncryptionSettings == null)
209209
{
210-
vEncryptionSettings = new Microsoft.Azure.Management.Compute.Models.EncryptionSettings();
210+
vEncryptionSettings = new EncryptionSettings();
211211
}
212212
vEncryptionSettings.DiskEncryptionKey = this.DiskEncryptionKey;
213213
}
@@ -216,7 +216,7 @@ private void Run()
216216
{
217217
if (vEncryptionSettings == null)
218218
{
219-
vEncryptionSettings = new Microsoft.Azure.Management.Compute.Models.EncryptionSettings();
219+
vEncryptionSettings = new EncryptionSettings();
220220
}
221221
vEncryptionSettings.KeyEncryptionKey = this.KeyEncryptionKey;
222222
}

src/ResourceManager/Compute/Commands.Compute/Generated/Disk/Config/NewAzureRmDiskUpdateConfigCommand.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -96,16 +96,16 @@ protected override void ProcessRecord()
9696
private void Run()
9797
{
9898
// EncryptionSettings
99-
Microsoft.Azure.Management.Compute.Models.EncryptionSettings vEncryptionSettings = null;
99+
EncryptionSettings vEncryptionSettings = null;
100100

101101
// Sku
102-
Microsoft.Azure.Management.Compute.Models.DiskSku vSku = null;
102+
DiskSku vSku = null;
103103

104104
if (this.MyInvocation.BoundParameters.ContainsKey("EncryptionSettingsEnabled"))
105105
{
106106
if (vEncryptionSettings == null)
107107
{
108-
vEncryptionSettings = new Microsoft.Azure.Management.Compute.Models.EncryptionSettings();
108+
vEncryptionSettings = new EncryptionSettings();
109109
}
110110
vEncryptionSettings.Enabled = this.EncryptionSettingsEnabled;
111111
}
@@ -114,7 +114,7 @@ private void Run()
114114
{
115115
if (vEncryptionSettings == null)
116116
{
117-
vEncryptionSettings = new Microsoft.Azure.Management.Compute.Models.EncryptionSettings();
117+
vEncryptionSettings = new EncryptionSettings();
118118
}
119119
vEncryptionSettings.DiskEncryptionKey = this.DiskEncryptionKey;
120120
}
@@ -123,7 +123,7 @@ private void Run()
123123
{
124124
if (vEncryptionSettings == null)
125125
{
126-
vEncryptionSettings = new Microsoft.Azure.Management.Compute.Models.EncryptionSettings();
126+
vEncryptionSettings = new EncryptionSettings();
127127
}
128128
vEncryptionSettings.KeyEncryptionKey = this.KeyEncryptionKey;
129129
}
@@ -132,7 +132,7 @@ private void Run()
132132
{
133133
if (vSku == null)
134134
{
135-
vSku = new Microsoft.Azure.Management.Compute.Models.DiskSku();
135+
vSku = new DiskSku();
136136
}
137137
vSku.Name = this.SkuName;
138138
}

src/ResourceManager/Compute/Commands.Compute/Generated/Disk/Config/SetAzureRmDiskDiskEncryptionKeyCommand.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -67,12 +67,12 @@ private void Run()
6767
// EncryptionSettings
6868
if (this.Disk.EncryptionSettings == null)
6969
{
70-
this.Disk.EncryptionSettings = new Microsoft.Azure.Management.Compute.Models.EncryptionSettings();
70+
this.Disk.EncryptionSettings = new EncryptionSettings();
7171
}
7272
// DiskEncryptionKey
7373
if (this.Disk.EncryptionSettings.DiskEncryptionKey == null)
7474
{
75-
this.Disk.EncryptionSettings.DiskEncryptionKey = new Microsoft.Azure.Management.Compute.Models.KeyVaultAndSecretReference();
75+
this.Disk.EncryptionSettings.DiskEncryptionKey = new KeyVaultAndSecretReference();
7676
}
7777
this.Disk.EncryptionSettings.DiskEncryptionKey.SecretUrl = this.SecretUrl;
7878
}
@@ -82,17 +82,17 @@ private void Run()
8282
// EncryptionSettings
8383
if (this.Disk.EncryptionSettings == null)
8484
{
85-
this.Disk.EncryptionSettings = new Microsoft.Azure.Management.Compute.Models.EncryptionSettings();
85+
this.Disk.EncryptionSettings = new EncryptionSettings();
8686
}
8787
// DiskEncryptionKey
8888
if (this.Disk.EncryptionSettings.DiskEncryptionKey == null)
8989
{
90-
this.Disk.EncryptionSettings.DiskEncryptionKey = new Microsoft.Azure.Management.Compute.Models.KeyVaultAndSecretReference();
90+
this.Disk.EncryptionSettings.DiskEncryptionKey = new KeyVaultAndSecretReference();
9191
}
9292
// SourceVault
9393
if (this.Disk.EncryptionSettings.DiskEncryptionKey.SourceVault == null)
9494
{
95-
this.Disk.EncryptionSettings.DiskEncryptionKey.SourceVault = new Microsoft.Azure.Management.Compute.Models.SourceVault();
95+
this.Disk.EncryptionSettings.DiskEncryptionKey.SourceVault = new SourceVault();
9696
}
9797
this.Disk.EncryptionSettings.DiskEncryptionKey.SourceVault.Id = this.SourceVaultId;
9898
}

0 commit comments

Comments
 (0)