From e5309c5cbed0d5b01a62294586d25c973bd44150 Mon Sep 17 00:00:00 2001 From: Jeff Mesnil Date: Wed, 27 Nov 2024 13:31:04 +0100 Subject: [PATCH] Prepare the Helm Chart for EAP XP 6 Signed-off-by: Jeff Mesnil --- .github/labeler.yml | 6 ++-- .github/workflows/validation.yaml | 4 +-- README.md | 18 ++++++++++- charts/eap-xp5/templates/deployment.yaml | 10 ------- charts/eap-xp5/templates/service.yaml | 10 ------- charts/{eap-xp5 => eap-xp6}/.helmignore | 0 charts/{eap-xp5 => eap-xp6}/Chart.yaml | 8 ++--- charts/{eap-xp5 => eap-xp6}/README.md | 14 ++++----- .../{eap-xp5 => eap-xp6}/templates/NOTES.txt | 2 +- .../templates/_helpers.tpl | 30 +++++++++---------- .../templates/buildconfig-bootable-jar.yaml | 2 +- .../buildconfig-s2i-build-artifacts.yaml | 8 ++--- .../templates/buildconfig-s2i.yaml | 10 +++---- charts/eap-xp6/templates/deployment.yaml | 10 +++++++ .../templates/imagestream.yaml | 4 +-- .../{eap-xp5 => eap-xp6}/templates/route.yaml | 2 +- charts/eap-xp6/templates/service.yaml | 10 +++++++ .../{eap-xp5 => eap-xp6}/values.schema.json | 0 charts/{eap-xp5 => eap-xp6}/values.yaml | 7 +++-- examples/eap-xp5/getting-started/app.yaml | 3 -- .../getting-started/README.adoc | 22 +++++++------- examples/eap-xp6/getting-started/app.yaml | 3 ++ 22 files changed, 100 insertions(+), 83 deletions(-) delete mode 100644 charts/eap-xp5/templates/deployment.yaml delete mode 100644 charts/eap-xp5/templates/service.yaml rename charts/{eap-xp5 => eap-xp6}/.helmignore (100%) rename charts/{eap-xp5 => eap-xp6}/Chart.yaml (95%) rename charts/{eap-xp5 => eap-xp6}/README.md (94%) rename charts/{eap-xp5 => eap-xp6}/templates/NOTES.txt (87%) rename charts/{eap-xp5 => eap-xp6}/templates/_helpers.tpl (54%) rename charts/{eap-xp5 => eap-xp6}/templates/buildconfig-bootable-jar.yaml (83%) rename charts/{eap-xp5 => eap-xp6}/templates/buildconfig-s2i-build-artifacts.yaml (85%) rename charts/{eap-xp5 => eap-xp6}/templates/buildconfig-s2i.yaml (55%) create mode 100644 charts/eap-xp6/templates/deployment.yaml rename charts/{eap-xp5 => eap-xp6}/templates/imagestream.yaml (70%) rename charts/{eap-xp5 => eap-xp6}/templates/route.yaml (51%) create mode 100644 charts/eap-xp6/templates/service.yaml rename charts/{eap-xp5 => eap-xp6}/values.schema.json (100%) rename charts/{eap-xp5 => eap-xp6}/values.yaml (71%) delete mode 100644 examples/eap-xp5/getting-started/app.yaml rename examples/{eap-xp5 => eap-xp6}/getting-started/README.adoc (71%) create mode 100644 examples/eap-xp6/getting-started/app.yaml diff --git a/.github/labeler.yml b/.github/labeler.yml index 27193e4..ff0d099 100644 --- a/.github/labeler.yml +++ b/.github/labeler.yml @@ -4,9 +4,9 @@ examples: - examples/**/* charts: - charts/**/* -eap-xp5: - - charts/eap-xp5/**/* - - examples/eap-xp5/**/* +eap-xp6: + - charts/eap-xp6/**/* + - examples/eap-xp6/**/* documentation: - ./README.md - charts/**/README.md diff --git a/.github/workflows/validation.yaml b/.github/workflows/validation.yaml index e7ab039..fd2fe81 100644 --- a/.github/workflows/validation.yaml +++ b/.github/workflows/validation.yaml @@ -20,8 +20,8 @@ jobs: command: | shopt -s globstar echo "Check JSON schema" - cat charts/eap-xp5/values.schema.json | jq > /dev/null + cat charts/eap-xp6/values.schema.json | jq > /dev/null - echo "Check Yaml Examples" + echo "Check YAML Examples" shopt -s globstar yq eval-all 'true' examples/**/*.yaml > /dev/null \ No newline at end of file diff --git a/README.md b/README.md index 70751b1..d0ee028 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,21 @@ # eap-charts -Helm Charts for Red Hat JBoss Enterprise Application Platform XP 5 (JBoss EAP XP 5) +Helm Charts for Red Hat JBoss Enterprise Application Platform XP 6 (JBoss EAP XP 6) + +## Install Helm Repository for EAP Charts + +The `eap-xp6` Chart can be installed from the [https://jbossas.github.io/eap-charts/](https://jbossas.github.io/eap-charts/) repository + +``` +$ helm repo add jboss https://jbossas.github.io/eap-charts/ +"jboss" has been added to your repositories +$ helm search repo jboss +NAME CHART VERSION APP VERSION DESCRIPTION +jboss/eap-xp6 1.0.0 6.0 Build and deploy EAP XP 6 applications on OpenShift +```` + +## EAP XP 6 Charts docs + +* A complete documentation of the `eap81` Chart is available in [charts/eap-xp6/](./charts/eap-xp6/README.md). ## Prerequisites Below are prerequisites that may apply to your use case. diff --git a/charts/eap-xp5/templates/deployment.yaml b/charts/eap-xp5/templates/deployment.yaml deleted file mode 100644 index 10f77da..0000000 --- a/charts/eap-xp5/templates/deployment.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if .Values.deploy.enabled }} -{{- include "wildfly-common.deployment" (list . "eap-xp5.deployment") -}} -{{- end -}} - -{{ define "eap-xp5.deployment" }} -{{- include "eap-xp5.deployment.labels" . }} -spec: - template: - {{- include "eap-xp5.deployment.labels" . | nindent 4 }} -{{- end -}} \ No newline at end of file diff --git a/charts/eap-xp5/templates/service.yaml b/charts/eap-xp5/templates/service.yaml deleted file mode 100644 index 8e86753..0000000 --- a/charts/eap-xp5/templates/service.yaml +++ /dev/null @@ -1,10 +0,0 @@ -{{- if .Values.deploy.enabled }} -{{- include "wildfly-common.service.http" (list . "eap-xp5.metadata.labels") }} ---- -{{- include "wildfly-common.service.ping" (list . "eap-xp5.metadata.labels") }} ---- -{{- if .Values.deploy.tls.enabled }} -{{- include "wildfly-common.service.https" (list . "eap-xp5.metadata.labels") }} -{{- end }} ---- -{{- end -}} \ No newline at end of file diff --git a/charts/eap-xp5/.helmignore b/charts/eap-xp6/.helmignore similarity index 100% rename from charts/eap-xp5/.helmignore rename to charts/eap-xp6/.helmignore diff --git a/charts/eap-xp5/Chart.yaml b/charts/eap-xp6/Chart.yaml similarity index 95% rename from charts/eap-xp5/Chart.yaml rename to charts/eap-xp6/Chart.yaml index bd6def3..25bf57f 100644 --- a/charts/eap-xp5/Chart.yaml +++ b/charts/eap-xp6/Chart.yaml @@ -1,9 +1,9 @@ apiVersion: v2 -name: eap-xp5 -description: Build and Deploy JBoss EAP XP5 applications on OpenShift +name: eap-xp6 +description: Build and Deploy JBoss EAP XP 6 applications on OpenShift type: application version: 1.0.0 -appVersion: "5.0" +appVersion: "6.0" kubeVersion: ">= 1.19.0-0" home: https://www.redhat.com/en/technologies/jboss-middleware/application-platform @@ -14,7 +14,7 @@ maintainers: icon: data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCAxMDAgMTAwIj48ZGVmcz48c3R5bGU+LmNscy0xe2ZpbGw6I2Q3MWUwMDt9LmNscy0ye2ZpbGw6I2MyMWEwMDt9LmNscy0ze2ZpbGw6I2NkY2RjZDt9LmNscy00e2ZpbGw6I2I3YjdiNzt9LmNscy01e2ZpbGw6I2VhZWFlYTt9LmNscy02e2ZpbGw6I2ZmZjt9PC9zdHlsZT48L2RlZnM+PHRpdGxlPkxvZ288L3RpdGxlPjxnIGlkPSJMYXllcl8xIiBkYXRhLW5hbWU9IkxheWVyIDEiPjxjaXJjbGUgY2xhc3M9ImNscy0xIiBjeD0iNTAiIGN5PSI1MCIgcj0iNTAiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMC43MSA1MCkgcm90YXRlKC00NSkiLz48cGF0aCBjbGFzcz0iY2xzLTIiIGQ9Ik04NS4zNiwxNC42NEE1MCw1MCwwLDAsMSwxNC42NCw4NS4zNloiLz48cGF0aCBjbGFzcz0iY2xzLTMiIGQ9Ik02MC4xNyw0My4xM2EzLjQxLDMuNDEsMCwwLDEsLjA3LjY4QTMuNCwzLjQsMCwwLDAsNjAuMTcsNDMuMTNaIi8+PHBhdGggY2xhc3M9ImNscy0zIiBkPSJNNTkuMjEsNDEuMzhBMy40OCwzLjQ4LDAsMCwxLDYwLDQyLjQ3LDMuNDgsMy40OCwwLDAsMCw1OS4yMSw0MS4zOFoiLz48cG9seWdvbiBjbGFzcz0iY2xzLTMiIHBvaW50cz0iNTkuMTMgNDEuMjkgNTkuMTMgNDEuMjkgNTkuMDQgNDEuMjEgNTkuMTMgNDEuMjkiLz48cGF0aCBjbGFzcz0iY2xzLTMiIGQ9Ik01OS4xMiw0Ni4zNCwzMy41NCw2OS43M2wyNS41OC0yMy40YTMuNDUsMy40NSwwLDAsMCwuOTEtMS40QTMuNDUsMy40NSwwLDAsMSw1OS4xMiw0Ni4zNFoiLz48cGF0aCBjbGFzcz0iY2xzLTMiIGQ9Ik0yOC41NCw3MS40OCw1OC44Nyw0MSw1OC43OSw0MWEzLjcsMy43LDAsMCwwLTUuMjEuMkwyOSw2OC4yNmMtMSwxLTEuMTksMi41Mi0uMzUsMy4zMWExLjc1LDEuNzUsMCwwLDAsLjc0LjQxLDEuNzUsMS43NSwwLDAsMS0uNzQtLjQxWiIvPjxwYXRoIGNsYXNzPSJjbHMtNCIgZD0iTTI4LjYyLDcxLjU3QTIuNTIsMi41MiwwLDAsMCwzMiw3MS4xMUw1OS4xMiw0Ni4zNGEzLjQyLDMuNDIsMCwwLDAsMC01TDU4Ljg3LDQxLDI4LjU0LDcxLjQ4WiIvPjxwYXRoIGNsYXNzPSJjbHMtNSIgZD0iTTM0LjQ2LDM0LjcxbC0xMC42LTguNDNhMi42LDIuNiwwLDAsMC00LjIsMi4zM2wuMTksMS42NGExOC4yMSwxOC4yMSwwLDAsMCwxMS42OSwxNWwxMy42OSw1LjE0LDIuMzEtMi41NUwzNi4xNiwzNi43M0ExNi40NSwxNi40NSwwLDAsMSwzNC40NiwzNC43MVoiLz48cGF0aCBjbGFzcz0iY2xzLTUiIGQ9Ik03NC42OSw3NS40MSw2NS44OCw2NS4xMmExNi40NSwxNi40NSwwLDAsMS0yLjA4LTEuNjNMNTIuMzMsNTIuNTVsLTIuNTIsMi4zLDUuNjcsMTMuNThBMTguMjEsMTguMjEsMCwwLDAsNzAuODcsNzkuNTZsMS42NC4xM0EyLjYsMi42LDAsMCwwLDc0LjY5LDc1LjQxWiIvPjxwYXRoIGNsYXNzPSJjbHMtNSIgZD0iTTU4LjY0LDQ2Ljc4YTMsMywwLDAsMCwzLjg1LTIuMTcsMy4yOCwzLjI4LDAsMCwwLTMtNC4xNWgwbC0uNTkuNTloMGwuMjYuMjVhMy40MiwzLjQyLDAsMCwxLDAsNVoiLz48cGF0aCBjbGFzcz0iY2xzLTYiIGQ9Ik0zMi43NywxNy4xOGwtLjUsMS41M2ExNy42LDE3LjYsMCwwLDAsMy44OSwxOEw0Ny41Myw0Ny44MmwzLjYxLTQtMTMuNy0yN0EyLjU0LDIuNTQsMCwwLDAsMzIuNzcsMTcuMThaIi8+PHBhdGggY2xhc3M9ImNscy02IiBkPSJNODMuNjUsNjEuNDgsNTYuMzUsNDguODdsLTQsMy42OEw2My44LDYzLjQ5YTE3LjYsMTcuNiwwLDAsMCwxOC4xNSwzLjIzbDEuNTEtLjU1QTIuNTQsMi41NCwwLDAsMCw4My42NSw2MS40OFoiLz48cGF0aCBjbGFzcz0iY2xzLTYiIGQ9Ik01My41OCw0MS4xN2EzLjcsMy43LDAsMCwxLDUuMjEtLjJsLjA4LjA4aDBsLjU5LS41OWgwYTMuNDEsMy40MSwwLDAsMC00LjI5LTIuOTNjLTIsLjM4LTMuMDcsMi42OC0yLDQuMTFaIi8+PC9nPjwvc3ZnPg== annotations: - charts.openshift.io/name: JBoss EAP XP5 + charts.openshift.io/name: JBoss EAP XP 6 charts.openshift.io/supportURL: https://access.redhat.com/support charts.openshift.io/provider: Red Hat diff --git a/charts/eap-xp5/README.md b/charts/eap-xp6/README.md similarity index 94% rename from charts/eap-xp5/README.md rename to charts/eap-xp6/README.md index 91da172..9ffa863 100644 --- a/charts/eap-xp5/README.md +++ b/charts/eap-xp6/README.md @@ -1,6 +1,6 @@ -# Helm Chart for JBoss EAP XP 5 +# Helm Chart for JBoss EAP XP 6 -A Helm chart for building and deploying a [JBoss EAP XP 5](https://www.redhat.com/en/technologies/jboss-middleware/application-platform) application on OpenShift. +A Helm chart for building and deploying a [JBoss EAP XP 6](https://www.redhat.com/en/technologies/jboss-middleware/application-platform) application on OpenShift. ## Building and Deploying Applications @@ -125,7 +125,7 @@ If the application image has been built by another mechanism, you can skip the b | `build.enabled` | Determines if build-related resources should be created. | `true` | Set this to `false` if you want to deploy a previously built image. Leave this set to `true` if you want to build and deploy a new image. | | `build.env` | Freeform `env` items | - | [Kubernetes documentation](https://kubernetes.io/docs/tasks/inject-data-application/define-environment-variable-container/). These environment variables will be used when the application is _built_. If you need to specify environment variables for the running application, use `deploy.env` instead. | | `build.images`| Freeform images injected in the source during S2I build | - | [OKD API documentation](https://docs.okd.io/latest/rest_api/workloads_apis/buildconfig-build-openshift-io-v1.html#spec-source-images-2) | -| `build.mode` | Determines the mode to build the application image with EAP XP 5 | `bootable-jar` | Allowed values: `s2i, bootable-jar` | +| `build.mode` | Determines the mode to build the application image with EAP XP 6 | `bootable-jar` | Allowed values: `s2i, bootable-jar` | | `build.output.kind`| Determines if the image will be pushed to an `ImageStreamTag` or a `DockerImage` | `ImageStreamTag` | [OKD API documentation](https://docs.okd.io/latest/rest_api/workloads_apis/buildconfig-build-openshift-io-v1.html#spec-output) | | `build.output.pushSecret` | Name of the push secret | - | The secret must exist in the same namespace or the chart will fail to install - Used only if `build.output.kind` is `DockerImage` | | `build.pullSecret` | Name of the pull secret | - | The secret must exist in the same namespace or the chart will fail to install - [OKD API documentation](https://docs.okd.io/latest/rest_api/workloads_apis/buildconfig-build-openshift-io-v1.html#spec-strategy-sourcestrategy) | @@ -139,8 +139,8 @@ If the application image has been built by another mechanism, you can skip the b | `build.s2i.featurePacks` | List of additional Galleon feature-packs identified by Maven coordinates (`::`) | - | The value can be be either a `string` with a list of comma-separated Maven coordinate or an array where each item is the Maven coordinate of a feature pack - [EAP Documentation](https://access.redhat.com/documentation/en-us/red_hat_jboss_enterprise_application_platform/7.4/html/getting_started_with_jboss_eap_for_openshift_container_platform/index) | | `build.s2i.channels` | List of Channels identified by Maven coordinates (`:`). If featurePacks are configured without any versioning, the channels that provides the latest feature packs can be specified. Deprecated, the recommended way to provision EAP is to use the eap-maven-plugin in the application pom.xml | - | The value can be be either a `string` with a list of comma-separated Maven coordinate or an array where each item is the Maven coordinate of a channel - [EAP Documentation](https://access.redhat.com/documentation/en-us/red_hat_jboss_enterprise_application_platform/7.4/html/getting_started_with_jboss_eap_for_openshift_container_platform/index) | | `build.s2i.jdk` | JDK Version of the EAP S2I images | `"17"` | Allowed Values: `"17"` | -| `build.s2i.jdk17.builderImage` | EAP S2I Builder image for JDK 17 | `registry.redhat.io/jboss-eap-8/eap8-openjdk17-builder-openshift-rhel8:latest` | [EAP Documentation](https://access.redhat.com/documentation/en-us/red_hat_jboss_enterprise_application_platform/8.0/html/getting_started_with_jboss_eap_for_openshift_container_platform/index) | -| `build.s2i.jdk17.runtimeImage` | EAP S2I Runtime image for JDK 17| `registry.redhat.io/jboss-eap-8/eap8-openjdk17-runtime-openshift-rhel8:latest` | [EAP Documentation](https://access.redhat.com/documentation/en-us/red_hat_jboss_enterprise_application_platform/8.0/html/getting_started_with_jboss_eap_for_openshift_container_platform/index) | +| `build.s2i.jdk17.builderImage` | EAP S2I Builder image for JDK 17 | `registry.redhat.io/jboss-eap-8-tech-preview/eap81-openjdk17-builder-openshift-rhel9:latest` | [EAP Documentation](https://access.redhat.com/documentation/en-us/red_hat_jboss_enterprise_application_platform/8.0/html/getting_started_with_jboss_eap_for_openshift_container_platform/index) | +| `build.s2i.jdk17.runtimeImage` | EAP S2I Runtime image for JDK 17| `registry.redhat.io/jboss-eap-8-tech-preview/eap8-openjdk17-runtime-openshift-rhel9:latest` | [EAP Documentation](https://access.redhat.com/documentation/en-us/red_hat_jboss_enterprise_application_platform/8.0/html/getting_started_with_jboss_eap_for_openshift_container_platform/index) | | `build.s2i.kind` | Determines the type of images for S2I Builder and Runtime images (`DockerImage`, `ImageStreamTag` or `ImageStreamImage`) | `DockerImage` | [OKD Documentation](https://docs.okd.io/latest/cicd/builds/build-strategies.html#builds-strategy-s2i-build_build-strategies) | | `build.s2i.runtimeKind` | Determines the type of images for S2I Runtime image (`DockerImage`, `ImageStreamTag` or `ImageStreamImage`) | the value of `build.s2i.kind` | [OKD Documentation](https://docs.okd.io/latest/cicd/)| | `build.sourceSecret`|Name of the secret containing the credentials to login to Git source reposiory | - | The secret must exist in the same namespace or the chart will fail to install - [OKD documentation](https://docs.okd.io/latest/cicd/builds/creating-build-inputs.html#builds-manually-add-source-clone-secrets_creating-build-inputs) | @@ -150,12 +150,12 @@ If the application image has been built by another mechanism, you can skip the b ### Provisioning Jboss EAP With S2I. -The recommended way to provision the JBoss EAP XP5 server is to use the `eap-maven-plugin` from the application `pom.xml`. +The recommended way to provision the JBoss EAP XP 6 server is to use the `eap-maven-plugin` from the application `pom.xml`. The `build.s2i.featurePacks`,`build.s2i.galleonLayers`and `build.s2i.channels` fields have been deprecated as they are no longer necessary with this recommendation. For backwards compatibility, the EAP S2I Builder image still supports these fields to delegate to the provisioning of the server to the `eap-maven-plugin` if it is not configured in the application `pom.xml`. -However if `build.s2i.galleonLayers` is set, `build.s2i.featurePacks` _must_ be specified (including EAP XP5 feature pack `org.jboss.eap.xp:wildfly-galleon-pack`). +However if `build.s2i.galleonLayers` is set, `build.s2i.featurePacks` _must_ be specified (including EAP XP 6 feature pack `org.jboss.eap.xp:wildfly-galleon-pack`). ## Deploying the Application Image diff --git a/charts/eap-xp5/templates/NOTES.txt b/charts/eap-xp6/templates/NOTES.txt similarity index 87% rename from charts/eap-xp5/templates/NOTES.txt rename to charts/eap-xp6/templates/NOTES.txt index 99c2048..01a73b4 100644 --- a/charts/eap-xp5/templates/NOTES.txt +++ b/charts/eap-xp6/templates/NOTES.txt @@ -1,7 +1,7 @@ {{- if .Release.IsInstall }} {{- if .Values.build.enabled }} -Your EAP XP 5 application is building! To follow the build, run: +Your EAP XP 6 application is building! To follow the build, run: $ oc get build -w diff --git a/charts/eap-xp5/templates/_helpers.tpl b/charts/eap-xp6/templates/_helpers.tpl similarity index 54% rename from charts/eap-xp5/templates/_helpers.tpl rename to charts/eap-xp6/templates/_helpers.tpl index 9664f7a..53a145c 100644 --- a/charts/eap-xp5/templates/_helpers.tpl +++ b/charts/eap-xp6/templates/_helpers.tpl @@ -1,55 +1,55 @@ {{/* -eap-xp5.eapBuilderImage corresponds to the imagestream for the EAP S2I Builder image. +eap-xp.eapBuilderImage corresponds to the imagestream for the EAP S2I Builder image. It depends on the build.s2i.jdk version. */}} -{{- define "eap-xp5.eapBuilderImage" -}} +{{- define "eap-xp.eapBuilderImage" -}} {{ .Values.build.s2i.jdk17.builderImage}} {{- end -}} {{/* -eap-xp5.eapRuntimeImage corresponds to the imagestream for the EAP S2I Runtime image. +eap-xp.eapRuntimeImage corresponds to the imagestream for the EAP S2I Runtime image. It depends on the build.s2i.jdkVersion. */}} -{{- define "eap-xp5.eapRuntimeImage" -}} +{{- define "eap-xp.eapRuntimeImage" -}} {{ .Values.build.s2i.jdk17.runtimeImage}} {{- end -}} {{/* Create chart name and version as used by the chart label. */}} -{{- define "eap-xp5.chart" -}} +{{- define "eap-xp.chart" -}} {{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }} {{- end }} -{{- define "eap-xp5.labels" -}} -helm.sh/chart: {{ include "eap-xp5.chart" . }} +{{- define "eap-xp.labels" -}} +helm.sh/chart: {{ include "eap-xp.chart" . }} {{ include "wildfly-common.selectorLabels" . }} app.kubernetes.io/managed-by: {{ .Release.Service }} app.openshift.io/runtime: eap {{- end }} -{{- define "eap-xp5.metering.labels" -}} +{{- define "eap-xp.metering.labels" -}} com.company: "Red_Hat" rht.prod_name: "Red_Hat_Runtimes" -rht.prod_ver: "2024-Q1" +rht.prod_ver: "2025-Q1" rht.comp: "EAP_XP" rht.comp_ver: {{ quote .Chart.AppVersion }} rht.subcomp_t: "application" {{- end }} -{{- define "eap-xp5.metadata.labels" -}} +{{- define "eap-xp.metadata.labels" -}} metadata: labels: - {{- include "eap-xp5.labels" . | nindent 4 }} - {{- include "eap-xp5.metering.labels" . | nindent 4 }} + {{- include "eap-xp.labels" . | nindent 4 }} + {{- include "eap-xp.metering.labels" . | nindent 4 }} {{- end -}} -{{- define "eap-xp5.deployment.labels" -}} +{{- define "eap-xp.deployment.labels" -}} metadata: labels: - {{- include "eap-xp5.labels" . | nindent 4 }} - {{- include "eap-xp5.metering.labels" . | nindent 4 }} + {{- include "eap-xp.labels" . | nindent 4 }} + {{- include "eap-xp.metering.labels" . | nindent 4 }} {{- if .Values.deploy.labels }} {{- tpl (toYaml .Values.deploy.labels) . | nindent 4 }} {{- end -}} diff --git a/charts/eap-xp5/templates/buildconfig-bootable-jar.yaml b/charts/eap-xp6/templates/buildconfig-bootable-jar.yaml similarity index 83% rename from charts/eap-xp5/templates/buildconfig-bootable-jar.yaml rename to charts/eap-xp6/templates/buildconfig-bootable-jar.yaml index 7c19652..343ecbd 100644 --- a/charts/eap-xp5/templates/buildconfig-bootable-jar.yaml +++ b/charts/eap-xp6/templates/buildconfig-bootable-jar.yaml @@ -1,3 +1,3 @@ {{- if and .Values.build.enabled (eq .Values.build.mode "bootable-jar") }} -{{- include "wildfly-common.buildconfig-bootable-jar" (list . "eap-xp5.metadata.labels") -}} +{{- include "wildfly-common.buildconfig-bootable-jar" (list . "eap-xp.metadata.labels") -}} {{- end }} \ No newline at end of file diff --git a/charts/eap-xp5/templates/buildconfig-s2i-build-artifacts.yaml b/charts/eap-xp6/templates/buildconfig-s2i-build-artifacts.yaml similarity index 85% rename from charts/eap-xp5/templates/buildconfig-s2i-build-artifacts.yaml rename to charts/eap-xp6/templates/buildconfig-s2i-build-artifacts.yaml index f348acb..f629c63 100644 --- a/charts/eap-xp5/templates/buildconfig-s2i-build-artifacts.yaml +++ b/charts/eap-xp6/templates/buildconfig-s2i-build-artifacts.yaml @@ -1,15 +1,15 @@ {{- if and .Values.build.enabled (eq .Values.build.mode "s2i") }} -{{- include "wildfly-common.buildconfig-s2i-build-artifacts" (list . "eap-xp5.buildconfig-s2i-build-artifacts") -}} +{{- include "wildfly-common.buildconfig-s2i-build-artifacts" (list . "eap-xp.buildconfig-s2i-build-artifacts") -}} {{- end -}} -{{- define "eap-xp5.buildconfig-s2i-build-artifacts" -}} -{{ include "eap-xp5.metadata.labels" . }} +{{- define "eap-xp.buildconfig-s2i-build-artifacts" -}} +{{ include "eap-xp.metadata.labels" . }} spec: strategy: sourceStrategy: from: kind: {{ .Values.build.s2i.builderKind | default .Values.build.s2i.kind }} - name: {{ include "eap-xp5.eapBuilderImage" . }} + name: {{ include "eap-xp.eapBuilderImage" . }} env: - name: CUSTOM_INSTALL_DIRECTORIES value: extensions diff --git a/charts/eap-xp5/templates/buildconfig-s2i.yaml b/charts/eap-xp6/templates/buildconfig-s2i.yaml similarity index 55% rename from charts/eap-xp5/templates/buildconfig-s2i.yaml rename to charts/eap-xp6/templates/buildconfig-s2i.yaml index 7ac4401..773f278 100644 --- a/charts/eap-xp5/templates/buildconfig-s2i.yaml +++ b/charts/eap-xp6/templates/buildconfig-s2i.yaml @@ -1,18 +1,18 @@ {{- if and .Values.build.enabled (eq .Values.build.mode "s2i") }} -{{- include "wildfly-common.buildconfig-s2i" (list . "eap-xp5.buildconfig-s2i") -}} +{{- include "wildfly-common.buildconfig-s2i" (list . "eap-xp.buildconfig-s2i") -}} {{- end -}} -{{- define "eap-xp5.buildconfig-s2i" -}} -{{ include "eap-xp5.metadata.labels" . }} +{{- define "eap-xp.buildconfig-s2i" -}} +{{ include "eap-xp.metadata.labels" . }} spec: source: dockerfile: |- - FROM {{ include "eap-xp5.eapRuntimeImage" . }} + FROM {{ include "eap-xp.eapRuntimeImage" . }} COPY --chown=jboss:root /server $JBOSS_HOME RUN chmod -R ug+rwX $JBOSS_HOME strategy: dockerStrategy: from: kind: {{ .Values.build.s2i.runtimeKind | default .Values.build.s2i.kind }} - name: {{ include "eap-xp5.eapRuntimeImage" .}} + name: {{ include "eap-xp.eapRuntimeImage" .}} {{- end -}} \ No newline at end of file diff --git a/charts/eap-xp6/templates/deployment.yaml b/charts/eap-xp6/templates/deployment.yaml new file mode 100644 index 0000000..b9fa969 --- /dev/null +++ b/charts/eap-xp6/templates/deployment.yaml @@ -0,0 +1,10 @@ +{{- if .Values.deploy.enabled }} +{{- include "wildfly-common.deployment" (list . "eap-xp.deployment") -}} +{{- end -}} + +{{ define "eap-xp.deployment" }} +{{- include "eap-xp.deployment.labels" . }} +spec: + template: + {{- include "eap-xp.deployment.labels" . | nindent 4 }} +{{- end -}} \ No newline at end of file diff --git a/charts/eap-xp5/templates/imagestream.yaml b/charts/eap-xp6/templates/imagestream.yaml similarity index 70% rename from charts/eap-xp5/templates/imagestream.yaml rename to charts/eap-xp6/templates/imagestream.yaml index 593c5ea..0f27f72 100644 --- a/charts/eap-xp5/templates/imagestream.yaml +++ b/charts/eap-xp6/templates/imagestream.yaml @@ -1,11 +1,11 @@ {{- if and .Values.build.enabled (eq .Values.build.output.kind "ImageStreamTag") -}} {{- if .Values.build.s2i.buildApplicationImage -}} -{{- include "wildfly-common.imagestream" (list . "eap-xp5.metadata.labels") }} +{{- include "wildfly-common.imagestream" (list . "eap-xp.metadata.labels") }} {{- end -}} {{- if eq .Values.build.mode "s2i" }} --- -{{- include "wildfly-common.imagestream-s2i-build-artifacts" (list . "eap-xp5.metadata.labels") }} +{{- include "wildfly-common.imagestream-s2i-build-artifacts" (list . "eap-xp.metadata.labels") }} {{- end -}} {{- end -}} \ No newline at end of file diff --git a/charts/eap-xp5/templates/route.yaml b/charts/eap-xp6/templates/route.yaml similarity index 51% rename from charts/eap-xp5/templates/route.yaml rename to charts/eap-xp6/templates/route.yaml index d3e58a4..24f4f77 100644 --- a/charts/eap-xp5/templates/route.yaml +++ b/charts/eap-xp6/templates/route.yaml @@ -1,3 +1,3 @@ {{- if (and .Values.deploy.enabled .Values.deploy.route.enabled) }} -{{- include "wildfly-common.route" (list . "eap-xp5.metadata.labels") -}} +{{- include "wildfly-common.route" (list . "eap-xp.metadata.labels") -}} {{- end -}} \ No newline at end of file diff --git a/charts/eap-xp6/templates/service.yaml b/charts/eap-xp6/templates/service.yaml new file mode 100644 index 0000000..e5931b8 --- /dev/null +++ b/charts/eap-xp6/templates/service.yaml @@ -0,0 +1,10 @@ +{{- if .Values.deploy.enabled }} +{{- include "wildfly-common.service.http" (list . "eap-xp.metadata.labels") }} +--- +{{- include "wildfly-common.service.ping" (list . "eap-xp.metadata.labels") }} +--- +{{- if .Values.deploy.tls.enabled }} +{{- include "wildfly-common.service.https" (list . "eap-xp.metadata.labels") }} +{{- end }} +--- +{{- end -}} \ No newline at end of file diff --git a/charts/eap-xp5/values.schema.json b/charts/eap-xp6/values.schema.json similarity index 100% rename from charts/eap-xp5/values.schema.json rename to charts/eap-xp6/values.schema.json diff --git a/charts/eap-xp5/values.yaml b/charts/eap-xp6/values.yaml similarity index 71% rename from charts/eap-xp5/values.yaml rename to charts/eap-xp6/values.yaml index 3d2c1eb..766ff79 100644 --- a/charts/eap-xp5/values.yaml +++ b/charts/eap-xp6/values.yaml @@ -1,10 +1,11 @@ -# Default values for JBoss EAP XP 5 +# Default values for JBoss EAP XP 6 # This is a YAML-formatted file. # Declare variables to be passed into your templates. image: tag: latest build: enabled: true + uri: https://github.com/jboss-eap-up-and-running/eap-xp6-getting-started.git mode: bootable-jar bootableJar: builderImage: registry.access.redhat.com/ubi8/openjdk-17:latest @@ -13,8 +14,8 @@ build: kind: DockerImage jdk: "17" jdk17: - builderImage: registry.redhat.io/jboss-eap-8/eap8-openjdk17-builder-openshift-rhel8:latest - runtimeImage: registry.redhat.io/jboss-eap-8/eap8-openjdk17-runtime-openshift-rhel8:latest + builderImage: registry.redhat.io/jboss-eap-8-tech-preview/eap81-openjdk17-builder-openshift-rhel9:latest + runtimeImage: registry.redhat.io/jboss-eap-8-tech-preview/eap81-openjdk17-runtime-openshift-rhel9:latest output: kind: "ImageStreamTag" triggers: {} diff --git a/examples/eap-xp5/getting-started/app.yaml b/examples/eap-xp5/getting-started/app.yaml deleted file mode 100644 index 78428e3..0000000 --- a/examples/eap-xp5/getting-started/app.yaml +++ /dev/null @@ -1,3 +0,0 @@ -build: - uri: https://github.com/jboss-eap-up-and-running/eap-xp5-getting-started.git - mode: bootable-jar diff --git a/examples/eap-xp5/getting-started/README.adoc b/examples/eap-xp6/getting-started/README.adoc similarity index 71% rename from examples/eap-xp5/getting-started/README.adoc rename to examples/eap-xp6/getting-started/README.adoc index b936bb5..3cbc105 100644 --- a/examples/eap-xp5/getting-started/README.adoc +++ b/examples/eap-xp6/getting-started/README.adoc @@ -5,13 +5,13 @@ :idseparator: - :keywords: openshift,wildfly,microprofile,helm -This example shows how to deploy a Java application with EAP XP 5 on OpenShift. +This example shows how to deploy a Java application with EAP XP 6 on OpenShift. ## Prerequisites ## Source Code -The source code for the backend is hosted at https://github.com/jboss-eap-up-and-running/eap-xp5-getting-started.git +The source code for the backend is hosted at https://github.com/jboss-eap-up-and-running/eap-xp6-getting-started.git It is a simple application that uses JAX-RS to exposes HTTP endpoint. @@ -26,7 +26,7 @@ In that case, the Helm Chart is configured with `build.mode=bootable-jar`. [source,options="nowrap"] ---- -$ helm install eap-xp5-app -f examples/eap-xp5/getting-started/app.yaml ./charts/eap-xp5 +$ helm install eap-xp6-app -f examples/eap-xp6/getting-started/app.yaml ./charts/eap-xp6 ---- ## Deployment @@ -35,22 +35,22 @@ Once the chart is installed, let's wait for the application to be built and depl [source,options="nowrap"] ---- -$ oc get deployment/eap-xp5-app -w +$ oc get deployment/eap-xp6-app -w NAME READY UP-TO-DATE AVAILABLE AGE -eap-xp5-app 0/1 1 0 27s +eap-xp6-app 0/1 1 0 27s ... -eap-xp5-app 1/1 1 1 5m29s +eap-xp6-app 1/1 1 1 5m29s ---- ## Use the application -Once the application is deployed on OpenShift, it can be accessed from the route `eap-xp5-app`. +Once the application is deployed on OpenShift, it can be accessed from the route `eap-xp6-app`. Let's find the host that we can use to connect to this backend: [source,options="nowrap"] ---- -$ oc get route eap-xp5-app -o jsonpath="{.spec.host}" -eap-xp5-app-jmesnil1-dev.apps.sandbox.x8i5.p1.openshiftapps.com +$ oc get route eap-xp6-app -o jsonpath="{.spec.host}" +eap-xp6-app-jmesnil1-dev.apps.sandbox.x8i5.p1.openshiftapps.com ---- This value will be different for every installation of the application. @@ -63,6 +63,6 @@ The application can be deleted by running the command: [source,options="nowrap"] ---- -$ helm delete eap-xp5-app -release "eap-xp5-app " uninstalled +$ helm delete eap-xp6-app +release "eap-xp6-app " uninstalled ---- diff --git a/examples/eap-xp6/getting-started/app.yaml b/examples/eap-xp6/getting-started/app.yaml new file mode 100644 index 0000000..4577241 --- /dev/null +++ b/examples/eap-xp6/getting-started/app.yaml @@ -0,0 +1,3 @@ +build: + uri: https://github.com/jboss-eap-up-and-running/eap-xp6-getting-started.git + mode: bootable-jar