-
Notifications
You must be signed in to change notification settings - Fork 385
Add migration tool, guide and add script to test if migration job from api-server to CRD is working #2710
Add migration tool, guide and add script to test if migration job from api-server to CRD is working #2710
Conversation
* Move creating PVC functionality to the migration tool
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: mszostok The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
I think you actually broke some stuff in the instance controller in pkg/controller... |
That’s true, there is sth wrong and I’m still working on it;) But overall logic and documentation will not be changed |
@piotrmiskiewicz @jberkhahn PTAL about issue: I had to adjust test because here we also fixed repetitive updates on status entry. Here are changes which I applied ae2caca |
5d7a9c2
to
433c7ac
Compare
433c7ac
to
e9ce4f1
Compare
Waiting for your reviews :) and also block tide merge. We will need to do that manually using the rebase and merge action to keep the commits history |
/lgtm |
docs/migration-apiserver-to-crds.md
Outdated
This document describes how the migration works and what actions must be performed. | ||
|
||
>**NOTE:** | ||
Before starting the migration, make sure that you performed a full backup of your cluster. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"you have performed"
docs/migration-apiserver-to-crds.md
Outdated
layout: docwithnav | ||
--- | ||
|
||
Service Catalog upgrade from version 0.2.x (and earlier) to 0.3.x needs a data migration. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"Upgrading Service Catalog from versions 0.2.x (and earlier) to 0.3.x requires a database migration."
docs/migration-apiserver-to-crds.md
Outdated
![Service Catalog upgrade steps](images/sc-migration-to-crds-steps.svg) | ||
|
||
The upgrade to CRDs consists of the following steps: | ||
1. Make API Server read-only. Before any backup, we should block any resource changes to be sure the backup makes a snapshot. We need to avoid any changes when the migration tool is backuping resources. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"backing up resources"
docs/migration-apiserver-to-crds.md
Outdated
|
||
## Upgrade Service Catalog manually | ||
|
||
### Backup and deleting resources |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"Backup and delete resources"
docs/migration-apiserver-to-crds.md
Outdated
PLATFORM=darwin make build | ||
``` | ||
|
||
Resulting executable file can be found in the `bin` subdirectory. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"The resulting"
/lgtm |
@jberkhahn changes applied:) there is also PR for adding CI for running migration tests: kubernetes/test-infra#14464. It was executed on our infra: https://storage.googleapis.com/kyma-prow-logs/logs/post-test-sc-upgrade-job/1176903408213299200/build-log.txt. You can also execute it locally:
|
/lgtm |
Description
Changes proposed in this pr:
Add migration tool and guide which allow clients to do easily migration from api-server to CRD approach.
Scenario
pre-upgrade hook
OwnerReference
fields in all Secrets pointed by any ServiceBindingupgrade
post-upgrade
OwnerReference
to all Secrets pointed by ServiceBindings.Full documentation with diagrams is added in this PR: https://github.com/kubernetes-sigs/service-catalog/pull/2710/files#diff-c13a535c132e80742d0b5f424960c632
Add script to test if migration job from api-server to CRD is working (will be executed as CI pipeline).
Scenario:
Pipeline in
test-infra
: Add Service Catalog pipeline for checking migration scenario kubernetes/test-infra#14464Example of this pipeline execution: https://storage.googleapis.com/kyma-prow-logs/logs/post-test-sc-upgrade-job/1176903408213299200/build-log.txt
Fixes:
Provide Migration Path for Apiserver -> CRDs #2634
Add upgrade test to pipeline #2660