All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.github.ActionsRunnerGroup Maven / Gradle / Ivy

There is a newer version: 6.4.0-alpha.1731735876
Show newest version
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.github;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import com.pulumi.github.ActionsRunnerGroupArgs;
import com.pulumi.github.Utilities;
import com.pulumi.github.inputs.ActionsRunnerGroupState;
import java.lang.Boolean;
import java.lang.Integer;
import java.lang.String;
import java.util.List;
import java.util.Optional;
import javax.annotation.Nullable;

/**
 * This resource allows you to create and manage GitHub Actions runner groups within your GitHub enterprise organizations.
 * You must have admin access to an organization to use this resource.
 * 
 * ## Example Usage
 * 
 * <!--Start PulumiCodeChooser -->
 * 
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.github.Repository;
 * import com.pulumi.github.RepositoryArgs;
 * import com.pulumi.github.ActionsRunnerGroup;
 * import com.pulumi.github.ActionsRunnerGroupArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         var example = new Repository("example", RepositoryArgs.builder()
 *             .name("my-repository")
 *             .build());
 * 
 *         var exampleActionsRunnerGroup = new ActionsRunnerGroup("exampleActionsRunnerGroup", ActionsRunnerGroupArgs.builder()
 *             .name(example.name())
 *             .visibility("selected")
 *             .selectedRepositoryIds(example.repoId())
 *             .build());
 * 
 *     }
 * }
 * }
 * 
* <!--End PulumiCodeChooser --> * * ## Import * * This resource can be imported using the ID of the runner group: * * ```sh * $ pulumi import github:index/actionsRunnerGroup:ActionsRunnerGroup test 7 * ``` * */ @ResourceType(type="github:index/actionsRunnerGroup:ActionsRunnerGroup") public class ActionsRunnerGroup extends com.pulumi.resources.CustomResource { /** * Whether public repositories can be added to the runner group. Defaults to false. * */ @Export(name="allowsPublicRepositories", refs={Boolean.class}, tree="[0]") private Output allowsPublicRepositories; /** * @return Whether public repositories can be added to the runner group. Defaults to false. * */ public Output> allowsPublicRepositories() { return Codegen.optional(this.allowsPublicRepositories); } /** * Whether this is the default runner group * */ @Export(name="default", refs={Boolean.class}, tree="[0]") private Output default_; /** * @return Whether this is the default runner group * */ public Output default_() { return this.default_; } /** * An etag representing the runner group object * */ @Export(name="etag", refs={String.class}, tree="[0]") private Output etag; /** * @return An etag representing the runner group object * */ public Output etag() { return this.etag; } /** * Whether the runner group is inherited from the enterprise level * */ @Export(name="inherited", refs={Boolean.class}, tree="[0]") private Output inherited; /** * @return Whether the runner group is inherited from the enterprise level * */ public Output inherited() { return this.inherited; } /** * Name of the runner group * */ @Export(name="name", refs={String.class}, tree="[0]") private Output name; /** * @return Name of the runner group * */ public Output name() { return this.name; } /** * If true, the runner group will be restricted to running only the workflows specified in the selected_workflows array. Defaults to false. * */ @Export(name="restrictedToWorkflows", refs={Boolean.class}, tree="[0]") private Output restrictedToWorkflows; /** * @return If true, the runner group will be restricted to running only the workflows specified in the selected_workflows array. Defaults to false. * */ public Output> restrictedToWorkflows() { return Codegen.optional(this.restrictedToWorkflows); } /** * The GitHub API URL for the runner group's runners * */ @Export(name="runnersUrl", refs={String.class}, tree="[0]") private Output runnersUrl; /** * @return The GitHub API URL for the runner group's runners * */ public Output runnersUrl() { return this.runnersUrl; } /** * GitHub API URL for the runner group's repositories * */ @Export(name="selectedRepositoriesUrl", refs={String.class}, tree="[0]") private Output selectedRepositoriesUrl; /** * @return GitHub API URL for the runner group's repositories * */ public Output selectedRepositoriesUrl() { return this.selectedRepositoriesUrl; } /** * IDs of the repositories which should be added to the runner group * */ @Export(name="selectedRepositoryIds", refs={List.class,Integer.class}, tree="[0,1]") private Output> selectedRepositoryIds; /** * @return IDs of the repositories which should be added to the runner group * */ public Output>> selectedRepositoryIds() { return Codegen.optional(this.selectedRepositoryIds); } /** * List of workflows the runner group should be allowed to run. This setting will be ignored unless restricted_to_workflows is set to true. * */ @Export(name="selectedWorkflows", refs={List.class,String.class}, tree="[0,1]") private Output> selectedWorkflows; /** * @return List of workflows the runner group should be allowed to run. This setting will be ignored unless restricted_to_workflows is set to true. * */ public Output>> selectedWorkflows() { return Codegen.optional(this.selectedWorkflows); } /** * Visibility of a runner group. Whether the runner group can include `all`, `selected`, or `private` repositories. A value of `private` is not currently supported due to limitations in the GitHub API. * */ @Export(name="visibility", refs={String.class}, tree="[0]") private Output visibility; /** * @return Visibility of a runner group. Whether the runner group can include `all`, `selected`, or `private` repositories. A value of `private` is not currently supported due to limitations in the GitHub API. * */ public Output visibility() { return this.visibility; } /** * * @param name The _unique_ name of the resulting resource. */ public ActionsRunnerGroup(java.lang.String name) { this(name, ActionsRunnerGroupArgs.Empty); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. */ public ActionsRunnerGroup(java.lang.String name, ActionsRunnerGroupArgs args) { this(name, args, null); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. * @param options A bag of options that control this resource's behavior. */ public ActionsRunnerGroup(java.lang.String name, ActionsRunnerGroupArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("github:index/actionsRunnerGroup:ActionsRunnerGroup", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()), false); } private ActionsRunnerGroup(java.lang.String name, Output id, @Nullable ActionsRunnerGroupState state, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("github:index/actionsRunnerGroup:ActionsRunnerGroup", name, state, makeResourceOptions(options, id), false); } private static ActionsRunnerGroupArgs makeArgs(ActionsRunnerGroupArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { if (options != null && options.getUrn().isPresent()) { return null; } return args == null ? ActionsRunnerGroupArgs.Empty : args; } private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output id) { var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder() .version(Utilities.getVersion()) .build(); return com.pulumi.resources.CustomResourceOptions.merge(defaultOptions, options, id); } /** * Get an existing Host resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state * @param options Optional settings to control the behavior of the CustomResource. */ public static ActionsRunnerGroup get(java.lang.String name, Output id, @Nullable ActionsRunnerGroupState state, @Nullable com.pulumi.resources.CustomResourceOptions options) { return new ActionsRunnerGroup(name, id, state, options); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy