Skip to content

Commit

Permalink
fix suggestions
Browse files Browse the repository at this point in the history
Signed-off-by: Flavius Lacatusu <flacatus@redhat.com>
  • Loading branch information
flacatus committed Jul 28, 2021
1 parent f8e0577 commit 1624742
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,19 +140,19 @@ $ chectl server:deploy --installer=olm --platform=<CHECTL_SUPPORTED_PLATFORM> --

### Deploy stable Che operator in Cluster Wide Availability

Eclipse Che introduce a new channel which install Eclipse Che in AllNamespace mode with Devworkspace Operator like a OLM dependency.
Eclipse Che introduced a new channel which installs Eclipse Che in AllNamespace mode with Devworkspace Operator like an OLM dependency.
More info about DevWorkspace Operator can be found [here](https://github.com/devfile/devworkspace-operator).

Before installing Eclipse Che using channel `stable-all-namespaces` we need to consider the following:

* It is not possible to have Eclipse Che installed in single Namespace (currently the default one) and then try to install Che in All Namespace mode using the new channel stable-all-namespaces.
* To update to stable-all-namespaces channel you need first to remove all subscriptions created for che installed from nightly or stable
* To update to stable-all-namespaces channel you need first to remove all subscriptions created for Che installed from nightly or stable
channels. IMPORTANT: Removing subscriptions doesn’t mean Eclipse Che operands(che-server, keycloak or roles) will be removed from the cluster.
* DevWorkspace engine will be by default enabled in the new channel.
* In case if you have already installed Che with DevWorkspace engine enabled from channels nightly or stable you need to remove all DevWorkspace resources from the cluster following the next [scripts](https://github.com/devfile/devworkspace-operator/blob/main/build/make/deploy.mk#L77).
* `stable-all-namespaces` channel is supported only in openshift.
* `stable-all-namespaces` channel is supported only in OpenShift.

If the Openshift Cluster already have all these considerations done you can proceed to install the Eclipse Che using stable-all-namespaces channel from OperatorHub or using the new channel you need to perform next chectl command:
If the OpenShift Cluster already have all these considerations done you can proceed to install the Eclipse Che using stable-all-namespaces channel from OperatorHub or using the new channel you need to perform the following chectl command:

```bash
chectl server:deploy --installer=olm --platform=openshift --olm-channel=stable-all-namespaces
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ dependencies:
- type: olm.package
value:
packageName: devworkspace-operator
version: ">=0.6.0"
version: ">=0.8.0"
16 changes: 8 additions & 8 deletions pkg/deploy/dev-workspace/dev_workspace.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,12 @@ import (
)

var (
DevWorkspaceNamespace = "devworkspace-controller"
DevWorkspaceCheNamespace = "devworkspace-che"
DevWorkspaceWebhookName = "controller.devfile.io"
DevWorkspaceServiceAccount = "devworkspace-controller-serviceaccount"
DevWorkspaceService = "devworkspace-controller-manager-service"
DevWorkspaceDeploymentName = "devworkspace-controller-manager"
DevWorkspaceNamespace = "devworkspace-controller"
DevWorkspaceWebhookName = "controller.devfile.io"
DevWorkspaceServiceAccount = "devworkspace-controller-serviceaccount"
DevWorkspaceService = "devworkspace-controller-manager-service"
DevWorkspaceDeploymentName = "devworkspace-controller-manager"

SubscriptionResourceName = "subscriptions"
CheManagerResourcename = "chemanagers"
ClusterServiceVersionResourceName = "clusterserviceversions"
Expand Down Expand Up @@ -117,7 +117,7 @@ func ReconcileDevWorkspace(deployContext *deploy.DeployContext) (bool, error) {
}

// Check if exists devworkspace operator csv is already installed
devWorkspaceOperatorCSVExists := isDevWorkspaceControllerCSVExists(deployContext)
devWorkspaceOperatorCSVExists := isDevWorkspaceOperatorCSVExists(deployContext)
if devWorkspaceOperatorCSVExists {
return true, nil
}
Expand Down Expand Up @@ -161,7 +161,7 @@ func ReconcileDevWorkspace(deployContext *deploy.DeployContext) (bool, error) {
return true, nil
}

func isDevWorkspaceControllerCSVExists(deployContext *deploy.DeployContext) bool {
func isDevWorkspaceOperatorCSVExists(deployContext *deploy.DeployContext) bool {
// If clusterserviceversions resource doesn't exist in cluster DWO as well will not be present
if !util.HasK8SResourceObject(deployContext.ClusterAPI.DiscoveryClient, ClusterServiceVersionResourceName) {
return false
Expand Down

0 comments on commit 1624742

Please sign in to comment.