Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate disabled plugins to Cloud #1355

Merged
merged 4 commits into from
Jan 24, 2024

Conversation

madebyrogal
Copy link
Contributor

Description

Changes proposed in this pull request:

  • migrate disabled plugin
  • fix missing displayName during migration
  • fix RBAC conversion
  • fix installation command abort update existing instalation

Testing

Test this against Botkube Cloud dev setup (UI and BE).

Check out the PR and build the latest CLI:

export IMAGE_TAG=v9.99.9-dev
make release-snapshot-cli
chmod +x ./dist/botkube-cli_darwin_amd64_v1/botkube && cp ./dist/botkube-cli_darwin_amd64_v1/botkube /usr/local/bin/botkube_dev

Then, install Botkube in your k3d cluster

export ALLOW_KUBECTL=true
export ALLOW_HELM=true
export SLACK_CHANNEL_NAME=botkube-demo \
export SLACK_API_APP_TOKEN=xapp-... \
export SLACK_API_BOT_TOKEN=xoxb-... \
export CLUSTER_NAME=dev
botkube_dev install --version 1.7.0 \
--set communications.default-group.socketSlack.enabled=true \
--set communications.default-group.socketSlack.channels.default.name=${SLACK_CHANNEL_NAME} \
--set communications.default-group.socketSlack.appToken=${SLACK_API_APP_TOKEN} \
--set communications.default-group.socketSlack.botToken=${SLACK_API_BOT_TOKEN} \
--set settings.clusterName=${CLUSTER_NAME} \
--set 'executors.k8s-default-tools.botkube/kubectl.enabled'=${ALLOW_KUBECTL} \
--set 'executors.k8s-default-tools.botkube/helm.enabled'=${ALLOW_HELM}

Then you will be asked about updating existing instance (test both options)

  • option 1: update existing instance
  • option 2: don't update

Each time check if you can see disabled plugins in UI

Related issue(s)

@madebyrogal madebyrogal added bug Something isn't working enhancement New feature or request labels Jan 19, 2024
@madebyrogal madebyrogal force-pushed the migrate-disabled-plugins branch from bd842f9 to a77baa6 Compare January 22, 2024 10:03
@madebyrogal madebyrogal marked this pull request as ready for review January 22, 2024 11:24
@madebyrogal madebyrogal requested review from a team and pkosiec January 22, 2024 11:24
Copy link
Collaborator

@pkosiec pkosiec left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't test it, just code review. Please update Migration E2E integration tests to cover the new functionality and after that (plus fixing the minor comments) I'll test the PR E2E 🙂 Thanks!

Hint: you can open a new PR based on this one using branch on the upstream repo, to be able to trigger the migration tests there.

internal/cli/install/helm/install.go Show resolved Hide resolved
internal/cli/install/install.go Outdated Show resolved Hide resolved
pkg/config/config.go Show resolved Hide resolved
@pkosiec pkosiec changed the title ADD migrate for disabled plugin Add migration for disabled plugins Jan 24, 2024
Copy link
Collaborator

@pkosiec pkosiec left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, good work!

@pkosiec pkosiec mentioned this pull request Jan 24, 2024
@pkosiec pkosiec changed the title Add migration for disabled plugins Migrate disabled plugins to Cloud Jan 24, 2024
@madebyrogal madebyrogal force-pushed the migrate-disabled-plugins branch from 6e89488 to efa4e28 Compare January 24, 2024 09:26
@madebyrogal madebyrogal merged commit 69b9cc7 into kubeshop:main Jan 24, 2024
15 checks passed
@madebyrogal madebyrogal deleted the migrate-disabled-plugins branch January 24, 2024 09:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants