Beispiel #1
0
 ///GENMHASH:FC4CCB4833EA2DD311741B384FD9316F:8E288AFF39988D3B6818D60EB161D26B
 internal RegistryTaskRunImpl(IRegistryManager registryManager, RunInner runInner)
 {
     this.registryManager = registryManager;
     this.registriesInner = registryManager.Inner.Registries;
     this.platform        = new PlatformProperties();
     this.inner           = runInner;
 }
 /// <summary>
 /// Creates a container registry with the specified parameters.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='registry'>
 /// The parameters for creating a container registry.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <RegistryInner> CreateAsync(this IRegistriesOperations operations, string resourceGroupName, string registryName, RegistryInner registry, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CreateWithHttpMessagesAsync(resourceGroupName, registryName, registry, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Beispiel #3
0
 /// <summary>
 /// Regenerates one of the login credentials for the specified container
 /// registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='name'>
 /// Specifies name of the password which should be regenerated -- password or
 /// password2. Possible values include: 'password', 'password2'
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <RegistryListCredentials> RegenerateCredentialAsync(this IRegistriesOperations operations, string resourceGroupName, string registryName, PasswordName name, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.RegenerateCredentialWithHttpMessagesAsync(resourceGroupName, registryName, name, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Schedules a new run based on the request parameters and add it to the run
 /// queue.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='runRequest'>
 /// The parameters of a run that needs to scheduled.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task <RunInner> ScheduleRunAsync(this IRegistriesOperations operations, string resourceGroupName, string registryName, RunRequestInner runRequest, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ScheduleRunWithHttpMessagesAsync(resourceGroupName, registryName, runRequest, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Lists all the container registries under the specified resource group.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <RegistryInner> > ListByResourceGroupAsync(this IRegistriesOperations operations, string resourceGroupName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListByResourceGroupWithHttpMessagesAsync(resourceGroupName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Lists all the container registries under the specified subscription.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <RegistryInner> > ListNextAsync(this IRegistriesOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Beispiel #7
0
 /// <summary>
 /// Updates a container registry with the specified parameters.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='registryUpdateParameters'>
 /// The parameters for updating a container registry.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task <Registry> BeginUpdateAsync(this IRegistriesOperations operations, string resourceGroupName, string registryName, RegistryUpdateParameters registryUpdateParameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.BeginUpdateWithHttpMessagesAsync(resourceGroupName, registryName, registryUpdateParameters, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Beispiel #8
0
 /// <summary>
 /// Updates the policies for the specified container registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='quarantinePolicy'>
 /// An object that represents quarantine policy for a container registry.
 /// </param>
 /// <param name='trustPolicy'>
 /// An object that represents content trust policy for a container registry.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task <RegistryPolicies> BeginUpdatePoliciesAsync(this IRegistriesOperations operations, string resourceGroupName, string registryName, QuarantinePolicy quarantinePolicy = default(QuarantinePolicy), TrustPolicy trustPolicy = default(TrustPolicy), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.BeginUpdatePoliciesWithHttpMessagesAsync(resourceGroupName, registryName, quarantinePolicy, trustPolicy, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Beispiel #9
0
 /// <summary>
 /// Updates the policies for the specified container registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='quarantinePolicy'>
 /// An object that represents quarantine policy for a container registry.
 /// </param>
 /// <param name='trustPolicy'>
 /// An object that represents content trust policy for a container registry.
 /// </param>
 public static RegistryPolicies BeginUpdatePolicies(this IRegistriesOperations operations, string resourceGroupName, string registryName, QuarantinePolicy quarantinePolicy = default(QuarantinePolicy), TrustPolicy trustPolicy = default(TrustPolicy))
 {
     return(operations.BeginUpdatePoliciesAsync(resourceGroupName, registryName, quarantinePolicy, trustPolicy).GetAwaiter().GetResult());
 }
Beispiel #10
0
 /// <summary>
 /// Checks whether the container registry name is available for use. The name
 /// must contain only alphanumeric characters, be globally unique, and between
 /// 5 and 50 characters in length.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='name'>
 /// The name of the container registry.
 /// </param>
 public static RegistryNameStatus CheckNameAvailability(this IRegistriesOperations operations, string name)
 {
     return(operations.CheckNameAvailabilityAsync(name).GetAwaiter().GetResult());
 }
Beispiel #11
0
 /// <summary>
 /// Updates a container registry with the specified parameters.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='registryUpdateParameters'>
 /// The parameters for updating a container registry.
 /// </param>
 public static Registry BeginUpdate(this IRegistriesOperations operations, string resourceGroupName, string registryName, RegistryUpdateParameters registryUpdateParameters)
 {
     return(operations.BeginUpdateAsync(resourceGroupName, registryName, registryUpdateParameters).GetAwaiter().GetResult());
 }
Beispiel #12
0
 /// <summary>
 /// Lists all the container registries under the specified subscription.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 public static IPage <Registry> ListNext(this IRegistriesOperations operations, string nextPageLink)
 {
     return(operations.ListNextAsync(nextPageLink).GetAwaiter().GetResult());
 }
Beispiel #13
0
 /// <summary>
 /// Creates a container registry with the specified parameters.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='registry'>
 /// The parameters for creating a container registry.
 /// </param>
 public static Registry Create(this IRegistriesOperations operations, string resourceGroupName, string registryName, Registry registry)
 {
     return(operations.CreateAsync(resourceGroupName, registryName, registry).GetAwaiter().GetResult());
 }
Beispiel #14
0
 /// <summary>
 /// Generate keys for a token of a specified container registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='generateCredentialsParameters'>
 /// The parameters for generating credentials.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task <GenerateCredentialsResult> GenerateCredentialsAsync(this IRegistriesOperations operations, string resourceGroupName, string registryName, GenerateCredentialsParameters generateCredentialsParameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GenerateCredentialsWithHttpMessagesAsync(resourceGroupName, registryName, generateCredentialsParameters, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Deletes a container registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task BeginDeleteAsync(this IRegistriesOperations operations, string resourceGroupName, string registryName, CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.BeginDeleteWithHttpMessagesAsync(resourceGroupName, registryName, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
Beispiel #16
0
 /// <summary>
 /// Regenerates one of the login credentials for the specified container
 /// registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='name'>
 /// Specifies name of the password which should be regenerated -- password or
 /// password2. Possible values include: 'password', 'password2'
 /// </param>
 public static RegistryListCredentialsResult RegenerateCredential(this IRegistriesOperations operations, string resourceGroupName, string registryName, PasswordName name)
 {
     return(operations.RegenerateCredentialAsync(resourceGroupName, registryName, name).GetAwaiter().GetResult());
 }
Beispiel #17
0
 /// <summary>
 /// Lists the policies for the specified container registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 public static RegistryPolicies ListPolicies(this IRegistriesOperations operations, string resourceGroupName, string registryName)
 {
     return(operations.ListPoliciesAsync(resourceGroupName, registryName).GetAwaiter().GetResult());
 }
Beispiel #18
0
 /// <summary>
 /// Lists the login credentials for the specified container registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 public static RegistryListCredentialsResult ListCredentials(this IRegistriesOperations operations, string resourceGroupName, string registryName)
 {
     return(operations.ListCredentialsAsync(resourceGroupName, registryName).GetAwaiter().GetResult());
 }
Beispiel #19
0
 /// <summary>
 /// Lists all the container registries under the specified subscription.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 public static IPage <Registry> List(this IRegistriesOperations operations)
 {
     return(operations.ListAsync().GetAwaiter().GetResult());
 }
Beispiel #20
0
 /// <summary>
 /// Lists all the container registries under the specified resource group.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 public static IPage <Registry> ListByResourceGroup(this IRegistriesOperations operations, string resourceGroupName)
 {
     return(operations.ListByResourceGroupAsync(resourceGroupName).GetAwaiter().GetResult());
 }
Beispiel #21
0
 /// <summary>
 /// Generate keys for a token of a specified container registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='generateCredentialsParameters'>
 /// The parameters for generating credentials.
 /// </param>
 public static GenerateCredentialsResult BeginGenerateCredentials(this IRegistriesOperations operations, string resourceGroupName, string registryName, GenerateCredentialsParameters generateCredentialsParameters)
 {
     return(operations.BeginGenerateCredentialsAsync(resourceGroupName, registryName, generateCredentialsParameters).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Checks whether the container registry name is available for use. The name
 /// must contain only alphanumeric characters, be globally unique, and between
 /// 5 and 50 characters in length.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='name'>
 /// The name of the container registry.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <RegistryNameStatusInner> CheckNameAvailabilityAsync(this IRegistriesOperations operations, string name, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CheckNameAvailabilityWithHttpMessagesAsync(name, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Beispiel #23
0
 /// <summary>
 /// Lists all the container registries under the specified resource group.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task <IPage <Registry> > ListByResourceGroupNextAsync(this IRegistriesOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListByResourceGroupNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Lists the policies for the specified container registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task <RegistryPoliciesInner> ListPoliciesAsync(this IRegistriesOperations operations, string resourceGroupName, string registryName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListPoliciesWithHttpMessagesAsync(resourceGroupName, registryName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Beispiel #25
0
 /// <summary>
 /// Copies an image to this container registry from the specified container
 /// registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='parameters'>
 /// The parameters specifying the image to copy and the source container
 /// registry.
 /// </param>
 public static void BeginImportImage(this IRegistriesOperations operations, string resourceGroupName, string registryName, ImportImageParameters parameters)
 {
     operations.BeginImportImageAsync(resourceGroupName, registryName, parameters).GetAwaiter().GetResult();
 }
 /// <summary>
 /// Get the upload location for the user to be able to upload the source.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task <SourceUploadDefinitionInner> GetBuildSourceUploadUrlAsync(this IRegistriesOperations operations, string resourceGroupName, string registryName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetBuildSourceUploadUrlWithHttpMessagesAsync(resourceGroupName, registryName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Schedules a new run based on the request parameters and add it to the run
 /// queue.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='runRequest'>
 /// The parameters of a run that needs to scheduled.
 /// </param>
 public static Run BeginScheduleRun(this IRegistriesOperations operations, string resourceGroupName, string registryName, RunRequest runRequest)
 {
     return(operations.BeginScheduleRunAsync(resourceGroupName, registryName, runRequest).GetAwaiter().GetResult());
 }
Beispiel #28
0
 /// <summary>
 /// Deletes a container registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 public static void BeginDelete(this IRegistriesOperations operations, string resourceGroupName, string registryName)
 {
     operations.BeginDeleteAsync(resourceGroupName, registryName).GetAwaiter().GetResult();
 }
Beispiel #29
0
 /// <summary>
 /// Copies an image to this container registry from the specified container
 /// registry.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group to which the container registry belongs.
 /// </param>
 /// <param name='registryName'>
 /// The name of the container registry.
 /// </param>
 /// <param name='parameters'>
 /// The parameters specifying the image to copy and the source container
 /// registry.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task BeginImportImageAsync(this IRegistriesOperations operations, string resourceGroupName, string registryName, ImportImageParameters parameters, CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.BeginImportImageWithHttpMessagesAsync(resourceGroupName, registryName, parameters, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
 /// <summary>
 /// Lists all the container registries under the specified subscription.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task <IPage <RegistryInner> > ListAsync(this IRegistriesOperations operations, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListWithHttpMessagesAsync(null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }