@pulumi/awsx
Version:
[](https://github.com/pulumi/pulumi-awsx/actions) [](https://slack.pulumi.com) [;
exports.Image = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
/**
* Builds a docker image and pushes to the ECR repository
*/
class Image extends pulumi.ComponentResource {
/**
* Returns true if the given object is an instance of Image. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
static isInstance(obj) {
if (obj === undefined || obj === null) {
return false;
}
return obj['__pulumiType'] === Image.__pulumiType;
}
/**
* Create a Image resource with the given unique name, arguments, and options.
*
* @param name The _unique_ name of the resource.
* @param args The arguments to use to populate this resource's properties.
* @param opts A bag of options that control this resource's behavior.
*/
constructor(name, args, opts) {
let resourceInputs = {};
opts = opts || {};
if (!opts.id) {
if (args?.repositoryUrl === undefined && !opts.urn) {
throw new Error("Missing required property 'repositoryUrl'");
}
resourceInputs["args"] = args?.args;
resourceInputs["builderVersion"] = args?.builderVersion;
resourceInputs["cacheFrom"] = args?.cacheFrom;
resourceInputs["context"] = args?.context;
resourceInputs["dockerfile"] = args?.dockerfile;
resourceInputs["imageName"] = args?.imageName;
resourceInputs["imageTag"] = args?.imageTag;
resourceInputs["platform"] = args?.platform;
resourceInputs["registryId"] = args?.registryId;
resourceInputs["repositoryUrl"] = args?.repositoryUrl;
resourceInputs["target"] = args?.target;
resourceInputs["imageUri"] = undefined /*out*/;
}
else {
resourceInputs["imageUri"] = undefined /*out*/;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(Image.__pulumiType, name, resourceInputs, opts, true /*remote*/);
}
}
exports.Image = Image;
/** @internal */
Image.__pulumiType = 'awsx:ecr:Image';
//# sourceMappingURL=image.js.map