Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,27 @@
// update/ossm-updating-openshift-service-mesh.adoc

:_mod-docs-content-type: PROCEDURE
[id="preparing-to-update-istio-control-plane-with-inplace_{context}"]
= Preparing to update Istio control plane with InPlace strategy
[id="installing-istio-with-inplace-strategy_{context}"]
= Installing with InPlace update strategy

You can configure the {istio} control plane and workloads for the `InPlace` update strategy. When using the `InPlace` strategy, the `IstioRevision` resource created by the {SMProduct} Operator always uses the same name as the `{istio}` resource.
You can install the {istio} control plane, {istio} CNI, and the Bookinfo demo application using the `Inplace` update strategy.

[NOTE]
====
You can skip this installation procedure if the cluster already includes an {istio} deployment.
====

When using the `InPlace` strategy, the `IstioRevision` resource created by the {SMProduct} Operator always uses the same name as the `{istio}` resource.

.Procedure

. Create the `istio-system` namespace by running the following command:
+
[source,terminal]
----
$ oc create ns istio-system
----

. Attach the workloads to a control plane deployed using the `InPlace` strategy:

.. Label the namespace to automatically include all workloads by entering the following command:
Expand All @@ -20,7 +34,7 @@ $ oc label namespace <namespace_name> istio.io/rev=<revision_name>

.. Apply the revision label to individual workloads by modifying the pod template in the `Deployment` resource. For example:
+
[source,yaml, subs="attributes,verbatim"]
[source,yaml]
----
apiVersion: apps/v1
kind: Deployment
Expand All @@ -40,7 +54,7 @@ $ oc label namespace <namespace_name> istio-injection=enabled

. Deploy the {istio} control plane using the `InPlace` update strategy. The following example configuration creates an `{istio}` resource named `default` in the `istio-system` namespace:
+
[source,yaml, subs="attributes,verbatim"]
[source,yaml]
----
apiVersion: sailoperator.io/v1
kind: Istio
Expand All @@ -55,7 +69,7 @@ spec:

. Install the {istio} CNI plugin with the desired version. The following example configuration creates an `IstioCNI` resource named `default` in the `istio-cni` namespace:
+
[source,yaml, subs="attributes,verbatim"]
[source,yaml]
----
apiVersion: sailoperator.io/v1
kind: IstioCNI
Expand All @@ -75,16 +89,33 @@ spec:
$ oc create ns bookinfo
----

.. Label the `bookinfo` namespace to enable sidecar injection by running the following command:
+
[source,terminal]
----
$ oc label namespace bookinfo istio-injection=enabled
----

.. Install the `bookinfo` pods in the `bookinfo` namespace by running the following command:
+
[source,terminal]
----
$ oc apply -f https://raw.githubusercontent.com/openshift-service-mesh/istio/release-1.24/samples/bookinfo/platform/kube/bookinfo.yaml -n bookinfo
----

. Label the `bookinfo` namespace to enable sidecar injection by running the following command:
. Review the `Istio` resource by running the following command:
+
[source,terminal]
----
$ oc label namespace bookinfo istio-injection=enabled
$ oc get istio -n istio-system
----
+
.Example output
+
[source,terminal]
----
NAME REVISIONS READY IN USE ACTIVE REVISION STATUS VERSION AGE
default 1 1 1 default Healthy v1.24.3 115s
----
+
The `IN USE` field shows `1` because both the namespace label and the injected proxies reference the `IstioRevision` resource.
Original file line number Diff line number Diff line change
@@ -0,0 +1,134 @@
// Module included in the following assemblies:

// update/ossm-updating-openshift-service-mesh.adoc

:_mod-docs-content-type: PROCEDURE
[id="installing-istio-with-revisionbased-strategy-istiorevisiontag_{context}"]
= Installing Istio with RevisionBased strategy and IstioRevisionTag

You can install the {istio} control plane, `IstioRevisionTag` resource, {istio} CNI, and the Bookinfo demo application using the `RevisionBased` update strategy.

[NOTE]
====
You can use the following section to understand the update process. You can skip this installation if the cluster already includes an {istio} deployment.
====

.Procedure

. Create the `istio-system` namespace by running the following command:
+
[source,terminal]
----
$ oc create ns istio-system
----

. Deploy the {istio} control plane using the `RevisionBased` update strategy. The following example configuration creates an `{istio}` resource named `default` in the `istio-system` namespace:
+
.Example configuration
[source,yaml]
----
apiVersion: sailoperator.io/v1
kind: Istio
metadata:
name: default
spec:
namespace: istio-system
updateStrategy:
type: RevisionBased
version: v1.24.3
----

. Create an `IstioRevisionTag` resource. The following example configuration creates an `IstioRevisionTag` resource named `default`:
+
.Example configuration
[source,yaml]
----
apiVersion: sailoperator.io/v1
kind: IstioRevisionTag
metadata:
name: default
spec:
targetRef:
kind: Istio
name: default
----
+
Verify that the `targetRef` field points to the desired `{istio}` resource. In the example above, the `IstioRevisionTag` references the `{istio}` resource named `default`.

. Create the `istio-cni` namespace by running the following command:
+
[source,terminal]
----
$ oc create ns istion-cni
----

