@bambamboole/coolify 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +202 -0
- package/README.md +1 -0
- package/application.d.ts +88 -0
- package/application.js +137 -0
- package/application.ts +174 -0
- package/database.d.ts +69 -0
- package/database.js +128 -0
- package/database.ts +146 -0
- package/deployment.d.ts +57 -0
- package/deployment.js +94 -0
- package/deployment.ts +100 -0
- package/index.d.ts +27 -0
- package/index.js +83 -0
- package/index.ts +88 -0
- package/package.json +36 -0
- package/privateKey.d.ts +47 -0
- package/privateKey.js +89 -0
- package/privateKey.ts +85 -0
- package/project.d.ts +53 -0
- package/project.js +88 -0
- package/project.ts +90 -0
- package/provider.d.ts +41 -0
- package/provider.js +71 -0
- package/provider.ts +70 -0
- package/s3storage.d.ts +57 -0
- package/s3storage.js +108 -0
- package/s3storage.ts +114 -0
- package/server.d.ts +50 -0
- package/server.js +100 -0
- package/server.ts +99 -0
- package/utilities.d.ts +5 -0
- package/utilities.js +114 -0
- package/utilities.ts +96 -0
package/server.ts
ADDED
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
2
|
+
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
3
|
+
|
|
4
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
5
|
+
import * as utilities from "./utilities";
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* A Coolify server connected over SSH with a Coolify private key.
|
|
9
|
+
*/
|
|
10
|
+
export class Server extends pulumi.CustomResource {
|
|
11
|
+
/**
|
|
12
|
+
* Get an existing Server resource's state with the given name, ID, and optional extra
|
|
13
|
+
* properties used to qualify the lookup.
|
|
14
|
+
*
|
|
15
|
+
* @param name The _unique_ name of the resulting resource.
|
|
16
|
+
* @param id The _unique_ provider ID of the resource to lookup.
|
|
17
|
+
* @param opts Optional settings to control the behavior of the CustomResource.
|
|
18
|
+
*/
|
|
19
|
+
public static get(name: string, id: pulumi.Input<pulumi.ID>, opts?: pulumi.CustomResourceOptions): Server {
|
|
20
|
+
return new Server(name, undefined as any, { ...opts, id: id });
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/** @internal */
|
|
24
|
+
public static readonly __pulumiType = 'coolify:index:Server';
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Returns true if the given object is an instance of Server. This is designed to work even
|
|
28
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
29
|
+
*/
|
|
30
|
+
public static isInstance(obj: any): obj is Server {
|
|
31
|
+
if (obj === undefined || obj === null) {
|
|
32
|
+
return false;
|
|
33
|
+
}
|
|
34
|
+
return obj['__pulumiType'] === Server.__pulumiType;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
declare public readonly description: pulumi.Output<string>;
|
|
38
|
+
declare public readonly ip: pulumi.Output<string>;
|
|
39
|
+
declare public readonly name: pulumi.Output<string>;
|
|
40
|
+
declare public readonly port: pulumi.Output<number>;
|
|
41
|
+
declare public readonly privateKeyUuid: pulumi.Output<string>;
|
|
42
|
+
declare public readonly user: pulumi.Output<string>;
|
|
43
|
+
declare public /*out*/ readonly uuid: pulumi.Output<string>;
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* Create a Server resource with the given unique name, arguments, and options.
|
|
47
|
+
*
|
|
48
|
+
* @param name The _unique_ name of the resource.
|
|
49
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
50
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
51
|
+
*/
|
|
52
|
+
constructor(name: string, args: ServerArgs, opts?: pulumi.CustomResourceOptions) {
|
|
53
|
+
let resourceInputs: pulumi.Inputs = {};
|
|
54
|
+
opts = opts || {};
|
|
55
|
+
if (!opts.id) {
|
|
56
|
+
if (args?.ip === undefined && !opts.urn) {
|
|
57
|
+
throw new Error("Missing required property 'ip'");
|
|
58
|
+
}
|
|
59
|
+
if (args?.name === undefined && !opts.urn) {
|
|
60
|
+
throw new Error("Missing required property 'name'");
|
|
61
|
+
}
|
|
62
|
+
if (args?.privateKeyUuid === undefined && !opts.urn) {
|
|
63
|
+
throw new Error("Missing required property 'privateKeyUuid'");
|
|
64
|
+
}
|
|
65
|
+
resourceInputs["description"] = args?.description;
|
|
66
|
+
resourceInputs["ip"] = args?.ip;
|
|
67
|
+
resourceInputs["name"] = args?.name;
|
|
68
|
+
resourceInputs["port"] = args?.port;
|
|
69
|
+
resourceInputs["privateKeyUuid"] = args?.privateKeyUuid;
|
|
70
|
+
resourceInputs["user"] = args?.user;
|
|
71
|
+
resourceInputs["uuid"] = undefined /*out*/;
|
|
72
|
+
} else {
|
|
73
|
+
resourceInputs["description"] = undefined /*out*/;
|
|
74
|
+
resourceInputs["ip"] = undefined /*out*/;
|
|
75
|
+
resourceInputs["name"] = undefined /*out*/;
|
|
76
|
+
resourceInputs["port"] = undefined /*out*/;
|
|
77
|
+
resourceInputs["privateKeyUuid"] = undefined /*out*/;
|
|
78
|
+
resourceInputs["user"] = undefined /*out*/;
|
|
79
|
+
resourceInputs["uuid"] = undefined /*out*/;
|
|
80
|
+
}
|
|
81
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
82
|
+
super(Server.__pulumiType, name, resourceInputs, opts);
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
* The set of arguments for constructing a Server resource.
|
|
88
|
+
*/
|
|
89
|
+
export interface ServerArgs {
|
|
90
|
+
description?: pulumi.Input<string | undefined>;
|
|
91
|
+
ip: pulumi.Input<string>;
|
|
92
|
+
name: pulumi.Input<string>;
|
|
93
|
+
port?: pulumi.Input<number | undefined>;
|
|
94
|
+
/**
|
|
95
|
+
* UUID of the Coolify private key used to connect. Usually the id output of a PrivateKey resource.
|
|
96
|
+
*/
|
|
97
|
+
privateKeyUuid: pulumi.Input<string>;
|
|
98
|
+
user?: pulumi.Input<string | undefined>;
|
|
99
|
+
}
|
package/utilities.d.ts
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export declare function getEnv(...vars: string[]): string | undefined;
|
|
2
|
+
export declare function getEnvBoolean(...vars: string[]): boolean | undefined;
|
|
3
|
+
export declare function getEnvNumber(...vars: string[]): number | undefined;
|
|
4
|
+
export declare function getVersion(): string;
|
|
5
|
+
//# sourceMappingURL=utilities.d.ts.map
|
package/utilities.js
ADDED
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
3
|
+
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
5
|
+
if (k2 === undefined) k2 = k;
|
|
6
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
7
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
8
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
9
|
+
}
|
|
10
|
+
Object.defineProperty(o, k2, desc);
|
|
11
|
+
}) : (function(o, m, k, k2) {
|
|
12
|
+
if (k2 === undefined) k2 = k;
|
|
13
|
+
o[k2] = m[k];
|
|
14
|
+
}));
|
|
15
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
16
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
17
|
+
}) : function(o, v) {
|
|
18
|
+
o["default"] = v;
|
|
19
|
+
});
|
|
20
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
21
|
+
if (mod && mod.__esModule) return mod;
|
|
22
|
+
var result = {};
|
|
23
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
24
|
+
__setModuleDefault(result, mod);
|
|
25
|
+
return result;
|
|
26
|
+
};
|
|
27
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
28
|
+
exports.callAsync = exports.lazyLoad = exports.resourceOptsDefaults = exports.getVersion = exports.getEnvNumber = exports.getEnvBoolean = exports.getEnv = void 0;
|
|
29
|
+
const runtime = __importStar(require("@pulumi/pulumi/runtime"));
|
|
30
|
+
function getEnv(...vars) {
|
|
31
|
+
for (const v of vars) {
|
|
32
|
+
const value = process.env[v];
|
|
33
|
+
if (value) {
|
|
34
|
+
return value;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
return undefined;
|
|
38
|
+
}
|
|
39
|
+
exports.getEnv = getEnv;
|
|
40
|
+
function getEnvBoolean(...vars) {
|
|
41
|
+
const s = getEnv(...vars);
|
|
42
|
+
if (s !== undefined) {
|
|
43
|
+
// NOTE: these values are taken from https://golang.org/src/strconv/atob.go?s=351:391#L1, which is what
|
|
44
|
+
// Terraform uses internally when parsing boolean values.
|
|
45
|
+
if (["1", "t", "T", "true", "TRUE", "True"].find(v => v === s) !== undefined) {
|
|
46
|
+
return true;
|
|
47
|
+
}
|
|
48
|
+
if (["0", "f", "F", "false", "FALSE", "False"].find(v => v === s) !== undefined) {
|
|
49
|
+
return false;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
return undefined;
|
|
53
|
+
}
|
|
54
|
+
exports.getEnvBoolean = getEnvBoolean;
|
|
55
|
+
function getEnvNumber(...vars) {
|
|
56
|
+
const s = getEnv(...vars);
|
|
57
|
+
if (s !== undefined) {
|
|
58
|
+
const f = parseFloat(s);
|
|
59
|
+
if (!isNaN(f)) {
|
|
60
|
+
return f;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
return undefined;
|
|
64
|
+
}
|
|
65
|
+
exports.getEnvNumber = getEnvNumber;
|
|
66
|
+
function getVersion() {
|
|
67
|
+
let version = require('./package.json').version;
|
|
68
|
+
// Node allows for the version to be prefixed by a "v", while semver doesn't.
|
|
69
|
+
// If there is a v, strip it off.
|
|
70
|
+
if (version.indexOf('v') === 0) {
|
|
71
|
+
version = version.slice(1);
|
|
72
|
+
}
|
|
73
|
+
return version;
|
|
74
|
+
}
|
|
75
|
+
exports.getVersion = getVersion;
|
|
76
|
+
/** @internal */
|
|
77
|
+
function resourceOptsDefaults() {
|
|
78
|
+
return { version: getVersion(), pluginDownloadURL: "https://github.com/bambamboole/pulumi-provider-coolify/releases/download/v$%7BVERSION%7D" };
|
|
79
|
+
}
|
|
80
|
+
exports.resourceOptsDefaults = resourceOptsDefaults;
|
|
81
|
+
/** @internal */
|
|
82
|
+
function lazyLoad(exports, props, loadModule) {
|
|
83
|
+
for (let property of props) {
|
|
84
|
+
Object.defineProperty(exports, property, {
|
|
85
|
+
enumerable: true,
|
|
86
|
+
get: function () {
|
|
87
|
+
return loadModule()[property];
|
|
88
|
+
},
|
|
89
|
+
});
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
exports.lazyLoad = lazyLoad;
|
|
93
|
+
/** @internal */
|
|
94
|
+
async function callAsync(tok, props, res, opts) {
|
|
95
|
+
const o = runtime.call(tok, props, res);
|
|
96
|
+
const value = await o.promise(true /*withUnknowns*/);
|
|
97
|
+
const isKnown = await o.isKnown;
|
|
98
|
+
const isSecret = await o.isSecret;
|
|
99
|
+
const problem = !isKnown ? "an unknown value"
|
|
100
|
+
: isSecret ? "a secret value"
|
|
101
|
+
: undefined;
|
|
102
|
+
// Ingoring o.resources silently. They are typically non-empty, r.f() calls include r as a dependency.
|
|
103
|
+
if (problem) {
|
|
104
|
+
throw new Error(`Plain resource method "${tok}" incorrectly returned ${problem}. ` +
|
|
105
|
+
"This is an error in the provider, please report this to the provider developer.");
|
|
106
|
+
}
|
|
107
|
+
// Extract a single property if requested.
|
|
108
|
+
if (opts && opts.property) {
|
|
109
|
+
return value[opts.property];
|
|
110
|
+
}
|
|
111
|
+
return value;
|
|
112
|
+
}
|
|
113
|
+
exports.callAsync = callAsync;
|
|
114
|
+
//# sourceMappingURL=utilities.js.map
|
package/utilities.ts
ADDED
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
2
|
+
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
import * as runtime from "@pulumi/pulumi/runtime";
|
|
6
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
7
|
+
|
|
8
|
+
export function getEnv(...vars: string[]): string | undefined {
|
|
9
|
+
for (const v of vars) {
|
|
10
|
+
const value = process.env[v];
|
|
11
|
+
if (value) {
|
|
12
|
+
return value;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
return undefined;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export function getEnvBoolean(...vars: string[]): boolean | undefined {
|
|
19
|
+
const s = getEnv(...vars);
|
|
20
|
+
if (s !== undefined) {
|
|
21
|
+
// NOTE: these values are taken from https://golang.org/src/strconv/atob.go?s=351:391#L1, which is what
|
|
22
|
+
// Terraform uses internally when parsing boolean values.
|
|
23
|
+
if (["1", "t", "T", "true", "TRUE", "True"].find(v => v === s) !== undefined) {
|
|
24
|
+
return true;
|
|
25
|
+
}
|
|
26
|
+
if (["0", "f", "F", "false", "FALSE", "False"].find(v => v === s) !== undefined) {
|
|
27
|
+
return false;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
return undefined;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export function getEnvNumber(...vars: string[]): number | undefined {
|
|
34
|
+
const s = getEnv(...vars);
|
|
35
|
+
if (s !== undefined) {
|
|
36
|
+
const f = parseFloat(s);
|
|
37
|
+
if (!isNaN(f)) {
|
|
38
|
+
return f;
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
return undefined;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export function getVersion(): string {
|
|
45
|
+
let version = require('./package.json').version;
|
|
46
|
+
// Node allows for the version to be prefixed by a "v", while semver doesn't.
|
|
47
|
+
// If there is a v, strip it off.
|
|
48
|
+
if (version.indexOf('v') === 0) {
|
|
49
|
+
version = version.slice(1);
|
|
50
|
+
}
|
|
51
|
+
return version;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
/** @internal */
|
|
55
|
+
export function resourceOptsDefaults(): any {
|
|
56
|
+
return { version: getVersion(), pluginDownloadURL: "https://github.com/bambamboole/pulumi-provider-coolify/releases/download/v$%7BVERSION%7D" };
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
/** @internal */
|
|
60
|
+
export function lazyLoad(exports: any, props: string[], loadModule: any) {
|
|
61
|
+
for (let property of props) {
|
|
62
|
+
Object.defineProperty(exports, property, {
|
|
63
|
+
enumerable: true,
|
|
64
|
+
get: function() {
|
|
65
|
+
return loadModule()[property];
|
|
66
|
+
},
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
/** @internal */
|
|
72
|
+
export async function callAsync<T>(
|
|
73
|
+
tok: string,
|
|
74
|
+
props: pulumi.Inputs,
|
|
75
|
+
res?: pulumi.Resource,
|
|
76
|
+
opts?: {property?: string},
|
|
77
|
+
): Promise<T> {
|
|
78
|
+
const o: any = runtime.call<T>(tok, props, res);
|
|
79
|
+
const value = await o.promise(true /*withUnknowns*/);
|
|
80
|
+
const isKnown = await o.isKnown;
|
|
81
|
+
const isSecret = await o.isSecret;
|
|
82
|
+
const problem: string|undefined =
|
|
83
|
+
!isKnown ? "an unknown value"
|
|
84
|
+
: isSecret ? "a secret value"
|
|
85
|
+
: undefined;
|
|
86
|
+
// Ingoring o.resources silently. They are typically non-empty, r.f() calls include r as a dependency.
|
|
87
|
+
if (problem) {
|
|
88
|
+
throw new Error(`Plain resource method "${tok}" incorrectly returned ${problem}. ` +
|
|
89
|
+
"This is an error in the provider, please report this to the provider developer.");
|
|
90
|
+
}
|
|
91
|
+
// Extract a single property if requested.
|
|
92
|
+
if (opts && opts.property) {
|
|
93
|
+
return value[opts.property];
|
|
94
|
+
}
|
|
95
|
+
return value;
|
|
96
|
+
}
|