Workforce Pool
Represents a collection of external workforces. Provides namespaces for federated users that can be referenced in IAM policies. To get more information about WorkforcePool, see:
How-to Guides
Note: Ask your Google Cloud account team to request access to workforce identity federation for your billing/quota project. The account team notifies you when the project is granted access.
Example Usage
Iam Workforce Pool Basic
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.iam.WorkforcePool;
import com.pulumi.gcp.iam.WorkforcePoolArgs;
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 WorkforcePool("example", WorkforcePoolArgs.builder()
.location("global")
.parent("organizations/123456789")
.workforcePoolId("example-pool")
.build());
}
}
Iam Workforce Pool Full
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.iam.WorkforcePool;
import com.pulumi.gcp.iam.WorkforcePoolArgs;
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 WorkforcePool("example", WorkforcePoolArgs.builder()
.description("A sample workforce pool.")
.disabled(false)
.displayName("Display name")
.location("global")
.parent("organizations/123456789")
.sessionDuration("7200s")
.workforcePoolId("example-pool")
.build());
}
}
Import
WorkforcePool can be imported using any of these accepted formats
$ pulumi import gcp:iam/workforcePool:WorkforcePool default locations/{{location}}/workforcePools/{{workforce_pool_id}}
$ pulumi import gcp:iam/workforcePool:WorkforcePool default {{location}}/{{workforce_pool_id}}
Properties
A user-specified description of the pool. Cannot exceed 256 characters.
A user-specified display name of the pool in Google Cloud Console. Cannot exceed 32 characters.
Duration that the Google Cloud access tokens, console sign-in sessions, and gcloud
sign-in sessions from this pool are valid. Must be greater than 15 minutes (900s) and less than 12 hours (43200s). If sessionDuration
is not configured, minted credentials have a default duration of one hour (3600s). A duration in seconds with up to nine fractional digits, ending with 's
'. Example: "3.5s
".
The name of the pool. The ID must be a globally unique string of 6 to 63 lowercase letters, digits, or hyphens. It must start with a letter, and cannot have a trailing hyphen. The prefix gcp-
is reserved for use by Google, and may not be specified.