@lbrlabs/pulumi-tailscalebastion
Version:
This repo provides a [multi-language](https://www.pulumi.com/blog/pulumiup-pulumi-packages-multi-language-components/) component that creates a [Tailscale](https://tailscale.com/) [Subnet Router](https://tailscale.com/kb/1019/subnets/) in your chosen clou
60 lines • 2.83 kB
JavaScript
;
// *** WARNING: this file was generated by Pulumi SDK Generator. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
Object.defineProperty(exports, "__esModule", { value: true });
exports.Bastion = void 0;
const pulumi = require("@pulumi/pulumi");
const utilities = require("../utilities");
class Bastion extends pulumi.ComponentResource {
/**
* Create a Bastion 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) {
var _a;
let resourceInputs = {};
opts = opts || {};
if (!opts.id) {
if ((!args || args.createNamespace === undefined) && !opts.urn) {
throw new Error("Missing required property 'createNamespace'");
}
if ((!args || args.highAvailability === undefined) && !opts.urn) {
throw new Error("Missing required property 'highAvailability'");
}
if ((!args || args.routes === undefined) && !opts.urn) {
throw new Error("Missing required property 'routes'");
}
if ((!args || args.tailscaleTags === undefined) && !opts.urn) {
throw new Error("Missing required property 'tailscaleTags'");
}
resourceInputs["createNamespace"] = args ? args.createNamespace : undefined;
resourceInputs["highAvailability"] = (_a = (args ? args.highAvailability : undefined)) !== null && _a !== void 0 ? _a : false;
resourceInputs["namespace"] = args ? args.namespace : undefined;
resourceInputs["routes"] = args ? args.routes : undefined;
resourceInputs["tailscaleTags"] = args ? args.tailscaleTags : undefined;
resourceInputs["deploymentName"] = undefined /*out*/;
}
else {
resourceInputs["deploymentName"] = undefined /*out*/;
}
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
super(Bastion.__pulumiType, name, resourceInputs, opts, true /*remote*/);
}
/**
* Returns true if the given object is an instance of Bastion. 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'] === Bastion.__pulumiType;
}
}
exports.Bastion = Bastion;
/** @internal */
Bastion.__pulumiType = 'tailscale-bastion:kubernetes:Bastion';
//# sourceMappingURL=bastion.js.map