getRegistryImage

This data source fetches the project name, and provides the appropriate URLs to use for container registry for this project. The URLs are computed entirely offline - as long as the project exists, they will be valid, but this data source does not contact Google Container Registry (GCR) at any point.

Example Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.gcp.container.ContainerFunctions;
import com.pulumi.gcp.container.inputs.GetRegistryImageArgs;
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) {
final var debian = ContainerFunctions.getRegistryImage(GetRegistryImageArgs.builder()
.name("debian")
.build());
ctx.export("gcrLocation", debian.applyValue(getRegistryImageResult -> getRegistryImageResult.imageUrl()));
}
}

Return

A collection of values returned by getRegistryImage.

Parameters

argument

A collection of arguments for invoking getRegistryImage.


suspend fun getRegistryImage(digest: String? = null, name: String, project: String? = null, region: String? = null, tag: String? = null): GetRegistryImageResult

Return

A collection of values returned by getRegistryImage.

Parameters

digest

The image digest to fetch, if any.

name

The image name.

project

The project ID that this image is attached to. If not provider, provider project will be used instead.

region

The GCR region to use. As of this writing, one of asia, eu, and us. See the documentation for additional information.

tag

The tag to fetch, if any.

See also


Return

A collection of values returned by getRegistryImage.

Parameters

argument

Builder for com.pulumi.gcp.container.kotlin.inputs.GetRegistryImagePlainArgs.

See also