@astrale-domains/services 0.4.9 → 0.5.1
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/README.md +153 -816
- package/dist/schema/index.d.ts +4 -5
- package/dist/schema/index.js +2 -3
- package/dist/schema/modules/deployment/classes/cloudflare-deployment.d.ts +4 -321
- package/dist/schema/modules/deployment/classes/cloudflare-deployment.js +1 -19
- package/dist/schema/modules/deployment/classes/current-deployment.d.ts +20 -0
- package/dist/schema/modules/deployment/classes/current-deployment.js +13 -0
- package/dist/schema/modules/deployment/classes/{deployment-on-line.d.ts → deployment-of.d.ts} +3 -3
- package/dist/schema/modules/deployment/classes/deployment-of.js +11 -0
- package/dist/schema/modules/deployment/classes/deployment.d.ts +9 -57
- package/dist/schema/modules/deployment/classes/deployment.js +9 -23
- package/dist/schema/modules/deployment/classes/index.d.ts +2 -3
- package/dist/schema/modules/deployment/classes/index.js +2 -3
- package/dist/schema/modules/deployment/errors/deployment-not-found.d.ts +2 -5
- package/dist/schema/modules/deployment/errors/deployment-not-found.js +2 -5
- package/dist/schema/modules/deployment/errors/index.d.ts +0 -2
- package/dist/schema/modules/deployment/errors/index.js +0 -2
- package/dist/schema/modules/deployment/functions/index.d.ts +0 -10
- package/dist/schema/modules/deployment/functions/index.js +0 -10
- package/dist/schema/modules/deployment/functions/retire-deployment.d.ts +8 -7
- package/dist/schema/modules/deployment/functions/retire-deployment.js +8 -7
- package/dist/schema/modules/deployment/index.d.ts +6 -6
- package/dist/schema/modules/deployment/index.js +7 -5
- package/dist/schema/modules/deployment/policies/index.d.ts +1 -4
- package/dist/schema/modules/deployment/policies/index.js +1 -4
- package/dist/schema/modules/deployment/policies/own-deployment.d.ts +1 -1
- package/dist/schema/modules/deployment/policies/own-deployment.js +6 -7
- package/dist/schema/modules/deployment/policies/traverse-owned-service-deployment.d.ts +2 -0
- package/dist/schema/modules/deployment/policies/traverse-owned-service-deployment.js +7 -0
- package/dist/schema/modules/deployment/states/deployment-lifecycle.d.ts +6 -9
- package/dist/schema/modules/deployment/states/deployment-lifecycle.js +6 -7
- package/dist/schema/modules/deployment/types/deployment-hosting.d.ts +9 -28
- package/dist/schema/modules/deployment/types/deployment-hosting.js +3 -3
- package/dist/schema/modules/deployment/types/deployment-request.d.ts +12 -40
- package/dist/schema/modules/deployment/types/deployment-request.js +17 -9
- package/dist/schema/modules/deployment/types/deployment-response.d.ts +7 -15
- package/dist/schema/modules/deployment/types/deployment-response.js +2 -2
- package/dist/schema/modules/deployment/types/deployment-retire.d.ts +1 -1
- package/dist/schema/modules/deployment/types/deployment-secret.d.ts +0 -39
- package/dist/schema/modules/deployment/types/deployment-secret.js +0 -34
- package/dist/schema/modules/deployment/types/deployment-summary.d.ts +14 -45
- package/dist/schema/modules/deployment/types/deployment-summary.js +9 -8
- package/dist/schema/modules/deployment/types/index.d.ts +7 -3
- package/dist/schema/modules/deployment/types/index.js +4 -2
- package/dist/schema/modules/{service → deployment}/types/service-deployment-artifact-module.d.ts +2 -20
- package/dist/schema/modules/deployment/types/service-deployment-artifact-module.js +10 -0
- package/dist/schema/modules/{service → deployment}/types/service-deployment-assets.d.ts +4 -20
- package/dist/schema/modules/{service → deployment}/types/service-deployment-assets.js +4 -7
- package/dist/schema/modules/service/classes/cloudflare-service.d.ts +321 -0
- package/dist/schema/modules/service/classes/cloudflare-service.js +35 -0
- package/dist/schema/modules/service/classes/index.d.ts +1 -1
- package/dist/schema/modules/service/classes/index.js +1 -1
- package/dist/schema/modules/service/classes/service.d.ts +18 -107
- package/dist/schema/modules/service/classes/service.js +16 -27
- package/dist/schema/modules/service/errors/index.d.ts +1 -0
- package/dist/schema/modules/service/errors/index.js +1 -0
- package/dist/schema/modules/service/errors/service-not-found.d.ts +7 -0
- package/dist/schema/modules/service/errors/service-not-found.js +8 -0
- package/dist/schema/modules/service/functions/delete-service.d.ts +1 -1
- package/dist/schema/modules/service/functions/delete-service.js +1 -1
- package/dist/schema/modules/{deployment/functions/deploy-cloudflare-deployment.d.ts → service/functions/deploy-service.d.ts} +20 -35
- package/dist/schema/modules/service/functions/deploy-service.js +15 -0
- package/dist/schema/modules/service/functions/describe-hosting.d.ts +8 -0
- package/dist/schema/modules/service/functions/describe-hosting.js +11 -0
- package/dist/schema/modules/service/functions/index.d.ts +5 -10
- package/dist/schema/modules/service/functions/index.js +5 -10
- package/dist/schema/modules/{deployment/functions/list-cloudflare-deployments.d.ts → service/functions/list-service-deployments.d.ts} +8 -12
- package/dist/schema/modules/service/functions/list-service-deployments.js +10 -0
- package/dist/schema/modules/service/functions/list-service-logs.d.ts +2 -1
- package/dist/schema/modules/service/functions/list-service-logs.js +1 -1
- package/dist/schema/modules/service/functions/list-service-schedules.d.ts +1 -1
- package/dist/schema/modules/service/functions/list-service-schedules.js +1 -1
- package/dist/schema/modules/service/functions/list-service-secret-names.d.ts +1 -1
- package/dist/schema/modules/service/functions/list-service-secret-names.js +1 -1
- package/dist/schema/modules/service/functions/promote-service.d.ts +14 -0
- package/dist/schema/modules/service/functions/promote-service.js +4 -0
- package/dist/schema/modules/service/functions/replace-service-schedules.d.ts +1 -1
- package/dist/schema/modules/service/functions/replace-service-schedules.js +1 -4
- package/dist/schema/modules/service/functions/set-service-secret.d.ts +4 -2
- package/dist/schema/modules/service/functions/set-service-secret.js +1 -1
- package/dist/schema/modules/service/functions/transfer-service.d.ts +14 -0
- package/dist/schema/modules/service/functions/transfer-service.js +4 -0
- package/dist/schema/modules/service/index.d.ts +5 -5
- package/dist/schema/modules/service/index.js +5 -4
- package/dist/schema/modules/service/policies/act-as.d.ts +6 -0
- package/dist/schema/modules/service/policies/act-as.js +10 -0
- package/dist/schema/modules/service/policies/index.d.ts +1 -0
- package/dist/schema/modules/service/policies/index.js +1 -0
- package/dist/schema/modules/service/states/service-lifecycle.d.ts +7 -20
- package/dist/schema/modules/service/states/service-lifecycle.js +6 -21
- package/dist/schema/modules/service/types/index.d.ts +1 -13
- package/dist/schema/modules/service/types/index.js +1 -8
- package/dist/schema/modules/service/types/service-management.d.ts +65 -24
- package/dist/schema/modules/service/types/service-management.js +46 -21
- package/dist/schema/schema.d.ts +252 -758
- package/dist/schema/schema.js +7 -11
- package/package.json +2 -9
- package/dist/scaffold/create-service.mjs +0 -77
- package/dist/scaffold/template/.env.example +0 -2
- package/dist/scaffold/template/README.md +0 -37
- package/dist/scaffold/template/gitignore +0 -6
- package/dist/scaffold/template/scripts/build.mjs +0 -10
- package/dist/scaffold/template/scripts/deploy.mjs +0 -50
- package/dist/scaffold/template/src/account.js +0 -26
- package/dist/scaffold/template/src/index.js +0 -32
- package/dist/scaffold/template/src/job.js +0 -19
- package/dist/schema/modules/deployment/classes/deployment-line.d.ts +0 -23
- package/dist/schema/modules/deployment/classes/deployment-line.js +0 -24
- package/dist/schema/modules/deployment/classes/deployment-on-line.js +0 -11
- package/dist/schema/modules/deployment/classes/line-owned-by.d.ts +0 -26
- package/dist/schema/modules/deployment/classes/line-owned-by.js +0 -19
- package/dist/schema/modules/deployment/errors/deployment-label-not-found.d.ts +0 -12
- package/dist/schema/modules/deployment/errors/deployment-label-not-found.js +0 -11
- package/dist/schema/modules/deployment/errors/deployment-registry-only.d.ts +0 -11
- package/dist/schema/modules/deployment/errors/deployment-registry-only.js +0 -12
- package/dist/schema/modules/deployment/functions/deploy-cloudflare-deployment.js +0 -14
- package/dist/schema/modules/deployment/functions/describe-deployment-hosting.d.ts +0 -8
- package/dist/schema/modules/deployment/functions/describe-deployment-hosting.js +0 -11
- package/dist/schema/modules/deployment/functions/expire-deployment-previews.d.ts +0 -16
- package/dist/schema/modules/deployment/functions/expire-deployment-previews.js +0 -14
- package/dist/schema/modules/deployment/functions/list-cloudflare-deployment-secret-names.d.ts +0 -5
- package/dist/schema/modules/deployment/functions/list-cloudflare-deployment-secret-names.js +0 -4
- package/dist/schema/modules/deployment/functions/list-cloudflare-deployments.js +0 -10
- package/dist/schema/modules/deployment/functions/list-deployment-secret-names.d.ts +0 -4
- package/dist/schema/modules/deployment/functions/list-deployment-secret-names.js +0 -6
- package/dist/schema/modules/deployment/functions/read-deployment-last-calls.d.ts +0 -10
- package/dist/schema/modules/deployment/functions/read-deployment-last-calls.js +0 -13
- package/dist/schema/modules/deployment/functions/retain-deployment.d.ts +0 -12
- package/dist/schema/modules/deployment/functions/retain-deployment.js +0 -13
- package/dist/schema/modules/deployment/functions/set-cloudflare-deployment-secret.d.ts +0 -18
- package/dist/schema/modules/deployment/functions/set-cloudflare-deployment-secret.js +0 -7
- package/dist/schema/modules/deployment/functions/set-deployment-secret.d.ts +0 -14
- package/dist/schema/modules/deployment/functions/set-deployment-secret.js +0 -3
- package/dist/schema/modules/deployment/policies/act-for-organization.d.ts +0 -6
- package/dist/schema/modules/deployment/policies/act-for-organization.js +0 -10
- package/dist/schema/modules/deployment/policies/own-line.d.ts +0 -5
- package/dist/schema/modules/deployment/policies/own-line.js +0 -10
- package/dist/schema/modules/deployment/policies/traverse-owned-line-deployment.d.ts +0 -2
- package/dist/schema/modules/deployment/policies/traverse-owned-line-deployment.js +0 -7
- package/dist/schema/modules/deployment/policies/traverse-owned-line.d.ts +0 -2
- package/dist/schema/modules/deployment/policies/traverse-owned-line.js +0 -7
- package/dist/schema/modules/deployment/types/deployment-retention.d.ts +0 -49
- package/dist/schema/modules/deployment/types/deployment-retention.js +0 -45
- package/dist/schema/modules/service/classes/cloudflare-worker.d.ts +0 -352
- package/dist/schema/modules/service/classes/cloudflare-worker.js +0 -41
- package/dist/schema/modules/service/functions/delete-service-secret.d.ts +0 -11
- package/dist/schema/modules/service/functions/delete-service-secret.js +0 -3
- package/dist/schema/modules/service/functions/delete-worker-secret.d.ts +0 -11
- package/dist/schema/modules/service/functions/delete-worker-secret.js +0 -7
- package/dist/schema/modules/service/functions/delete-worker.d.ts +0 -9
- package/dist/schema/modules/service/functions/delete-worker.js +0 -7
- package/dist/schema/modules/service/functions/deploy-cloudflare-worker.d.ts +0 -109
- package/dist/schema/modules/service/functions/deploy-cloudflare-worker.js +0 -9
- package/dist/schema/modules/service/functions/list-worker-logs.d.ts +0 -12
- package/dist/schema/modules/service/functions/list-worker-logs.js +0 -7
- package/dist/schema/modules/service/functions/list-worker-schedules.d.ts +0 -4
- package/dist/schema/modules/service/functions/list-worker-schedules.js +0 -7
- package/dist/schema/modules/service/functions/list-worker-secret-names.d.ts +0 -4
- package/dist/schema/modules/service/functions/list-worker-secret-names.js +0 -7
- package/dist/schema/modules/service/functions/migrate-worker-ingress.d.ts +0 -24
- package/dist/schema/modules/service/functions/migrate-worker-ingress.js +0 -26
- package/dist/schema/modules/service/functions/replace-worker-schedules.d.ts +0 -11
- package/dist/schema/modules/service/functions/replace-worker-schedules.js +0 -7
- package/dist/schema/modules/service/functions/set-worker-secret.d.ts +0 -12
- package/dist/schema/modules/service/functions/set-worker-secret.js +0 -7
- package/dist/schema/modules/service/types/deploy-cloudflare-worker.d.ts +0 -286
- package/dist/schema/modules/service/types/deploy-cloudflare-worker.js +0 -51
- package/dist/schema/modules/service/types/legacy/service-deployment-content.js +0 -22
- package/dist/schema/modules/service/types/service-deployment-artifact-module.js +0 -13
- package/dist/schema/modules/service/types/service-deployment-resource-limits.d.ts +0 -6
- package/dist/schema/modules/service/types/service-deployment-resource-limits.js +0 -7
- package/dist/schema/modules/service/types/service-readiness.d.ts +0 -6
- package/dist/schema/modules/service/types/service-readiness.js +0 -6
- package/dist/schema/modules/service/types/service-secret-operation-rejection.d.ts +0 -9
- package/dist/schema/modules/service/types/service-secret-operation-rejection.js +0 -5
- /package/dist/schema/modules/{service → deployment}/types/content/index.d.ts +0 -0
- /package/dist/schema/modules/{service → deployment}/types/content/index.js +0 -0
- /package/dist/schema/modules/{service → deployment}/types/content/limits.d.ts +0 -0
- /package/dist/schema/modules/{service → deployment}/types/content/limits.js +0 -0
- /package/dist/schema/modules/{service → deployment}/types/service-deployment-content.d.ts +0 -0
- /package/dist/schema/modules/{service → deployment}/types/service-deployment-content.js +0 -0
package/dist/schema/schema.js
CHANGED
|
@@ -1,29 +1,25 @@
|
|
|
1
1
|
import { KernelSchema, defineSchema, view } from '@astrale-os/sdk/schema';
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import { CloudflareDeployment, Deployment, OwnDeployment, TraverseOwnedServiceDeployment, current_deployment, deployment_of, } from './modules/deployment/index.js';
|
|
3
|
+
import { ActAs, CloudflareService, OwnService, Service, TraverseOwnedService, service_owned_by, } from './modules/service/index.js';
|
|
4
4
|
const origin = 'services.astrale.ai';
|
|
5
5
|
const classes = {
|
|
6
6
|
Service,
|
|
7
|
-
|
|
7
|
+
CloudflareService,
|
|
8
8
|
service_owned_by,
|
|
9
|
-
DeploymentLine,
|
|
10
9
|
Deployment,
|
|
11
10
|
CloudflareDeployment,
|
|
12
|
-
|
|
13
|
-
|
|
11
|
+
deployment_of,
|
|
12
|
+
current_deployment,
|
|
14
13
|
};
|
|
15
14
|
const policies = {
|
|
16
15
|
OwnService,
|
|
17
16
|
TraverseOwnedService,
|
|
18
|
-
|
|
17
|
+
ActAs,
|
|
19
18
|
OwnDeployment,
|
|
20
|
-
|
|
21
|
-
TraverseOwnedLine,
|
|
22
|
-
TraverseOwnedLineDeployment,
|
|
19
|
+
TraverseOwnedServiceDeployment,
|
|
23
20
|
};
|
|
24
21
|
const views = {
|
|
25
22
|
application: view({}),
|
|
26
|
-
service: view({ target: CloudflareWorker }),
|
|
27
23
|
};
|
|
28
24
|
export const schema = defineSchema(origin, {
|
|
29
25
|
dependencies: { kernel: KernelSchema },
|
package/package.json
CHANGED
|
@@ -1,14 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@astrale-domains/services",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.1",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/astrale-os/domains.git",
|
|
7
7
|
"directory": "services"
|
|
8
8
|
},
|
|
9
|
-
"bin": {
|
|
10
|
-
"create-astrale-service": "./dist/scaffold/create-service.mjs"
|
|
11
|
-
},
|
|
12
9
|
"files": [
|
|
13
10
|
"dist"
|
|
14
11
|
],
|
|
@@ -75,23 +72,19 @@
|
|
|
75
72
|
"build": "astrale-domain build",
|
|
76
73
|
"lint": "astrale-domain lint",
|
|
77
74
|
"lint:fix": "astrale-domain lint --fix",
|
|
78
|
-
"package": "astrale-domain package
|
|
75
|
+
"package": "astrale-domain package",
|
|
79
76
|
"provider:bootstrap": "bun providers/cloudflare/operator/provision/bootstrap.ts",
|
|
80
77
|
"provider:deployment-audit": "bun providers/cloudflare/operator/maintenance/deployment-audit.ts",
|
|
81
78
|
"provider:doctor": "bun providers/cloudflare/operator/maintenance/doctor.ts",
|
|
82
|
-
"provider:orphan-audit": "bun providers/cloudflare/operator/maintenance/orphan-audit.ts",
|
|
83
79
|
"provider:platform-bootstrap": "bun providers/cloudflare/operator/platform-namespace/bootstrap.ts",
|
|
84
80
|
"provider:platform-expiry": "bun scripts/platform-namespace/expiry.ts",
|
|
85
81
|
"provider:platform-retire": "bun scripts/platform-namespace/retire.ts",
|
|
86
82
|
"provider:platform-secret": "bun providers/cloudflare/operator/platform-namespace/secret.ts",
|
|
87
|
-
"provider:reclaim-service": "bun providers/cloudflare/operator/maintenance/reclaim-service.ts",
|
|
88
83
|
"provider:route-wildcard": "bun providers/cloudflare/operator/routing/wildcard.ts",
|
|
89
|
-
"provider:route-tenant": "bun providers/cloudflare/operator/routing/tenant.ts",
|
|
90
84
|
"typecheck": "tsc --noEmit && tsc --project providers/cloudflare/operator/dispatch/tsconfig.json",
|
|
91
85
|
"test": "vitest run --config vitest.config.ts && pnpm run accessibility:check",
|
|
92
86
|
"accessibility:check": "oxlint ui views frontend/src --jsx-a11y-plugin --react-plugin --deny-warnings",
|
|
93
87
|
"frontend:build": "vite build",
|
|
94
|
-
"test:remote": "node --test tests/remote/*.test.mjs",
|
|
95
88
|
"test:kernel": "vitest run --config vitest.config.ts tests/kernel"
|
|
96
89
|
}
|
|
97
90
|
}
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
import { cp, mkdir, readFile, readdir, rename, writeFile } from 'node:fs/promises'
|
|
3
|
-
import { basename, resolve } from 'node:path'
|
|
4
|
-
|
|
5
|
-
const [directory, ...extra] = process.argv.slice(2)
|
|
6
|
-
if (directory === '--help' || directory === '-h') {
|
|
7
|
-
console.log(
|
|
8
|
-
'Usage: create-astrale-service <new-directory>\nCreates local source only. Does not install dependencies, register identities or deploy.',
|
|
9
|
-
)
|
|
10
|
-
} else {
|
|
11
|
-
try {
|
|
12
|
-
if (!directory || directory.startsWith('-') || extra.length) {
|
|
13
|
-
throw new Error('Usage: create-astrale-service <new-directory>')
|
|
14
|
-
}
|
|
15
|
-
const destination = resolve(directory)
|
|
16
|
-
const name = basename(destination)
|
|
17
|
-
if (!/^[a-z][a-z0-9-]{0,62}$/.test(name)) {
|
|
18
|
-
throw new Error(
|
|
19
|
-
'Use a lowercase project name beginning with a letter (maximum 63 characters).',
|
|
20
|
-
)
|
|
21
|
-
}
|
|
22
|
-
const owner = JSON.parse(await readFile(new URL('../../package.json', import.meta.url), 'utf8'))
|
|
23
|
-
// Exclusive creation preserves existing projects and refuses symlink targets.
|
|
24
|
-
await mkdir(destination)
|
|
25
|
-
const template = new URL('./template/', import.meta.url)
|
|
26
|
-
for (const entry of await readdir(template)) {
|
|
27
|
-
await cp(new URL(entry, template), resolve(destination, entry), {
|
|
28
|
-
recursive: true,
|
|
29
|
-
force: false,
|
|
30
|
-
errorOnExist: true,
|
|
31
|
-
})
|
|
32
|
-
}
|
|
33
|
-
await rename(resolve(destination, 'gitignore'), resolve(destination, '.gitignore'))
|
|
34
|
-
await writeFile(
|
|
35
|
-
resolve(destination, 'package.json'),
|
|
36
|
-
JSON.stringify(
|
|
37
|
-
{
|
|
38
|
-
name,
|
|
39
|
-
version: '0.0.0',
|
|
40
|
-
private: true,
|
|
41
|
-
type: 'module',
|
|
42
|
-
scripts: { build: 'node scripts/build.mjs', deploy: 'node scripts/deploy.mjs' },
|
|
43
|
-
dependencies: {
|
|
44
|
-
'@astrale-os/sdk': owner.dependencies['@astrale-os/sdk'],
|
|
45
|
-
zod: owner.dependencies.zod,
|
|
46
|
-
jose: '6.2.3',
|
|
47
|
-
},
|
|
48
|
-
devDependencies: { esbuild: '0.28.2' },
|
|
49
|
-
engines: { node: '>=22.13' },
|
|
50
|
-
},
|
|
51
|
-
null,
|
|
52
|
-
2,
|
|
53
|
-
) + '\n',
|
|
54
|
-
{ flag: 'wx' },
|
|
55
|
-
)
|
|
56
|
-
await writeFile(
|
|
57
|
-
resolve(destination, 'service.json'),
|
|
58
|
-
JSON.stringify(
|
|
59
|
-
{
|
|
60
|
-
serviceKey: name,
|
|
61
|
-
vars: { KERNEL: '', TARGET: '' },
|
|
62
|
-
},
|
|
63
|
-
null,
|
|
64
|
-
2,
|
|
65
|
-
) + '\n',
|
|
66
|
-
{ flag: 'wx' },
|
|
67
|
-
)
|
|
68
|
-
console.log(
|
|
69
|
-
`Created ${destination}\nInstall dependencies, edit service.json and src/job.js, then run npm run deploy -- --instance <instance> --as <identity>.`,
|
|
70
|
-
)
|
|
71
|
-
} catch (error) {
|
|
72
|
-
console.error(
|
|
73
|
-
error.code === 'EEXIST' ? 'Destination already exists; no files overwritten.' : error.message,
|
|
74
|
-
)
|
|
75
|
-
process.exitCode = 1
|
|
76
|
-
}
|
|
77
|
-
}
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
# Background Service
|
|
2
|
-
|
|
3
|
-
This is plain compute, not a Domain. It does not publish or install an Application.
|
|
4
|
-
|
|
5
|
-
1. Install dependencies with `npm install` (Node22.13+), and install the Astrale CLI separately.
|
|
6
|
-
2. Edit `service.json`: KERNEL is the exact Kernel issuer (including /api when present); TARGET is
|
|
7
|
-
the canonical callable Path. Edit `src/job.js` to match that callable's input and business intent.
|
|
8
|
-
3. Create a dedicated Identity in its business Domain, register its ES256 key on the same Node,
|
|
9
|
-
and grant only the required callable authority and business permissions. Use Shell.Group.assignMember
|
|
10
|
-
for supported custom groups; do not use Root or admin credentials in this Worker.
|
|
11
|
-
4. Run `npm run deploy -- --instance <instance> --as <owner>`. It builds first and calls Services.
|
|
12
|
-
The returned Service ID belongs to compute; it is not the registered Identity Node ID.
|
|
13
|
-
5. Use `CloudflareWorker.setSecret` on that Service ID to bind ACCOUNT_PRIVATE_JWK. Send its value
|
|
14
|
-
through stdin, not shell arguments or service.json. `.env.example` only names the secret.
|
|
15
|
-
6. Verify the account's real call, then enable the cron through `CloudflareWorker.setSchedule`.
|
|
16
|
-
|
|
17
|
-
```sh
|
|
18
|
-
astrale call @SERVICE_ID::services.astrale.ai:class.CloudflareWorker.method.setSchedule \
|
|
19
|
-
--data '{"crons":["* * * * *"]}' -i INSTANCE --as OWNER --json
|
|
20
|
-
astrale call @SERVICE_ID::services.astrale.ai:class.CloudflareWorker.method.logs \
|
|
21
|
-
tail=20 -i INSTANCE --as OWNER --json
|
|
22
|
-
```
|
|
23
|
-
|
|
24
|
-
The cron is a private Services-dispatched POST to /__scheduled, not a native Cloudflare scheduled
|
|
25
|
-
export. The public dispatcher rejects that path; headers alone are not authentication. The job
|
|
26
|
-
awaits the remote result before success and uses a 9s call budget under the current 10s dispatcher
|
|
27
|
-
deadline. Health indicates compute is reachable, not that the account is registered or authorized.
|
|
28
|
-
No exactly-once guarantee: design repeated or uncertain calls in the business Domain.
|
|
29
|
-
|
|
30
|
-
Deployment uses the Services provider's default public-fetch routing. It requires the Services
|
|
31
|
-
Runtime containing Domains PR210; publishing a schema package alone does not deploy that fix.
|
|
32
|
-
Explicit compatibilityFlags in service.json replace defaults completely. Configuration changes
|
|
33
|
-
require redeployment; no automatic fallback or provider-specific transport is embedded here.
|
|
34
|
-
|
|
35
|
-
To stop, set crons to [] and observe convergence. Delete the Service through its public delete
|
|
36
|
-
method, resuming a deleting result at retryAfterMs if necessary. Account/group/data retirement is
|
|
37
|
-
a separate business operation. Never delete shared groups or uninstall another Domain implicitly.
|
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import { spawn } from 'node:child_process'
|
|
2
|
-
import { readFile } from 'node:fs/promises'
|
|
3
|
-
|
|
4
|
-
const args = process.argv.slice(2)
|
|
5
|
-
if (args[0] === '--') args.shift()
|
|
6
|
-
if (!args.some((arg) => arg === '-i' || /^(--instance|--url)(=|$)/.test(arg))) {
|
|
7
|
-
throw new Error(
|
|
8
|
-
'Select a Services instance explicitly: npm run deploy -- --instance <instance> --as <identity>',
|
|
9
|
-
)
|
|
10
|
-
}
|
|
11
|
-
const configuration = JSON.parse(await readFile('service.json', 'utf8'))
|
|
12
|
-
await import('./build.mjs')
|
|
13
|
-
const content = (await readFile('.dist/worker.mjs')).toString('base64')
|
|
14
|
-
const request = {
|
|
15
|
-
...configuration,
|
|
16
|
-
entry: 'index.mjs',
|
|
17
|
-
modules: [{ name: 'index.mjs', kind: 'esm', contentBase64Chunks: content.match(/.{1,524288}/g) }],
|
|
18
|
-
}
|
|
19
|
-
const child = spawn(
|
|
20
|
-
'astrale',
|
|
21
|
-
['call', '/:services.astrale.ai:class.CloudflareWorker:deploy', ...args, '--json'],
|
|
22
|
-
{
|
|
23
|
-
stdio: ['pipe', 'pipe', 'inherit'],
|
|
24
|
-
},
|
|
25
|
-
)
|
|
26
|
-
let output = ''
|
|
27
|
-
child.stdout.on('data', (chunk) => {
|
|
28
|
-
output += chunk
|
|
29
|
-
})
|
|
30
|
-
child.on('error', () => {
|
|
31
|
-
console.error('Could not start the Astrale CLI. Install @astrale-os/cli first.')
|
|
32
|
-
process.exitCode = 1
|
|
33
|
-
})
|
|
34
|
-
child.on('close', (code) => {
|
|
35
|
-
process.stdout.write(output)
|
|
36
|
-
if (code !== 0) {
|
|
37
|
-
process.exitCode = 1
|
|
38
|
-
return
|
|
39
|
-
}
|
|
40
|
-
try {
|
|
41
|
-
const result = JSON.parse(output)
|
|
42
|
-
if (result.state !== 'ready') process.exitCode = 1
|
|
43
|
-
} catch {
|
|
44
|
-
process.exitCode = 1
|
|
45
|
-
}
|
|
46
|
-
})
|
|
47
|
-
child.stdin.on('error', () => {
|
|
48
|
-
process.exitCode = 1
|
|
49
|
-
})
|
|
50
|
-
child.stdin.end(JSON.stringify(request))
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { issuer, jwk, register } from '@astrale-os/sdk/auth'
|
|
2
|
-
import { connect } from '@astrale-os/sdk/client/session'
|
|
3
|
-
import { importJWK, SignJWT } from 'jose'
|
|
4
|
-
|
|
5
|
-
export function openAccount(kernel, privateJwk) {
|
|
6
|
-
if (privateJwk.kty !== 'EC' || privateJwk.crv !== 'P-256' || !privateJwk.d) {
|
|
7
|
-
throw new TypeError('Expected a registered ES256 private JWK')
|
|
8
|
-
}
|
|
9
|
-
const publicKey = jwk.acceptPublic({ kty: 'EC', crv: 'P-256', x: privateJwk.x, y: privateJwk.y })
|
|
10
|
-
return connect({
|
|
11
|
-
url: kernel,
|
|
12
|
-
auth: {
|
|
13
|
-
ttlSeconds: 60,
|
|
14
|
-
resolve: async () => ({
|
|
15
|
-
credential: await new SignJWT({})
|
|
16
|
-
.setProtectedHeader({ alg: 'ES256', kid: privateJwk.kid, typ: 'JWT' })
|
|
17
|
-
.setIssuer(await register.selfIssuer(issuer.accept(kernel), publicKey))
|
|
18
|
-
.setSubject('self')
|
|
19
|
-
.setAudience(kernel)
|
|
20
|
-
.setIssuedAt()
|
|
21
|
-
.setExpirationTime('3m')
|
|
22
|
-
.sign(await importJWK(privateJwk, 'ES256')),
|
|
23
|
-
}),
|
|
24
|
-
},
|
|
25
|
-
})
|
|
26
|
-
}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { runJob } from './job.js'
|
|
2
|
-
|
|
3
|
-
export default {
|
|
4
|
-
async fetch(request, env) {
|
|
5
|
-
const path = new URL(request.url).pathname
|
|
6
|
-
if (path === '/health' && request.method === 'GET') return Response.json({ status: 'ok' })
|
|
7
|
-
if (path !== '/__scheduled' || request.method !== 'POST')
|
|
8
|
-
return new Response(null, { status: 404 })
|
|
9
|
-
// Services invokes this through private dispatch and blocks the public path.
|
|
10
|
-
const scheduledAt = Number(request.headers.get('x-astrale-scheduled-time'))
|
|
11
|
-
if (!Number.isSafeInteger(scheduledAt) || scheduledAt <= 0)
|
|
12
|
-
return new Response(null, { status: 400 })
|
|
13
|
-
const started = Date.now()
|
|
14
|
-
try {
|
|
15
|
-
await runJob({ scheduledAt, env, signal: AbortSignal.timeout(9000) })
|
|
16
|
-
console.log(
|
|
17
|
-
JSON.stringify({ event: 'job.completed', scheduledAt, elapsedMs: Date.now() - started }),
|
|
18
|
-
)
|
|
19
|
-
return Response.json({ status: 'completed' })
|
|
20
|
-
} catch (error) {
|
|
21
|
-
// Do not log credentials, provider envelopes or business result values.
|
|
22
|
-
console.error(
|
|
23
|
-
JSON.stringify({
|
|
24
|
-
event: 'job.failed',
|
|
25
|
-
scheduledAt,
|
|
26
|
-
code: typeof error?.code === 'number' ? error.code : undefined,
|
|
27
|
-
}),
|
|
28
|
-
)
|
|
29
|
-
return Response.json({ status: 'failed' }, { status: 503 })
|
|
30
|
-
}
|
|
31
|
-
},
|
|
32
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { Path } from '@astrale-os/sdk/graph/path'
|
|
2
|
-
|
|
3
|
-
import { openAccount } from './account.js'
|
|
4
|
-
|
|
5
|
-
// Adapt this input to the target Domain's contract. Repeat safety belongs there.
|
|
6
|
-
export async function runJob({ scheduledAt, env, signal }) {
|
|
7
|
-
if (!env.KERNEL || !env.TARGET || !env.ACCOUNT_PRIVATE_JWK) {
|
|
8
|
-
throw new Error('Configure KERNEL, TARGET and the ACCOUNT_PRIVATE_JWK secret')
|
|
9
|
-
}
|
|
10
|
-
const session = openAccount(env.KERNEL, JSON.parse(env.ACCOUNT_PRIVATE_JWK))
|
|
11
|
-
try {
|
|
12
|
-
return await session.call(
|
|
13
|
-
{ target: Path.parse(env.TARGET), input: { scheduledAt } },
|
|
14
|
-
{ signal },
|
|
15
|
-
)
|
|
16
|
-
} finally {
|
|
17
|
-
session.close()
|
|
18
|
-
}
|
|
19
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
/**
|
|
3
|
-
* The line every deployment of one origin in one environment shares. The first organisation that
|
|
4
|
-
* deploys on it holds it, and only an operator transfer gives it to another: it stays registered
|
|
5
|
-
* and refused to every other organisation after its organisation, that organisation's Services or
|
|
6
|
-
* every deployment on it are deleted.
|
|
7
|
-
*/
|
|
8
|
-
export declare const DeploymentLine: import("@astrale-os/sdk/schema").AuthoredNodeClass<{
|
|
9
|
-
readonly description: "The deployment line of one origin in one environment, held by one organisation.";
|
|
10
|
-
readonly icon: import("@astrale-os/sdk/schema").ClassIcon;
|
|
11
|
-
readonly extends: readonly [import("@astrale-os/sdk/schema").KernelClass<"Timestamped">];
|
|
12
|
-
readonly properties: {
|
|
13
|
-
origin: z.ZodString;
|
|
14
|
-
environment: z.ZodString;
|
|
15
|
-
/** The 16-character fingerprint of `(origin, environment)`; it alone identifies the line. */
|
|
16
|
-
fingerprint: z.ZodString;
|
|
17
|
-
/** How the line reads in its deployments' labels: readable, or the fingerprint alone. */
|
|
18
|
-
line: z.ZodString;
|
|
19
|
-
};
|
|
20
|
-
readonly policies: {
|
|
21
|
-
read: () => import("@astrale-os/sdk/schema").Policy;
|
|
22
|
-
};
|
|
23
|
-
}>;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { classIcon, fullMatch, K, nodeClass } from '@astrale-os/sdk/schema';
|
|
2
|
-
import { GitBranch } from '@astrale-os/sdk/schema/icons';
|
|
3
|
-
import { z } from 'zod';
|
|
4
|
-
import { OwnLine } from '../policies/own-line.js';
|
|
5
|
-
/**
|
|
6
|
-
* The line every deployment of one origin in one environment shares. The first organisation that
|
|
7
|
-
* deploys on it holds it, and only an operator transfer gives it to another: it stays registered
|
|
8
|
-
* and refused to every other organisation after its organisation, that organisation's Services or
|
|
9
|
-
* every deployment on it are deleted.
|
|
10
|
-
*/
|
|
11
|
-
export const DeploymentLine = nodeClass({
|
|
12
|
-
description: 'The deployment line of one origin in one environment, held by one organisation.',
|
|
13
|
-
icon: classIcon.lucide(GitBranch),
|
|
14
|
-
extends: [K.classes.Timestamped],
|
|
15
|
-
properties: {
|
|
16
|
-
origin: z.string().min(1).max(253),
|
|
17
|
-
environment: z.string().min(1).max(63),
|
|
18
|
-
/** The 16-character fingerprint of `(origin, environment)`; it alone identifies the line. */
|
|
19
|
-
fingerprint: z.string().check(fullMatch('[a-z2-7]{16}')),
|
|
20
|
-
/** How the line reads in its deployments' labels: readable, or the fingerprint alone. */
|
|
21
|
-
line: z.string().min(16).max(40),
|
|
22
|
-
},
|
|
23
|
-
policies: { read: () => OwnLine },
|
|
24
|
-
});
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { edgeClass } from '@astrale-os/sdk/schema';
|
|
2
|
-
import { TraverseOwnedLineDeployment } from '../policies/traverse-owned-line-deployment.js';
|
|
3
|
-
import { DeploymentLine } from './deployment-line.js';
|
|
4
|
-
import { Deployment } from './deployment.js';
|
|
5
|
-
/** The line one deployment was made on; a deployment never moves to another line. */
|
|
6
|
-
export const deployment_on_line = edgeClass.directed({
|
|
7
|
-
description: 'The deployment line one Deployment belongs to.',
|
|
8
|
-
source: { as: 'deployment', accepts: [() => Deployment], outgoing: '1' },
|
|
9
|
-
target: { as: 'line', accepts: [() => DeploymentLine], incoming: '0..*' },
|
|
10
|
-
policies: { traverse: () => TraverseOwnedLineDeployment },
|
|
11
|
-
});
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The organisation holding one deployment line: an Identity of the Admin instance, a Shell User
|
|
3
|
-
* or Group, whose members and CI identities act for it through `extends_with`. A line outlives
|
|
4
|
-
* this Edge: deleting its organisation removes the Edge and leaves the line held by nobody until
|
|
5
|
-
* an operator transfer.
|
|
6
|
-
*
|
|
7
|
-
* Hence at most one holder, not exactly one: the Kernel deletes a Node only together with every
|
|
8
|
-
* incident Edge, so a required holder would make the organisation undeletable unless its lines
|
|
9
|
-
* went with it, and a deleted line would free its fingerprint for another organisation.
|
|
10
|
-
*/
|
|
11
|
-
export declare const line_owned_by: import("@astrale-os/sdk/schema").DirectedEdgeClass<{
|
|
12
|
-
readonly depth: 0;
|
|
13
|
-
readonly abstract: false;
|
|
14
|
-
readonly extends: readonly [];
|
|
15
|
-
readonly properties: never;
|
|
16
|
-
readonly source: {
|
|
17
|
-
readonly as: "line";
|
|
18
|
-
readonly outgoing: "0..1";
|
|
19
|
-
};
|
|
20
|
-
readonly target: {
|
|
21
|
-
readonly as: "owner";
|
|
22
|
-
readonly incoming: "0..*";
|
|
23
|
-
};
|
|
24
|
-
readonly constraints: Record<never, never>;
|
|
25
|
-
readonly effectiveProperties: never;
|
|
26
|
-
}>;
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { edgeClass, K } from '@astrale-os/sdk/schema';
|
|
2
|
-
import { TraverseOwnedLine } from '../policies/traverse-owned-line.js';
|
|
3
|
-
import { DeploymentLine } from './deployment-line.js';
|
|
4
|
-
/**
|
|
5
|
-
* The organisation holding one deployment line: an Identity of the Admin instance, a Shell User
|
|
6
|
-
* or Group, whose members and CI identities act for it through `extends_with`. A line outlives
|
|
7
|
-
* this Edge: deleting its organisation removes the Edge and leaves the line held by nobody until
|
|
8
|
-
* an operator transfer.
|
|
9
|
-
*
|
|
10
|
-
* Hence at most one holder, not exactly one: the Kernel deletes a Node only together with every
|
|
11
|
-
* incident Edge, so a required holder would make the organisation undeletable unless its lines
|
|
12
|
-
* went with it, and a deleted line would free its fingerprint for another organisation.
|
|
13
|
-
*/
|
|
14
|
-
export const line_owned_by = edgeClass.directed({
|
|
15
|
-
description: 'The organisation that holds one deployment line.',
|
|
16
|
-
source: { as: 'line', accepts: [() => DeploymentLine], outgoing: '0..1' },
|
|
17
|
-
target: { as: 'owner', accepts: [K.classes.Identity], incoming: '0..*' },
|
|
18
|
-
policies: { traverse: () => TraverseOwnedLine },
|
|
19
|
-
});
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
/**
|
|
3
|
-
* A label that names no deployment the caller may read: an unknown label and another
|
|
4
|
-
* organisation's deployment answer alike, so the answer never tells one from the other.
|
|
5
|
-
*/
|
|
6
|
-
export declare const deploymentLabelNotFound: Readonly<{
|
|
7
|
-
readonly family: "NOT_FOUND";
|
|
8
|
-
readonly message: "No deployment of yours has this label.";
|
|
9
|
-
readonly details: z.ZodObject<{
|
|
10
|
-
label: z.ZodString;
|
|
11
|
-
}, z.core.$strict>;
|
|
12
|
-
}>;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { error } from '@astrale-os/sdk/schema/errors';
|
|
2
|
-
import { z } from 'zod';
|
|
3
|
-
/**
|
|
4
|
-
* A label that names no deployment the caller may read: an unknown label and another
|
|
5
|
-
* organisation's deployment answer alike, so the answer never tells one from the other.
|
|
6
|
-
*/
|
|
7
|
-
export const deploymentLabelNotFound = error({
|
|
8
|
-
family: 'NOT_FOUND',
|
|
9
|
-
message: 'No deployment of yours has this label.',
|
|
10
|
-
details: z.strictObject({ label: z.string().min(1).max(63) }),
|
|
11
|
-
});
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
/**
|
|
3
|
-
* Asked of retention by anyone but the registry Domain (`SERVICES_REGISTRY_ORIGIN`). Only the
|
|
4
|
-
* registry knows which releases are published, so a line holder cannot keep its own preview by
|
|
5
|
-
* marking it, and only the registry runs the expiry of every organisation's previews.
|
|
6
|
-
*/
|
|
7
|
-
export declare const deploymentRegistryOnly: Readonly<{
|
|
8
|
-
readonly family: "UNSUPPORTED";
|
|
9
|
-
readonly message: "Only the registry Domain marks deployments published and expires previews.";
|
|
10
|
-
readonly details: z.ZodObject<{}, z.core.$strict>;
|
|
11
|
-
}>;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { error } from '@astrale-os/sdk/schema/errors';
|
|
2
|
-
import { z } from 'zod';
|
|
3
|
-
/**
|
|
4
|
-
* Asked of retention by anyone but the registry Domain (`SERVICES_REGISTRY_ORIGIN`). Only the
|
|
5
|
-
* registry knows which releases are published, so a line holder cannot keep its own preview by
|
|
6
|
-
* marking it, and only the registry runs the expiry of every organisation's previews.
|
|
7
|
-
*/
|
|
8
|
-
export const deploymentRegistryOnly = error({
|
|
9
|
-
family: 'UNSUPPORTED',
|
|
10
|
-
message: 'Only the registry Domain marks deployments published and expires previews.',
|
|
11
|
-
details: z.strictObject({}),
|
|
12
|
-
});
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { method } from '@astrale-os/sdk/schema';
|
|
2
|
-
import { deploymentRequest } from '../types/deployment-request.js';
|
|
3
|
-
import { deploymentResponse } from '../types/deployment-response.js';
|
|
4
|
-
/**
|
|
5
|
-
* Host one release as an immutable deployment on its publisher's line. Any authenticated identity
|
|
6
|
-
* may ask; the handler proves that it acts for the organisation it names before any write.
|
|
7
|
-
*/
|
|
8
|
-
export const deployCloudflareDeployment = method({
|
|
9
|
-
description: 'Host one release as an immutable deployment on its publisher line.',
|
|
10
|
-
auth: 'authenticated',
|
|
11
|
-
static: true,
|
|
12
|
-
input: deploymentRequest,
|
|
13
|
-
output: deploymentResponse,
|
|
14
|
-
});
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/** Where this Services runtime addresses the deployments it hosts. */
|
|
2
|
-
export declare const describeDeploymentHosting: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
|
|
3
|
-
readonly mode: 'value';
|
|
4
|
-
readonly value: {
|
|
5
|
-
routingDomain: string;
|
|
6
|
-
addressing: "opaque" | "readable";
|
|
7
|
-
};
|
|
8
|
-
}, "authenticated", true, false, undefined>>;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { method } from '@astrale-os/sdk/schema';
|
|
2
|
-
import { z } from 'zod';
|
|
3
|
-
import { deploymentHosting } from '../types/deployment-hosting.js';
|
|
4
|
-
/** Where this Services runtime addresses the deployments it hosts. */
|
|
5
|
-
export const describeDeploymentHosting = method({
|
|
6
|
-
description: 'Describe the routing domain and line addressing of hosted deployments.',
|
|
7
|
-
auth: 'authenticated',
|
|
8
|
-
static: true,
|
|
9
|
-
input: z.strictObject({}),
|
|
10
|
-
output: deploymentHosting,
|
|
11
|
-
});
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* One pass of preview expiry over every line: a preview expires 30 days after its last call or
|
|
3
|
-
* its activation, whichever is later, and a published deployment never does. The pass is a plan
|
|
4
|
-
* unless the runtime enforces expiry. Only the registry Domain runs it.
|
|
5
|
-
*/
|
|
6
|
-
export declare const expireDeploymentPreviews: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
|
|
7
|
-
limit?: number | undefined;
|
|
8
|
-
apply?: boolean | undefined;
|
|
9
|
-
}, {
|
|
10
|
-
readonly mode: 'value';
|
|
11
|
-
readonly value: {
|
|
12
|
-
planned: string[];
|
|
13
|
-
retired: string[];
|
|
14
|
-
pending: string[];
|
|
15
|
-
};
|
|
16
|
-
}, "authenticated", true, false, undefined>>;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { method } from '@astrale-os/sdk/schema';
|
|
2
|
-
import { expirePreviewsInput, expirePreviewsOutput } from '../types/deployment-retention.js';
|
|
3
|
-
/**
|
|
4
|
-
* One pass of preview expiry over every line: a preview expires 30 days after its last call or
|
|
5
|
-
* its activation, whichever is later, and a published deployment never does. The pass is a plan
|
|
6
|
-
* unless the runtime enforces expiry. Only the registry Domain runs it.
|
|
7
|
-
*/
|
|
8
|
-
export const expireDeploymentPreviews = method({
|
|
9
|
-
description: 'Plan, or where enforced apply, the expiry of previews uncalled for 30 days.',
|
|
10
|
-
auth: 'authenticated',
|
|
11
|
-
static: true,
|
|
12
|
-
input: expirePreviewsInput,
|
|
13
|
-
output: expirePreviewsOutput,
|
|
14
|
-
});
|
package/dist/schema/modules/deployment/functions/list-cloudflare-deployment-secret-names.d.ts
DELETED
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
/** Decided as `setSecret`: `OwnDeployment` for the caller, before the deployment is read. */
|
|
2
|
-
export declare const listCloudflareDeploymentSecretNames: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<Record<string, never>, {
|
|
3
|
-
readonly mode: 'value';
|
|
4
|
-
readonly value: string[];
|
|
5
|
-
}, "authenticated", false, false, undefined>>;
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { method } from '@astrale-os/sdk/schema';
|
|
2
|
-
import { listDeploymentSecretNamesContract } from '../types/deployment-secret.js';
|
|
3
|
-
/** Decided as `setSecret`: `OwnDeployment` for the caller, before the deployment is read. */
|
|
4
|
-
export const listCloudflareDeploymentSecretNames = method(listDeploymentSecretNamesContract);
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { method } from '@astrale-os/sdk/schema';
|
|
2
|
-
import { listDeploymentsInput, listDeploymentsOutput } from '../types/deployment-hosting.js';
|
|
3
|
-
/** The deployments of the lines the caller holds, or acts for through `extends_with`. */
|
|
4
|
-
export const listCloudflareDeployments = method({
|
|
5
|
-
description: 'List the deployments of the lines the caller holds.',
|
|
6
|
-
auth: 'authenticated',
|
|
7
|
-
static: true,
|
|
8
|
-
input: listDeploymentsInput,
|
|
9
|
-
output: listDeploymentsOutput,
|
|
10
|
-
});
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The last call of each deployment named, as the dispatcher counted it. The caller must hold
|
|
3
|
-
* every label's line; the registry Domain may read any label.
|
|
4
|
-
*/
|
|
5
|
-
export declare const readDeploymentLastCalls: import("@astrale-os/sdk/schema").Method<import("@astrale-os/sdk/schema").CallableProjection<{
|
|
6
|
-
labels: string[];
|
|
7
|
-
}, {
|
|
8
|
-
readonly mode: 'value';
|
|
9
|
-
readonly value: Record<string, string | null>;
|
|
10
|
-
}, "authenticated", true, false, undefined>>;
|