Skip to content

data-app deploy on a managed-repo app keeps an old config version, so runtime.workspace and storage mappings never apply #799

Description

@trobertsonkbc

Summary

kbagent data-app create --use-managed-git-repo leaves the app's Storage configuration without parameters.dataApp.git. The platform writes the git block, then kbagent's own PUT overwrites the whole configuration without it. Deploying that latest version fails at startup with:

[ERROR] dataApp.git.repository is required in /data/config.json

Environment

  • kbagent v0.95.0, Windows 11
  • Stack connection.us-east4.gcp.keboola.com, project 133, app type python-js

Reproduction

kbagent data-app create --project P --name "X" --slug x --use-managed-git-repo --auth password --no-deploy

Config versions after create (all written by the kbagent token):

Version Change description parameters.dataApp.git
1 Configuration created absent
2 Set App ID absent
3 Configure managed Git repository present (repository, branch: main, private: true)
4 Initial data-app config via kbagent data-app create absent, dropped

Version 4 adds runtime.workspace.enabled and runtime.backend.size but rebuilds parameters from scratch, so the git block written in v3 is lost.

After pushing code to the managed repo:

  • kbagent data-app deploy --app-id N --wait (no --config-version) reported config_version: "3", deploying v3, which has the git block but no runtime.workspace. The app started without WORKSPACE_ID / QUERY_SERVICE_URL.
  • kbagent data-app deploy --app-id N --config-version <latest> fails with the error above.

Workaround

kbagent config update --component-id keboola.data-apps --config-id <cfg> --merge \
  --set 'parameters.dataApp.git={"repository":"https://git.<stack>/keboola/app-<id>.git","branch":"main","private":true}'
kbagent data-app deploy --app-id <id> --config-version <new latest> --wait

Expected

  1. data-app create merges into the existing configuration (or re-reads it before the PUT), so parameters.dataApp.git survives.
  2. data-app deploy without --config-version deploys the latest Storage configuration version, as its help text says ("Deploy the latest Storage config"). Here it deployed v3 while v5 existed.

Related

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions