Replace references from master to main branches (#784)
Signed-off-by: Anatolii Bazko <abazko@redhat.com>pull/785/head
parent
5e41f3812a
commit
31b52f41eb
|
|
@ -12,7 +12,7 @@ All documentation about how to onboard components in Openshift CI can be found i
|
||||||
All Che operator jobs configurations are defined in `https://github.com/openshift/release/tree/master/ci-operator/config/eclipse-che/che-operator`.
|
All Che operator jobs configurations are defined in `https://github.com/openshift/release/tree/master/ci-operator/config/eclipse-che/che-operator`.
|
||||||
|
|
||||||
### Jobs
|
### Jobs
|
||||||
- `che-operator-update` - It tests Eclipse Che update from the latest Eclipse Che release version to a new version from the PR and workspace startup. Note this PR check runs against `master` branch and all `7.x.y` branches.
|
- `che-operator-update` - It tests Eclipse Che update from the latest Eclipse Che release version to a new version from the PR and workspace startup. Note this PR check runs against `main` branch and all `7.x.y` branches.
|
||||||
- `che-operator-olm-latest-changes-tests`- It tests Eclipse Che deployment and workspace startup.
|
- `che-operator-olm-latest-changes-tests`- It tests Eclipse Che deployment and workspace startup.
|
||||||
|
|
||||||
All Openshift CI checks name in pull request have a special nomenclature. Example: `ci/prow/v6-che-operator-update where` where `v6` is Openshift4 minor version.
|
All Openshift CI checks name in pull request have a special nomenclature. Example: `ci/prow/v6-che-operator-update where` where `v6` is Openshift4 minor version.
|
||||||
|
|
|
||||||
|
|
@ -30,8 +30,8 @@ che-operator Development Guide: https://github.com/eclipse-che/che-operator/#dev
|
||||||
- [ ] [Code produced is complete](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#code-produced-is-complete)
|
- [ ] [Code produced is complete](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#code-produced-is-complete)
|
||||||
- [ ] [Code builds without errors](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#code-builds-without-errors)
|
- [ ] [Code builds without errors](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#code-builds-without-errors)
|
||||||
- [ ] [Tests are covering the bugfix](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#tests-are-covering-the-bugfix)
|
- [ ] [Tests are covering the bugfix](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#tests-are-covering-the-bugfix)
|
||||||
- [ ] [Custom resource definition file is up to date](https://github.com/eclipse-che/che-operator/blob/master/README.md#updating-custom-resource-definition-file)
|
- [ ] [Custom resource definition file is up to date](https://github.com/eclipse-che/che-operator/blob/main/README.md#updating-custom-resource-definition-file)
|
||||||
- [ ] [Nightly OLM bundle is up to date](https://github.com/eclipse-che/che-operator/blob/master/README.md#update-nightly-olm-bundle)
|
- [ ] [Nightly OLM bundle is up to date](https://github.com/eclipse-che/che-operator/blob/main/README.md#update-nightly-olm-bundle)
|
||||||
- [ ] [The repository devfile is up to date and works](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#the-repository-devfile-is-up-to-date-and-works)
|
- [ ] [The repository devfile is up to date and works](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#the-repository-devfile-is-up-to-date-and-works)
|
||||||
- [ ] [Sections `What issues does this PR fix or reference` and `How to test this PR` completed](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#sections-what-issues-does-this-pr-fix-or-reference-and-how-to-test-this-pr-completed)
|
- [ ] [Sections `What issues does this PR fix or reference` and `How to test this PR` completed](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#sections-what-issues-does-this-pr-fix-or-reference-and-how-to-test-this-pr-completed)
|
||||||
- [ ] [Relevant user documentation updated](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#relevant-contributing-documentation-updated)
|
- [ ] [Relevant user documentation updated](https://github.com/eclipse/che/blob/master/CONTRIBUTING.md#relevant-contributing-documentation-updated)
|
||||||
|
|
|
||||||
|
|
@ -19,10 +19,10 @@ if [ -z "${ROOT_PROJECT_DIR}" ]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
CSV_KUBERNETES_NEW="deploy/olm-catalog/nightly/eclipse-che-preview-kubernetes/manifests/che-operator.clusterserviceversion.yaml"
|
CSV_KUBERNETES_NEW="deploy/olm-catalog/nightly/eclipse-che-preview-kubernetes/manifests/che-operator.clusterserviceversion.yaml"
|
||||||
CSV_KUBERNETES_CURRENT=https://raw.githubusercontent.com/eclipse-che/che-operator/master/deploy/olm-catalog/nightly/eclipse-che-preview-kubernetes/manifests/che-operator.clusterserviceversion.yaml
|
CSV_KUBERNETES_CURRENT=https://raw.githubusercontent.com/eclipse-che/che-operator/main/deploy/olm-catalog/nightly/eclipse-che-preview-kubernetes/manifests/che-operator.clusterserviceversion.yaml
|
||||||
|
|
||||||
CSV_OPENSHIFT_NEW="deploy/olm-catalog/nightly/eclipse-che-preview-openshift/manifests/che-operator.clusterserviceversion.yaml"
|
CSV_OPENSHIFT_NEW="deploy/olm-catalog/nightly/eclipse-che-preview-openshift/manifests/che-operator.clusterserviceversion.yaml"
|
||||||
CSV_OPENSHIFT_CURRENT=https://raw.githubusercontent.com/eclipse-che/che-operator/master/deploy/olm-catalog/nightly/eclipse-che-preview-openshift/manifests/che-operator.clusterserviceversion.yaml
|
CSV_OPENSHIFT_CURRENT=https://raw.githubusercontent.com/eclipse-che/che-operator/main/deploy/olm-catalog/nightly/eclipse-che-preview-openshift/manifests/che-operator.clusterserviceversion.yaml
|
||||||
|
|
||||||
checkNightlyBundleVersions() {
|
checkNightlyBundleVersions() {
|
||||||
git fetch -q
|
git fetch -q
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ on:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '0 21 * * *'
|
- cron: '0 21 * * *'
|
||||||
branches:
|
branches:
|
||||||
- master
|
- main
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
build-and-push-images:
|
build-and-push-images:
|
||||||
|
|
@ -37,7 +37,7 @@ jobs:
|
||||||
- name: Build catalog source and opm bundle images and push to registry
|
- name: Build catalog source and opm bundle images and push to registry
|
||||||
run: >
|
run: >
|
||||||
${GITHUB_WORKSPACE}/olm/buildAndPushBundleImages.sh -c 'nightly' -p 'openshift' &&
|
${GITHUB_WORKSPACE}/olm/buildAndPushBundleImages.sh -c 'nightly' -p 'openshift' &&
|
||||||
${GITHUB_WORKSPACE}/olm/buildAndPushBundleImages.sh -c 'nightly' -p 'kubernetes'
|
${GITHUB_WORKSPACE}/olm/buildAndPushBundleImages.sh -c 'nightly' -p 'kubernetes'
|
||||||
env:
|
env:
|
||||||
IMAGE_REGISTRY_HOST: quay.io
|
IMAGE_REGISTRY_HOST: quay.io
|
||||||
IMAGE_REGISTRY_USER_NAME: eclipse
|
IMAGE_REGISTRY_USER_NAME: eclipse
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ name: Check nightly OLM bundle
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- main
|
||||||
jobs:
|
jobs:
|
||||||
check-bundle-files:
|
check-bundle-files:
|
||||||
runs-on: ubuntu-20.04
|
runs-on: ubuntu-20.04
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ name: Minikube
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- main
|
||||||
jobs:
|
jobs:
|
||||||
minikube:
|
minikube:
|
||||||
name: Test Eclipse Che update from stable to nightly
|
name: Test Eclipse Che update from stable to nightly
|
||||||
|
|
|
||||||
|
|
@ -14,7 +14,7 @@ name: Minishift
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- main
|
||||||
jobs:
|
jobs:
|
||||||
minishift:
|
minishift:
|
||||||
name: Test Eclipse Che update from stable to nightly
|
name: Test Eclipse Che update from stable to nightly
|
||||||
|
|
|
||||||
|
|
@ -11,10 +11,10 @@ on:
|
||||||
forceflag:
|
forceflag:
|
||||||
description: 'To force creation of .x branch, use --force flag here'
|
description: 'To force creation of .x branch, use --force flag here'
|
||||||
default: ''
|
default: ''
|
||||||
# trigger on commit to master branch of new CSVs, eg., https://github.com/eclipse-che/che-operator/pull/571/files
|
# trigger on commit to main branch of new CSVs, eg., https://github.com/eclipse-che/che-operator/pull/571/files
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- main
|
||||||
paths:
|
paths:
|
||||||
- 'VERSION'
|
- 'VERSION'
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -11,10 +11,10 @@ on:
|
||||||
forceflag:
|
forceflag:
|
||||||
description: 'To force creation of .x branch, use --force flag here'
|
description: 'To force creation of .x branch, use --force flag here'
|
||||||
default: ''
|
default: ''
|
||||||
# trigger on commit to master branch of new CSVs, eg., https://github.com/eclipse-che/che-operator/pull/571/files
|
# trigger on commit to main branch of new CSVs, eg., https://github.com/eclipse-che/che-operator/pull/571/files
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- main
|
||||||
paths:
|
paths:
|
||||||
- 'VERSION'
|
- 'VERSION'
|
||||||
|
|
||||||
|
|
@ -48,7 +48,7 @@ jobs:
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# To determine DWO version, we have to replace first 7. with v0.
|
# To determine DWO version, we have to replace first 7. with v0.
|
||||||
# then major DWO version is behind upstream Che version by 26
|
# then major DWO version is behind upstream Che version by 26
|
||||||
# and the minor version is the same
|
# and the minor version is the same
|
||||||
# e.g 7.27.0 for Che = v0.1.0 for DWO
|
# e.g 7.27.0 for Che = v0.1.0 for DWO
|
||||||
chectlMajorMinorVersion=${chectlVersion#7.}
|
chectlMajorMinorVersion=${chectlVersion#7.}
|
||||||
|
|
@ -74,7 +74,7 @@ jobs:
|
||||||
|
|
||||||
IFS=',' read -ra paramMap <<< "${this_params}"
|
IFS=',' read -ra paramMap <<< "${this_params}"
|
||||||
for keyvalue in "${paramMap[@]}"
|
for keyvalue in "${paramMap[@]}"
|
||||||
do
|
do
|
||||||
key=${keyvalue%=*}
|
key=${keyvalue%=*}
|
||||||
value=${keyvalue#*=}
|
value=${keyvalue#*=}
|
||||||
echo $var1
|
echo $var1
|
||||||
|
|
|
||||||
|
|
@ -7,10 +7,10 @@ on:
|
||||||
forceflag:
|
forceflag:
|
||||||
description: 'To update an existing PR, use -f or --force flag here'
|
description: 'To update an existing PR, use -f or --force flag here'
|
||||||
default: ''
|
default: ''
|
||||||
# trigger on commit to master branch of new CSVs, eg., https://github.com/eclipse-che/che-operator/pull/571/files
|
# trigger on commit to main branch of new CSVs, eg., https://github.com/eclipse-che/che-operator/pull/571/files
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- main
|
||||||
paths:
|
paths:
|
||||||
- 'VERSION'
|
- 'VERSION'
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
# Che/CodeReady Workspaces Operator
|
# Che/CodeReady Workspaces Operator
|
||||||
|
|
||||||
[](https://codecov.io/gh/eclipse-che/che-operator)
|
[](https://codecov.io/gh/eclipse-che/che-operator)
|
||||||
|
|
||||||
Che/CodeReady workspaces operator uses [Operator SDK](https://github.com/operator-framework/operator-sdk) and [Go Kube client](https://github.com/kubernetes/client-go) to deploy, update and manage K8S/OpenShift resources that constitute a single or multi-user Eclipse Che/CodeReady Workspaces cluster.
|
Che/CodeReady workspaces operator uses [Operator SDK](https://github.com/operator-framework/operator-sdk) and [Go Kube client](https://github.com/kubernetes/client-go) to deploy, update and manage K8S/OpenShift resources that constitute a single or multi-user Eclipse Che/CodeReady Workspaces cluster.
|
||||||
|
|
||||||
|
|
@ -378,7 +378,7 @@ $ export NO_DATE_UPDATE="true" \
|
||||||
|
|
||||||
### Che operator PR checks
|
### Che operator PR checks
|
||||||
|
|
||||||
Documentation about all Che operator test cases can be found [here](https://github.com/eclipse-che/che-operator/tree/master/.ci/README.md)
|
Documentation about all Che operator test cases can be found [here](https://github.com/eclipse-che/che-operator/tree/main/.ci/README.md)
|
||||||
|
|
||||||
### Generate go mocks.
|
### Generate go mocks.
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -68,7 +68,7 @@ Validate that the release version is installed and workspace can be created:
|
||||||
|
|
||||||
## 4. Merge pull requests
|
## 4. Merge pull requests
|
||||||
|
|
||||||
Merge pull request into .x and master branches.
|
Merge pull request into .x and main branches.
|
||||||
|
|
||||||
## 5. Testing release on minishift (when chectl is released)
|
## 5. Testing release on minishift (when chectl is released)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ projects:
|
||||||
source:
|
source:
|
||||||
location: 'https://github.com/eclipse-che/che-operator.git'
|
location: 'https://github.com/eclipse-che/che-operator.git'
|
||||||
type: git
|
type: git
|
||||||
branch: master
|
branch: main
|
||||||
clonePath: src/github.com/eclipse-che/che-operator
|
clonePath: src/github.com/eclipse-che/che-operator
|
||||||
components:
|
components:
|
||||||
- id: golang/go/latest
|
- id: golang/go/latest
|
||||||
|
|
|
||||||
|
|
@ -27,7 +27,7 @@ init() {
|
||||||
RELEASE_DIR=$(cd "$(dirname "$0")"; pwd)
|
RELEASE_DIR=$(cd "$(dirname "$0")"; pwd)
|
||||||
FORCE_UPDATE=""
|
FORCE_UPDATE=""
|
||||||
BUILDX_PLATFORMS="linux/amd64,linux/ppc64le"
|
BUILDX_PLATFORMS="linux/amd64,linux/ppc64le"
|
||||||
DEV_WORKSPACE_CONTROLLER_VERSION="master"
|
DEV_WORKSPACE_CONTROLLER_VERSION="main"
|
||||||
DEV_WORKSPACE_CHE_OPERATOR_VERSION="main"
|
DEV_WORKSPACE_CHE_OPERATOR_VERSION="main"
|
||||||
|
|
||||||
if [[ $# -lt 1 ]]; then usage; exit; fi
|
if [[ $# -lt 1 ]]; then usage; exit; fi
|
||||||
|
|
@ -82,9 +82,9 @@ checkoutToReleaseBranch() {
|
||||||
echo "[INFO] $BRANCH exists."
|
echo "[INFO] $BRANCH exists."
|
||||||
resetChanges $BRANCH
|
resetChanges $BRANCH
|
||||||
else
|
else
|
||||||
echo "[INFO] $BRANCH does not exist. Will be created a new one from master."
|
echo "[INFO] $BRANCH does not exist. Will be created a new one from main."
|
||||||
resetChanges master
|
resetChanges main
|
||||||
git push origin master:$BRANCH
|
git push origin main:$BRANCH
|
||||||
fi
|
fi
|
||||||
git checkout -B $RELEASE_BRANCH
|
git checkout -B $RELEASE_BRANCH
|
||||||
}
|
}
|
||||||
|
|
@ -126,7 +126,6 @@ checkImageReferences() {
|
||||||
echo "[ERROR] Unable to find ubi8_minimal image in the $filename"; exit 1
|
echo "[ERROR] Unable to find ubi8_minimal image in the $filename"; exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# use ${RELEASE} instead of master
|
|
||||||
wget https://raw.githubusercontent.com/eclipse/che/${RELEASE}/assembly/assembly-wsmaster-war/src/main/webapp/WEB-INF/classes/che/che.properties -q -O /tmp/che.properties
|
wget https://raw.githubusercontent.com/eclipse/che/${RELEASE}/assembly/assembly-wsmaster-war/src/main/webapp/WEB-INF/classes/che/che.properties -q -O /tmp/che.properties
|
||||||
|
|
||||||
plugin_broker_meta_image=$(cat /tmp/che.properties | grep che.workspace.plugin_broker.metadata.image | cut -d '=' -f2)
|
plugin_broker_meta_image=$(cat /tmp/che.properties | grep che.workspace.plugin_broker.metadata.image | cut -d '=' -f2)
|
||||||
|
|
@ -240,20 +239,20 @@ createPRToXBranch() {
|
||||||
set -e
|
set -e
|
||||||
}
|
}
|
||||||
|
|
||||||
createPRToMasterBranch() {
|
createPRToMainBranch() {
|
||||||
echo "[INFO] createPRToMasterBranch :: Create pull request into master branch to copy csv"
|
echo "[INFO] createPRToMainBranch :: Create pull request into main branch to copy csv"
|
||||||
resetChanges master
|
resetChanges main
|
||||||
local tmpBranch="copy-csv-to-master"
|
local tmpBranch="copy-csv-to-main"
|
||||||
git checkout -B $tmpBranch
|
git checkout -B $tmpBranch
|
||||||
git diff refs/heads/${BRANCH}...refs/heads/${RELEASE_BRANCH} ':(exclude)deploy/operator.yaml' | git apply -3
|
git diff refs/heads/${BRANCH}...refs/heads/${RELEASE_BRANCH} ':(exclude)deploy/operator.yaml' | git apply -3
|
||||||
. ${RELEASE_DIR}/replace-images-tags.sh nightly master
|
. ${RELEASE_DIR}/replace-images-tags.sh nightly main
|
||||||
if git status --porcelain; then
|
if git status --porcelain; then
|
||||||
git add -A || true # add new generated CSV files in olm/ folder
|
git add -A || true # add new generated CSV files in olm/ folder
|
||||||
git commit -am "Copy "$RELEASE" csv to master" --signoff
|
git commit -am "Copy "$RELEASE" csv to main" --signoff
|
||||||
fi
|
fi
|
||||||
git push origin $tmpBranch -f
|
git push origin $tmpBranch -f
|
||||||
if [[ $FORCE_UPDATE == "--force" ]]; then set +e; fi # don't fail if PR already exists (just force push commits into it)
|
if [[ $FORCE_UPDATE == "--force" ]]; then set +e; fi # don't fail if PR already exists (just force push commits into it)
|
||||||
hub pull-request $FORCE_UPDATE --base master --head ${tmpBranch} -m "Copy "$RELEASE" csv to master"
|
hub pull-request $FORCE_UPDATE --base main --head ${tmpBranch} -m "Copy "$RELEASE" csv to main"
|
||||||
set -e
|
set -e
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -291,7 +290,7 @@ fi
|
||||||
|
|
||||||
if [[ $CREATE_PULL_REQUESTS == "true" ]]; then
|
if [[ $CREATE_PULL_REQUESTS == "true" ]]; then
|
||||||
createPRToXBranch
|
createPRToXBranch
|
||||||
createPRToMasterBranch
|
createPRToMainBranch
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ $PREPARE_COMMUNITY_OPERATORS_UPDATE == "true" ]]; then
|
if [[ $PREPARE_COMMUNITY_OPERATORS_UPDATE == "true" ]]; then
|
||||||
|
|
|
||||||
|
|
@ -5,9 +5,9 @@
|
||||||
defaultsFile=${0%/*}/defaults.go
|
defaultsFile=${0%/*}/defaults.go
|
||||||
|
|
||||||
if [[ ! -f ${defaultsFile} ]]; then
|
if [[ ! -f ${defaultsFile} ]]; then
|
||||||
echo "$defaultsFile not found, downloading from master..."
|
echo "$defaultsFile not found, downloading from main..."
|
||||||
defaultsFile="/tmp/defaults.go"
|
defaultsFile="/tmp/defaults.go"
|
||||||
curl -ssL https://raw.githubusercontent.com/eclipse-che/che-operator/master/pkg/deploy/defaults.go -o ${defaultsFile}
|
curl -ssL https://raw.githubusercontent.com/eclipse-che/che-operator/main/pkg/deploy/defaults.go -o ${defaultsFile}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
excludes="eclipse/che-keycloak|centos/postgresql-96-centos7"
|
excludes="eclipse/che-keycloak|centos/postgresql-96-centos7"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue