@sylphx/cli 0.7.2 → 0.7.4
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/CHANGELOG.md +14 -0
- package/dist/main.js +33 -42
- package/dist/main.js.map +1 -1
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @sylphx/cli
|
|
2
2
|
|
|
3
|
+
## 0.7.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`90e15c8`](https://github.com/SylphxAI/platform/commit/90e15c8ae07469666fa6d4ed324f7a7473218004)]:
|
|
8
|
+
- @sylphx/sdk@0.10.6
|
|
9
|
+
|
|
10
|
+
## 0.7.3
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- Updated dependencies [[`28257eb`](https://github.com/SylphxAI/platform/commit/28257ebc815864d4ce1246ca0d9a092eff5b8e52)]:
|
|
15
|
+
- @sylphx/sdk@0.10.5
|
|
16
|
+
|
|
3
17
|
## 0.7.2
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
package/dist/main.js
CHANGED
|
@@ -15,7 +15,7 @@ var init_package = __esm({
|
|
|
15
15
|
"package.json"() {
|
|
16
16
|
package_default = {
|
|
17
17
|
name: "@sylphx/cli",
|
|
18
|
-
version: "0.7.
|
|
18
|
+
version: "0.7.4",
|
|
19
19
|
description: "Sylphx Platform CLI \u2014 deploy and manage your applications from the terminal. 63 commands across deployment, logs, env vars, domains, databases, storage, monitoring, self-service (user), admin (users/quotas/audit/invitations/jwt-keys/project-migrate), and more.",
|
|
20
20
|
type: "module",
|
|
21
21
|
homepage: "https://sylphx.com",
|
|
@@ -71,7 +71,7 @@ var init_package = __esm({
|
|
|
71
71
|
"@effect/cli": "0.75.1",
|
|
72
72
|
"@effect/platform": "0.96.0",
|
|
73
73
|
"@effect/platform-bun": "0.89.0",
|
|
74
|
-
"@sylphx/sdk": "0.10.
|
|
74
|
+
"@sylphx/sdk": "0.10.6",
|
|
75
75
|
chalk: "^5.3.0",
|
|
76
76
|
effect: "3.21.0",
|
|
77
77
|
eventsource: "^2.0.2",
|
|
@@ -5726,7 +5726,7 @@ var init_branch_databases = __esm({
|
|
|
5726
5726
|
params: ProjectEnvPath,
|
|
5727
5727
|
response: DestroyBranchDatabaseResult,
|
|
5728
5728
|
plane: "management",
|
|
5729
|
-
summary: "Schedule branch database teardown
|
|
5729
|
+
summary: "Schedule branch database teardown",
|
|
5730
5730
|
tags: ["branch-databases"]
|
|
5731
5731
|
})
|
|
5732
5732
|
};
|
|
@@ -6055,14 +6055,14 @@ var init_database = __esm({
|
|
|
6055
6055
|
|
|
6056
6056
|
// ../contract/dist/schemas/resources.js
|
|
6057
6057
|
import { Schema as Schema49 } from "effect";
|
|
6058
|
-
var ResourceTier, ResourceType, VolumeStatus,
|
|
6058
|
+
var ResourceTier, ResourceType, VolumeStatus, VolumeSharing, BindingRole, TierBadge, ResourcesOrgSlugParams, ResourcesResourceIdParams, DatabaseResource, CreateDatabaseResourceInput, UpdateDatabaseResourceInput, ListDatabaseResourcesResult, KvResource, CreateKvResourceInput, UpdateKvResourceInput, ListKvResourcesResult, BlobResource, CreateBlobResourceInput, UpdateBlobResourceInput, ListBlobResourcesResult, VolumeResource, CreateVolumeResourceInput, UpdateVolumeResourceInput, ListVolumeResourcesResult, ResourceBinding, CreateResourceBindingInput, ListResourceBindingsResult, SearchResource, SearchResourceWithApiKey, CreateSearchResourceInput, ListSearchResourcesResult, ManagedResource;
|
|
6059
6059
|
var init_resources = __esm({
|
|
6060
6060
|
"../contract/dist/schemas/resources.js"() {
|
|
6061
6061
|
"use strict";
|
|
6062
6062
|
ResourceTier = Schema49.Literal("standard");
|
|
6063
6063
|
ResourceType = Schema49.Literal("database", "kv", "blob", "volume", "search");
|
|
6064
6064
|
VolumeStatus = Schema49.Literal("provisioning", "active", "error");
|
|
6065
|
-
|
|
6065
|
+
VolumeSharing = Schema49.Literal("single-writer", "shared");
|
|
6066
6066
|
BindingRole = Schema49.Literal("primary", "replica", "analytics", "backup", "session");
|
|
6067
6067
|
TierBadge = Schema49.Struct({
|
|
6068
6068
|
tier: ResourceTier,
|
|
@@ -6182,9 +6182,8 @@ var init_resources = __esm({
|
|
|
6182
6182
|
orgId: Schema49.String,
|
|
6183
6183
|
name: Schema49.String,
|
|
6184
6184
|
tier: ResourceTier,
|
|
6185
|
-
|
|
6185
|
+
sharing: VolumeSharing,
|
|
6186
6186
|
/** Plaintext metadata — safe to return */
|
|
6187
|
-
hostPath: Schema49.NullOr(Schema49.String),
|
|
6188
6187
|
mountPath: Schema49.NullOr(Schema49.String),
|
|
6189
6188
|
sizeGb: Schema49.NullOr(Schema49.Number),
|
|
6190
6189
|
status: VolumeStatus,
|
|
@@ -6195,14 +6194,12 @@ var init_resources = __esm({
|
|
|
6195
6194
|
CreateVolumeResourceInput = Schema49.Struct({
|
|
6196
6195
|
name: Schema49.String,
|
|
6197
6196
|
tier: ResourceTier,
|
|
6198
|
-
|
|
6199
|
-
hostPath: Schema49.optional(Schema49.String),
|
|
6197
|
+
sharing: Schema49.optional(VolumeSharing),
|
|
6200
6198
|
mountPath: Schema49.optional(Schema49.String),
|
|
6201
6199
|
sizeGb: Schema49.optional(Schema49.Number)
|
|
6202
6200
|
});
|
|
6203
6201
|
UpdateVolumeResourceInput = Schema49.Struct({
|
|
6204
6202
|
name: Schema49.optional(Schema49.String),
|
|
6205
|
-
hostPath: Schema49.optional(Schema49.String),
|
|
6206
6203
|
mountPath: Schema49.optional(Schema49.String),
|
|
6207
6204
|
sizeGb: Schema49.optional(Schema49.Number)
|
|
6208
6205
|
});
|
|
@@ -6290,8 +6287,7 @@ var init_resources = __esm({
|
|
|
6290
6287
|
region: Schema49.optional(Schema49.NullOr(Schema49.String)),
|
|
6291
6288
|
prefix: Schema49.optional(Schema49.NullOr(Schema49.String)),
|
|
6292
6289
|
publicUrl: Schema49.optional(Schema49.NullOr(Schema49.String)),
|
|
6293
|
-
|
|
6294
|
-
hostPath: Schema49.optional(Schema49.NullOr(Schema49.String)),
|
|
6290
|
+
sharing: Schema49.optional(VolumeSharing),
|
|
6295
6291
|
mountPath: Schema49.optional(Schema49.NullOr(Schema49.String)),
|
|
6296
6292
|
sizeGb: Schema49.optional(Schema49.NullOr(Schema49.Number)),
|
|
6297
6293
|
memoryGb: Schema49.optional(Schema49.Number),
|
|
@@ -6300,7 +6296,6 @@ var init_resources = __esm({
|
|
|
6300
6296
|
message: Schema49.optional(Schema49.String),
|
|
6301
6297
|
provisioningError: Schema49.optional(Schema49.NullOr(Schema49.String)),
|
|
6302
6298
|
conditions: Schema49.optional(Schema49.Array(Schema49.Unknown)),
|
|
6303
|
-
config: Schema49.optional(Schema49.Record({ key: Schema49.String, value: Schema49.Unknown })),
|
|
6304
6299
|
createdAt: Schema49.optional(Schema49.String),
|
|
6305
6300
|
updatedAt: Schema49.optional(Schema49.String)
|
|
6306
6301
|
});
|
|
@@ -6333,7 +6328,7 @@ var init_databases = __esm({
|
|
|
6333
6328
|
region: Schema50.optional(Schema50.NullOr(Schema50.String)),
|
|
6334
6329
|
accessKeyEncrypted: Schema50.optional(Schema50.NullOr(Schema50.String)),
|
|
6335
6330
|
secretKeyEncrypted: Schema50.optional(Schema50.NullOr(Schema50.String)),
|
|
6336
|
-
|
|
6331
|
+
sharing: Schema50.optional(Schema50.Literal("single-writer", "shared")),
|
|
6337
6332
|
sizeGb: Schema50.optional(Schema50.NullOr(Schema50.Number)),
|
|
6338
6333
|
mountPath: Schema50.optional(Schema50.NullOr(Schema50.String)),
|
|
6339
6334
|
config: Schema50.optional(Schema50.Record({ key: Schema50.String, value: Schema50.Unknown }))
|
|
@@ -6861,7 +6856,7 @@ var init_deployments = __esm({
|
|
|
6861
6856
|
method: "GET",
|
|
6862
6857
|
path: "/deployments/status",
|
|
6863
6858
|
response: DeployServiceStatus,
|
|
6864
|
-
summary: "Deploy service readiness
|
|
6859
|
+
summary: "Deploy service readiness",
|
|
6865
6860
|
tags: ["deployments"]
|
|
6866
6861
|
}),
|
|
6867
6862
|
envScopedListAppDeployments: defineEndpoint({
|
|
@@ -10845,10 +10840,11 @@ var init_privacy = __esm({
|
|
|
10845
10840
|
|
|
10846
10841
|
// ../contract/dist/schemas/project-manifest.js
|
|
10847
10842
|
import { Schema as Schema83 } from "effect";
|
|
10848
|
-
var Slug2, ManifestEnvName, ManifestRegion, MachineSize, BuildMachineSize, BuildpackName, BuildStrategy, ServiceType, DeployStrategy, WwwRedirect, ManifestProjectSection, ManifestBuildSection, ManifestDeploySection, ManifestServiceBuildSection, ManifestServiceHealthSection, ManifestServiceSection, ManifestMigrationEngine, ManifestMigrationDestructivePolicy, ManifestMigrationsSection, ManifestDatabaseSection, ManifestEnvValue, ManifestDomainSection, ManifestManagedResourceTier, PostgresTier, PostgresVersion, SearchTier, KvTier, ManifestVolumeTier,
|
|
10843
|
+
var Slug2, ManifestEnvName, ManifestRegion, MachineSize, BuildMachineSize, BuildpackName, BuildStrategy, ServiceType, DeployStrategy, WwwRedirect, ManifestProjectSection, ManifestBuildSection, ManifestDeploySection, ManifestServiceBuildSection, ManifestServiceHealthSection, ManifestServiceSection, ManifestMigrationEngine, ManifestMigrationDestructivePolicy, ManifestMigrationsSection, ManifestDatabaseSection, ManifestEnvValue, ManifestDomainSection, ManifestManagedResourceTier, PostgresTier, PostgresVersion, SearchTier, KvTier, ManifestVolumeTier, ManifestVolumeSharing, ManifestDatabaseEngine, ManifestKvEngine, ManifestSearchEngine, ManifestDatabaseResource, ManifestKvResource, ManifestSearchResource, ManifestVolumeResource, ManifestResourcesSection, ManifestCiSection, ManifestServiceOverride, ManifestEnvironmentOverride, ManifestEnvironmentsMap, SylphxManifest;
|
|
10849
10844
|
var init_project_manifest = __esm({
|
|
10850
10845
|
"../contract/dist/schemas/project-manifest.js"() {
|
|
10851
10846
|
"use strict";
|
|
10847
|
+
init_resources();
|
|
10852
10848
|
Slug2 = Schema83.String.pipe(Schema83.pattern(/^[a-z0-9]([-a-z0-9]*[a-z0-9])?$/), Schema83.minLength(3), Schema83.maxLength(63));
|
|
10853
10849
|
ManifestEnvName = Schema83.Literal("production", "staging", "preview", "development");
|
|
10854
10850
|
ManifestRegion = Schema83.Literal("fsn1", "nbg1", "hel1", "ash1", "hil1");
|
|
@@ -10900,10 +10896,10 @@ var init_project_manifest = __esm({
|
|
|
10900
10896
|
ManifestDeploySection = Schema83.Struct({
|
|
10901
10897
|
/**
|
|
10902
10898
|
* Command run before traffic cutover (DB migrations via expand-and-
|
|
10903
|
-
* contract). Runs
|
|
10899
|
+
* contract). Runs before the new release accepts traffic. ADR-066.2.
|
|
10904
10900
|
*/
|
|
10905
10901
|
release_command: Schema83.optional(Schema83.String),
|
|
10906
|
-
/** HTTP path
|
|
10902
|
+
/** HTTP readiness path. */
|
|
10907
10903
|
health_check_path: Schema83.optional(Schema83.String),
|
|
10908
10904
|
/** Timeout in seconds. */
|
|
10909
10905
|
health_check_timeout: Schema83.optional(Schema83.Number.pipe(Schema83.int(), Schema83.between(1, 300))),
|
|
@@ -10925,7 +10921,7 @@ var init_project_manifest = __esm({
|
|
|
10925
10921
|
command: Schema83.optional(Schema83.String)
|
|
10926
10922
|
});
|
|
10927
10923
|
ManifestServiceSection = Schema83.Struct({
|
|
10928
|
-
/** Service name — unique within project.
|
|
10924
|
+
/** Service name — unique within project. */
|
|
10929
10925
|
name: Slug2,
|
|
10930
10926
|
type: ServiceType,
|
|
10931
10927
|
/** Per-service build override. Root [build] remains the default. */
|
|
@@ -10943,21 +10939,17 @@ var init_project_manifest = __esm({
|
|
|
10943
10939
|
internal_port: Schema83.optional(Schema83.Number.pipe(Schema83.int(), Schema83.between(1, 65535))),
|
|
10944
10940
|
/** Replica count. Ignored for `cron`. */
|
|
10945
10941
|
replicas: Schema83.optional(Schema83.Number.pipe(Schema83.int(), Schema83.between(0, 100))),
|
|
10946
|
-
/** Compute size; maps to per-service
|
|
10942
|
+
/** Compute size; maps to per-service runtime resources. */
|
|
10947
10943
|
instance_type: Schema83.optional(MachineSize),
|
|
10948
10944
|
/** Required when type=cron. Standard 5-field cron expression. */
|
|
10949
10945
|
cron_schedule: Schema83.optional(Schema83.String),
|
|
10950
10946
|
/** Optional per-service region override. */
|
|
10951
10947
|
regions: Schema83.optional(Schema83.Array(ManifestRegion)),
|
|
10952
|
-
/**
|
|
10953
|
-
* Scale-to-zero (KEDA). `false` (default) = pinned at `min_replicas >= 1`;
|
|
10954
|
-
* `true` = the reconciler emits a KEDA ScaledObject and lets KEDA drive
|
|
10955
|
-
* the replica count from 0 → N on incoming traffic (docs/design/scale-to-zero.md).
|
|
10956
|
-
*/
|
|
10948
|
+
/** Scale-to-zero. `false` (default) = pinned at `min_replicas >= 1`. */
|
|
10957
10949
|
scale_to_zero: Schema83.optional(Schema83.Boolean),
|
|
10958
10950
|
/**
|
|
10959
|
-
* Seconds of no traffic before
|
|
10960
|
-
*
|
|
10951
|
+
* Seconds of no traffic before the platform scales the service down to 0.
|
|
10952
|
+
* Only meaningful when `scale_to_zero=true`.
|
|
10961
10953
|
* Range: 60s–3600s. Default: 300 (5 min).
|
|
10962
10954
|
*/
|
|
10963
10955
|
idle_timeout_seconds: Schema83.optional(Schema83.Number.pipe(Schema83.int(), Schema83.between(60, 3600))),
|
|
@@ -11005,7 +10997,7 @@ var init_project_manifest = __esm({
|
|
|
11005
10997
|
SearchTier = ManifestManagedResourceTier;
|
|
11006
10998
|
KvTier = ManifestManagedResourceTier;
|
|
11007
10999
|
ManifestVolumeTier = ManifestManagedResourceTier;
|
|
11008
|
-
|
|
11000
|
+
ManifestVolumeSharing = VolumeSharing;
|
|
11009
11001
|
ManifestDatabaseEngine = Schema83.Literal("postgres");
|
|
11010
11002
|
ManifestKvEngine = Schema83.Literal("valkey");
|
|
11011
11003
|
ManifestSearchEngine = Schema83.Literal("typesense");
|
|
@@ -11038,11 +11030,10 @@ var init_project_manifest = __esm({
|
|
|
11038
11030
|
tier: ManifestVolumeTier,
|
|
11039
11031
|
storage_gb: Schema83.optional(Schema83.Number.pipe(Schema83.int(), Schema83.between(1, 1e4))),
|
|
11040
11032
|
/**
|
|
11041
|
-
*
|
|
11042
|
-
*
|
|
11043
|
-
* disks.
|
|
11033
|
+
* Public sharing intent. The platform maps this to the best backend storage
|
|
11034
|
+
* class without exposing implementation details.
|
|
11044
11035
|
*/
|
|
11045
|
-
|
|
11036
|
+
sharing: Schema83.optional(ManifestVolumeSharing),
|
|
11046
11037
|
/**
|
|
11047
11038
|
* Optional env-facing path metadata. This does not mount the volume into an
|
|
11048
11039
|
* app service by itself; service/task mounts stay explicit bindings.
|
|
@@ -34132,12 +34123,12 @@ function volumesCreateEffect(input) {
|
|
|
34132
34123
|
})
|
|
34133
34124
|
);
|
|
34134
34125
|
}
|
|
34135
|
-
if (!["
|
|
34126
|
+
if (!["single-writer", "shared"].includes(input.sharing)) {
|
|
34136
34127
|
return yield* Effect73.fail(
|
|
34137
34128
|
new CliArgError({
|
|
34138
34129
|
command: "volumes",
|
|
34139
|
-
argument: "--
|
|
34140
|
-
message: "--
|
|
34130
|
+
argument: "--sharing",
|
|
34131
|
+
message: "--sharing must be single-writer or shared"
|
|
34141
34132
|
})
|
|
34142
34133
|
);
|
|
34143
34134
|
}
|
|
@@ -34149,7 +34140,7 @@ function volumesCreateEffect(input) {
|
|
|
34149
34140
|
api2.createVolume(projectId, {
|
|
34150
34141
|
name: input.name,
|
|
34151
34142
|
sizeGb,
|
|
34152
|
-
|
|
34143
|
+
sharing: input.sharing,
|
|
34153
34144
|
mountPath: input.mount
|
|
34154
34145
|
})
|
|
34155
34146
|
);
|
|
@@ -34158,7 +34149,7 @@ function volumesCreateEffect(input) {
|
|
|
34158
34149
|
yield* Console63.log("");
|
|
34159
34150
|
yield* Console63.log(` ${chalk_default.dim("ID:")} ${vol.id}`);
|
|
34160
34151
|
yield* Console63.log(` ${chalk_default.dim("Size:")} ${vol.sizeGb}Gi`);
|
|
34161
|
-
yield* Console63.log(` ${chalk_default.dim("
|
|
34152
|
+
yield* Console63.log(` ${chalk_default.dim("Sharing:")} ${vol.sharing ?? "single-writer"}`);
|
|
34162
34153
|
yield* Console63.log("");
|
|
34163
34154
|
});
|
|
34164
34155
|
}
|
|
@@ -34208,9 +34199,9 @@ var createCmd14 = Command63.make(
|
|
|
34208
34199
|
Options63.withDescription("Size in GiB (default: 10)"),
|
|
34209
34200
|
Options63.withDefault("10")
|
|
34210
34201
|
),
|
|
34211
|
-
|
|
34212
|
-
Options63.withDescription("
|
|
34213
|
-
Options63.withDefault("
|
|
34202
|
+
sharing: Options63.text("sharing").pipe(
|
|
34203
|
+
Options63.withDescription("single-writer or shared (default: single-writer)"),
|
|
34204
|
+
Options63.withDefault("single-writer")
|
|
34214
34205
|
),
|
|
34215
34206
|
mount: Options63.text("mount").pipe(
|
|
34216
34207
|
Options63.withDescription("Default mount path (optional)"),
|
|
@@ -34219,10 +34210,10 @@ var createCmd14 = Command63.make(
|
|
|
34219
34210
|
project: projectOption37,
|
|
34220
34211
|
org: orgOption25
|
|
34221
34212
|
},
|
|
34222
|
-
({ name, size,
|
|
34213
|
+
({ name, size, sharing, mount, project, org }) => volumesCreateEffect({
|
|
34223
34214
|
name,
|
|
34224
34215
|
size,
|
|
34225
|
-
|
|
34216
|
+
sharing,
|
|
34226
34217
|
mount: mount._tag === "Some" ? mount.value : void 0,
|
|
34227
34218
|
project: project._tag === "Some" ? project.value : void 0,
|
|
34228
34219
|
org: org._tag === "Some" ? org.value : void 0
|