feat: import prepared Catalog bindings through authenticated services
This commit is contained in:
@@ -113,6 +113,22 @@ Cancellation cleans up named one-shot containers and releases the lock. Hard-kil
|
||||
processes require explicit stale-owner inspection; automatic destructive repair is
|
||||
not performed. Errors contain a stage/action without raw Docker output or secrets.
|
||||
|
||||
Success reports `platform_ready: true` and `workspace_ready: false`: services and
|
||||
local authentication protection are checked, while binding import, workspace
|
||||
preprocessing, model use and final readiness remain separate obligations.
|
||||
Binding import uses a named, bounded one-shot client on the Compose network. Protected
|
||||
bootstrap material travels through stdin, never arguments or journals. The client logs
|
||||
in through local authentication, obtains CSRF protection, calls permission-checked
|
||||
administration services, and logs out. Prepare `authentication.username` and
|
||||
`authentication.passwordFile` in `database-bootstrap.yaml`; offline validation checks
|
||||
the account/password against the private local registry and seals that file too.
|
||||
|
||||
The registry consumes the exact prepared Git file inventory and optional commit, without
|
||||
retargeting or refreshing an existing checkout. Binding creation and its durable import
|
||||
receipt commit together in the Catalog. The receipt survives administrative deletion.
|
||||
Reruns compare live configuration and encrypted-store contents, retain equivalent values,
|
||||
and stop on divergence. No bootstrap document becomes runtime authority. The application
|
||||
tests the imported connection; a successful host probe alone is insufficient.
|
||||
|
||||
Success reports `platform_ready: true`, `bindings_ready: true`, `workspace_ready: false`.
|
||||
The bounded `binding_import` report distinguishes authentication, workspace reconciliation,
|
||||
binding reconciliation and container connectivity failures. Workspace preprocessing,
|
||||
model use and final readiness remain separate obligations. Published preview.5 predates
|
||||
binding import; use a subsequent matching image/operator release for this extension.
|
||||
|
||||
@@ -93,6 +93,9 @@ must exist. It starts no services and does not implicitly generate passwords.
|
||||
|
||||
```yaml
|
||||
schemaVersion: 1
|
||||
authentication:
|
||||
username: admin
|
||||
passwordFile: /private/path/my-installation/secrets/admin-password
|
||||
databases:
|
||||
- workspaceId: practice
|
||||
engine: postgres
|
||||
@@ -116,7 +119,11 @@ must exist. It starts no services and does not implicitly generate passwords.
|
||||
`evidenceSecretFiles` with key `evidence.signed_urls`; static S3 credentials need
|
||||
`evidence.access_key`, `evidence.secret_key` and optional `evidence.session_token`.
|
||||
All values are private file paths. Workspace descriptors remain schema v4;
|
||||
this bootstrap input is not a second runtime Catalog.
|
||||
this bootstrap input is not a second runtime Catalog. The document also includes
|
||||
`authentication.username: admin` and `authentication.passwordFile` pointing to
|
||||
private `secrets/admin-password`. Update these references before validation if
|
||||
selecting another administrator. Execution uses ordinary login and administrative
|
||||
permissions, without asking for a password during setup.
|
||||
4. Explicitly generate technical credentials in the standard layout:
|
||||
|
||||
```sh
|
||||
@@ -211,10 +218,24 @@ comes from the prepared authentication documents. Secrets retain private permiss
|
||||
services that read them run with the operator's UID. This path does not convert an
|
||||
existing stack with incompatible volume ownership.
|
||||
|
||||
`platform_ready: true, workspace_ready: false` confirms platform startup and protected
|
||||
endpoints, **not** readiness to query a database. Binding import, workspace activation
|
||||
and preprocessing, and a model smoke test are subsequent steps. The three curated
|
||||
example databases remain deferred.
|
||||
Execution then imports bindings through authenticated Catalog services and the existing
|
||||
secret store. It verifies the remote, branch, revision and exact contents against the
|
||||
prepared plan, without silently retargeting an existing checkout. Database connectivity
|
||||
is tested again by the application in the containers.
|
||||
|
||||
`platform_ready: true, bindings_ready: true, workspace_ready: false` confirms the platform,
|
||||
authentication and database connections. Workspace preprocessing and model checks remain
|
||||
necessary before a question. The three curated examples remain deferred. This extension
|
||||
requires a bundle newer than preview.5; preview.5 only certifies platform startup.
|
||||
|
||||
An equivalent rerun does not duplicate bindings or credentials. Administrative changes
|
||||
or deletion stop import with `binding_reconciliation_required`: compare the bootstrap
|
||||
with Administration and preserve the intended change. Do not remove volumes or Catalog
|
||||
receipts to bypass this check. `workspace_reconciliation_required` identifies a source
|
||||
mismatch; `authentication_required` requires correcting the prepared administrator;
|
||||
`container_connection_failed` means the DWH cannot be reached or authenticated from the
|
||||
application network. Scalar credential files ignore outer whitespace, matching preflight
|
||||
probes; PEM and known-host files retain their exact bytes.
|
||||
With the default configuration, open `http://127.0.0.1:8080` to sign in. The browser
|
||||
origin must match `publicUrl`; do not substitute `localhost` for `127.0.0.1`.
|
||||
|
||||
|
||||
@@ -94,6 +94,9 @@ deve esistere. Non avvia servizi e non genera implicitamente password.
|
||||
|
||||
```yaml
|
||||
schemaVersion: 1
|
||||
authentication:
|
||||
username: admin
|
||||
passwordFile: /percorso/privato/mia-installazione/secrets/admin-password
|
||||
databases:
|
||||
- workspaceId: pratica
|
||||
engine: postgres
|
||||
@@ -118,7 +121,11 @@ deve esistere. Non avvia servizi e non genera implicitamente password.
|
||||
`evidence.signed_urls`; S3 con credenziali statiche richiede `evidence.access_key`
|
||||
e `evidence.secret_key`, con `evidence.session_token` facoltativo. Tutti i valori
|
||||
sono percorsi di file privati. I workspace rimangono nello schema v4: il bootstrap
|
||||
è un input iniziale, non un secondo Catalog runtime.
|
||||
è un input iniziale, non un secondo Catalog runtime. Il documento include anche
|
||||
`authentication.username: admin` e `authentication.passwordFile` con il percorso
|
||||
privato di `secrets/admin-password`. Se si cambia amministratore, aggiornare questi
|
||||
riferimenti prima della validazione: il setup usa il login ordinario e i permessi
|
||||
amministrativi, senza richiedere una password durante l'esecuzione.
|
||||
4. Generare esplicitamente le credenziali tecniche nel layout standard:
|
||||
|
||||
```sh
|
||||
@@ -219,10 +226,26 @@ proviene dai documenti di autenticazione già preparati. I segreti mantengono i
|
||||
permessi privati: i servizi interessati usano l'UID dell'operatore. Questo percorso
|
||||
non converte stack preesistenti con proprietari o volumi incompatibili.
|
||||
|
||||
Il risultato `platform_ready: true, workspace_ready: false` certifica l'avvio della
|
||||
piattaforma e la protezione degli endpoint, **non** la possibilità di interrogare
|
||||
già il database. Import dei binding, attivazione/preprocessing dei workspace e
|
||||
prova modello sono i passi successivi. I tre database di esempio restano differiti.
|
||||
L'esecuzione importa poi i binding tramite i servizi autenticati del Catalog e il
|
||||
secret store esistente. Verifica che remoto, branch, revisione e contenuti coincidano
|
||||
con i documenti del piano; non cambia implicitamente un checkout già presente.
|
||||
La connessione al DWH viene riprovata dall'applicazione nei container.
|
||||
|
||||
Il risultato `platform_ready: true, bindings_ready: true, workspace_ready: false`
|
||||
conferma piattaforma, autenticazione e collegamenti database. Preprocessing del
|
||||
workspace e prova modello rimangono necessari prima di una domanda. I tre database
|
||||
di esempio restano differiti. Questa estensione richiede un bundle successivo a
|
||||
preview.5; preview.5 certifica soltanto l'avvio della piattaforma.
|
||||
|
||||
Un secondo avvio non duplica binding o credenziali. Se un amministratore ha modificato
|
||||
o eliminato un binding, il codice `binding_reconciliation_required` ferma l'import:
|
||||
confrontare il bootstrap con la configurazione in Amministrazione e preservare la
|
||||
modifica voluta. Non cancellare volumi o ricevute Catalog per aggirare il controllo.
|
||||
`workspace_reconciliation_required` indica una differenza nella sorgente workspace;
|
||||
`authentication_required` richiede di correggere l'amministratore predisposto;
|
||||
`container_connection_failed` indica un DWH non raggiungibile o non autenticabile
|
||||
dalla rete applicativa. I segreti scalari letti dai file ignorano spazi e ritorni a
|
||||
capo esterni, come i probe preliminari; PEM e known-hosts restano invariati.
|
||||
Con il valore predefinito, aprire `http://127.0.0.1:8080` per l'accesso: l'origine
|
||||
del browser deve coincidere con `publicUrl`, quindi non sostituire `127.0.0.1` con
|
||||
`localhost`.
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
# Prepared Catalog binding import
|
||||
|
||||
Ticket #48 extends document-first `installation apply` after platform health.
|
||||
It verifies the exact prepared workspace source and imports the selected database
|
||||
configurations through authenticated, permission-checked application services.
|
||||
This source increment is not present in the published preview.5 bundle.
|
||||
|
||||
The prepared bootstrap now includes a local administrator username and private
|
||||
password-file reference. Offline validation verifies them against the authentication
|
||||
documents. Runtime uses ordinary login, session and CSRF handling. A named one-shot
|
||||
client on the Compose network receives secrets through stdin and logs out afterward.
|
||||
The existing Docker runner removes that container on interruption.
|
||||
|
||||
Each first import commits its Catalog database, binding and receipt together. The
|
||||
receipt survives administrative deletion. Equivalent reruns preserve secret-store
|
||||
generation and binding version; changed configuration, credentials, deleted bindings
|
||||
or a different repository require reconciliation. Interrupted creation is recovered
|
||||
from Catalog state even when the host journal has not yet recorded success.
|
||||
|
||||
Verification includes:
|
||||
|
||||
- Native prepare/validate/plan/apply/retry with closed stdin and no host runtime on
|
||||
the consumer command PATH (Docker boundary fixture).
|
||||
- Real local login, CSRF, binding API and logout through the shipped client module.
|
||||
- Real Git source inventories, revision mismatch and refusal to retarget a checkout.
|
||||
- Real PostgreSQL Catalog integration, read-only connector authentication, optimistic
|
||||
versions, repeat imports and retained receipts after deletion.
|
||||
- Secret newline normalization, no secret arguments/output, concurrent imports,
|
||||
administrative divergence and interruption after database commit.
|
||||
- Go suite, backend suite under the supported Node 24 runtime, TypeScript checking
|
||||
and strict public documentation build.
|
||||
|
||||
The PostgreSQL integration runs the application service against a Docker database;
|
||||
the public-image consumer trial for this new increment remains to be performed.
|
||||
It does not establish workspace preprocessing, model operation, a human-reviewed
|
||||
question, curated example availability or fresh-machine OS acceptance.
|
||||
Reference in New Issue
Block a user