Skip to content

Commit

Permalink
Update job config file. 3.x is 3.18, remove 3.15 latest is 3.17
Browse files Browse the repository at this point in the history
  • Loading branch information
SDawley committed Sep 30, 2024
1 parent 934ef60 commit 350e3c8
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 22 deletions.
2 changes: 1 addition & 1 deletion dependencies/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.17
3.18
Original file line number Diff line number Diff line change
@@ -1,13 +1,3 @@
#
# Copyright (c) 2018-2023 Red Hat, Inc.
# This program and the accompanying materials are made
# available under the terms of the Eclipse Public License 2.0
# which is available at https://www.eclipse.org/legal/epl-2.0/
#
# SPDX-License-Identifier: EPL-2.0
#
# Contributors:
# Red Hat, Inc. - initial API and implementation
apiVersion: template.openshift.io/v1
kind: Template
metadata:
Expand Down Expand Up @@ -117,9 +107,10 @@ parameters:
- name: IMAGE
value: registry.redhat.io/devspaces/pluginregistry-rhel8
displayName: Red Hat OpenShift Dev Spaces plugin registry image
description: Red Hat OpenShift Dev Spaces plugin registry container image. Defaults to registry.redhat.io/devspaces/pluginregistry-rhel8
description: Red Hat OpenShift Dev Spaces plugin registry container image. Defaults
to registry.redhat.io/devspaces/pluginregistry-rhel8
- name: IMAGE_TAG
value: '3.17'
value: '3.18'
displayName: Red Hat OpenShift Dev Spaces plugin registry version
description: Red Hat OpenShift Dev Spaces plugin registry version
- name: MEMORY_LIMIT
Expand Down
11 changes: 2 additions & 9 deletions product/updateVersionAndRegistryTags.sh
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ while [[ "$#" -gt 0 ]]; do
'-b') BRANCH="$2"; shift 1;;
'-w') WORKDIR="$2"; shift 1;;
'-v') VERBOSE=1; shift 0;;
'-nv'|'--no-version') doupdateversion=0; shift 0;;
'--no-version') doupdateversion=0; shift 0;;
'--remove') REMOVE_DEVSPACES_VERSION="$2"; shift 1;;
'--enable-jobs') ENABLE_JOBS_VERSION="$2"; shift 1;;
'--disable-jobs') DISABLE_JOBS_VERSION="$2"; shift 1;;
Expand Down Expand Up @@ -274,16 +274,9 @@ updatePluginRegistry() {
SCRIPT_DIR="${REG_ROOT}/build/scripts"
YAML_ROOT="${REG_ROOT}"
TEMPLATE_FILE="${REG_ROOT}/deploy/openshift/devspaces-plugin-registry.yaml"
for yaml in $("$SCRIPT_DIR"/list_che_yaml.sh "$YAML_ROOT"); do
sed -r \
-e "s#(.*image: (['\"]*)(registry.redhat.io|quay.io)/devspaces/.*:)[0-9.]+(['\"]*)#\1${DEVSPACES_VERSION}\2#g" \
-e "s#quay.io/devspaces/#registry.redhat.io/devspaces/#g" \
-e "s|# Copyright.*|# Copyright (c) 2018-$(date +%Y) Red Hat, Inc.|g" \
-i "${yaml}"
done

# update '.parameters[]|select(.name=="IMAGE_TAG")|.value' ==> 3.yy
yq -ri "(.parameters[] | select(.name == \"IMAGE_TAG\") | .value ) = \"${DEVSPACES_VERSION}\"" "${TEMPLATE_FILE}"
yq -yi "(.parameters[] | select(.name == \"IMAGE_TAG\") | .value ) = \"${DEVSPACES_VERSION}\"" "${TEMPLATE_FILE}"

git diff -q "${YAML_ROOT}" "${TEMPLATE_FILE}" || true
}
Expand Down

0 comments on commit 350e3c8

Please sign in to comment.