. Install the {istio} CNI plugin with the desired version. The following example configuration creates an `IstioCNI` resource named `default` in the `istio-cni` namespace:
+
.Example configuration
[source,yaml]
----
apiVersion: sailoperator.io/v1
kind: IstioCNI
metadata:
name: default
spec:
version: v1.24.3
namespace: istio-cni
----

. Configure application workloads to run in the cluster. The following example deploys the `bookinfo` application in the `bookinfo` namespace.

.. Create the `bookinfo` namespace by running the following command:
+
[source,terminal]
----
$ oc create ns bookinfo
----

.. Label the `bookinfo` namespace to enable sidecar injection by running the following command:
+
[source,terminal]
----
$ oc label namespace bookinfo istio-injection=enabled
----

.. Install the `bookinfo` pods in the `bookinfo` namespace by running the following command:
+
[source,terminal]
----
$ oc apply -f https://raw.githubusercontent.com/openshift-service-mesh/istio/release-1.24/samples/bookinfo/platform/kube/bookinfo.yaml -n bookinfo
----

. Review the `IstioRevisionTag` resource by running the following command:
+
[source,terminal]
----
$ oc get istiorevisiontag
----
+
.Example output
+
[source,terminal]
----
NAME STATUS IN USE REVISION AGE
default Healthy True default-v1-24-3 2m46s
----
+
The `IN USE` field shows `True` because both active workloads and the `bookinfo` namespace now reference the tag.

. Confirm that the proxy version matches the control plane version by running the following command:
+
[source,terminal]
----
$ istioctl proxy-status
----
+
The `VERSION` column should match the control plane version.
+
.Example output
+
[source,terminal]
----
NAME TYPE READY STATUS IN USE VERSION AGE
default-v1-24-3 Local True Healthy True v1.24.3 5m31s
----
126 changes: 126 additions & 0 deletions modules/ossm-installing-istio-with-revisionbased-strategy.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,126 @@
// Module included in the following assemblies:

// update/ossm-updating-openshift-service-mesh.adoc

:_mod-docs-content-type: PROCEDURE
[id="installing-istio-with-revisionbased-strategy_{context}"]
= Installing Istio with RevisionBased strategy

You can install the {istio} control plane, {istio} CNI, and the Bookinfo demo application using the `RevisionBased` update strategy.

[NOTE]
====
You can use the following section to understand the update process. You can skip this installation if the cluster already includes an {istio} deployment.
====

.Procedure

. Create the `istio-system` namespace by running the following command:
+
[source,terminal]
----
$ oc create ns istio-system
----

. Deploy the {istio} control plane using the `RevisionBased` update strategy. The following example configuration creates an `{istio}` resource named `default` in the `istio-system` namespace:
+
.Example configuration
[source,yaml]
----
apiVersion: sailoperator.io/v1
kind: Istio
metadata:
name: default
spec:
namespace: istio-system
version: v1.24.3
updateStrategy:
type: RevisionBased
----

. Install the {istio} CNI plugin with the desired version. The following example configuration creates an `IstioCNI` resource named `default` in the `istio-cni` namespace:
+
.Example configuration
[source,yaml]
----
apiVersion: sailoperator.io/v1
kind: IstioCNI
metadata:
name: default
spec:
version: v1.24.3
namespace: istio-cni
----

. Get the `IstioRevision` name by running the following command:
+
[source,terminal]
----
$ oc get istiorevision -n istio-system
----
+
.Example output
[source,terminal]
----
NAME TYPE READY STATUS IN USE VERSION AGE
default-v1-24-3 Local True Healthy False v1.24.3 3m4s
----
+
The `IstioRevision` name is in the format `<istio_resource_name>-<version>`.

. Configure application workloads to run in the cluster. The following example deploys the `bookinfo` application in the `bookinfo` namespace:

.. Create the `bookinfo` namespace by running the following command:
+
[source,terminal]
----
$ oc create ns bookinfo
----

.. Label the `bookinfo` namespace to enable sidecar injection by running the following command:
+
[source,terminal]
----
$ oc label namespace bookinfo istio.io/rev=<revision_name>
----

.. Install the `bookinfo` pods in the `bookinfo` namespace by running the following command:
+
[source,terminal]
----
$ oc apply -f https://raw.githubusercontent.com/openshift-service-mesh/istio/release-1.24/samples/bookinfo/platform/kube/bookinfo.yaml -n bookinfo
----

. Review the `Istio` resource by running the following command:
+
[source,terminal]
----
$ oc get istio -n istio-system
----
+
.Example output
+
[source,terminal]
----
NAME REVISIONS READY IN USE ACTIVE REVISION STATUS VERSION AGE
default 1 1 1 default-v1-24-3 Healthy v1.24.3 5m13s
----
+
The `IN USE` field shows `1` after you deploy the application.

. Confirm that the proxy version matches the control plane version by running the following command:
+
[source,terminal]
----
$ istioctl proxy-status
----
+
The `VERSION` column should match the control plane version.
+
.Example output
+
[source,terminal]
----
NAME TYPE READY STATUS IN USE VERSION AGE
default-v1-24-3 Local True Healthy True v1.24.3 5m31s
----
Loading