Replace references from master to main branches (#784)

Signed-off-by: Anatolii Bazko <abazko@redhat.com>
pull/785/head
Anatolii Bazko 2021-04-16 12:22:39 +03:00 committed by GitHub
parent 5e41f3812a
commit 31b52f41eb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
15 changed files with 36 additions and 37 deletions

View File

@ -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`.
### 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.
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.

View File

@ -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 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)
- [ ] [Custom resource definition file is up to date](https://github.com/eclipse-che/che-operator/blob/master/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)
- [ ] [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/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)
- [ ] [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)

View File

@ -19,10 +19,10 @@ if [ -z "${ROOT_PROJECT_DIR}" ]; then
fi
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_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() {
git fetch -q

View File

@ -14,7 +14,7 @@ on:
schedule:
- cron: '0 21 * * *'
branches:
- master
- main
jobs:
build-and-push-images:
@ -37,7 +37,7 @@ jobs:
- name: Build catalog source and opm bundle images and push to registry
run: >
${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:
IMAGE_REGISTRY_HOST: quay.io
IMAGE_REGISTRY_USER_NAME: eclipse

View File

@ -14,7 +14,7 @@ name: Check nightly OLM bundle
on:
pull_request:
branches:
- master
- main
jobs:
check-bundle-files:
runs-on: ubuntu-20.04

View File

@ -14,7 +14,7 @@ name: Minikube
on:
pull_request:
branches:
- master
- main
jobs:
minikube:
name: Test Eclipse Che update from stable to nightly

View File

@ -14,7 +14,7 @@ name: Minishift
on:
pull_request:
branches:
- master
- main
jobs:
minishift:
name: Test Eclipse Che update from stable to nightly

View File

@ -11,10 +11,10 @@ on:
forceflag:
description: 'To force creation of .x branch, use --force flag here'
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:
branches:
- master
- main
paths:
- 'VERSION'

View File

@ -11,10 +11,10 @@ on:
forceflag:
description: 'To force creation of .x branch, use --force flag here'
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:
branches:
- master
- main
paths:
- 'VERSION'
@ -48,7 +48,7 @@ jobs:
fi
# 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
# e.g 7.27.0 for Che = v0.1.0 for DWO
chectlMajorMinorVersion=${chectlVersion#7.}
@ -74,7 +74,7 @@ jobs:
IFS=',' read -ra paramMap <<< "${this_params}"
for keyvalue in "${paramMap[@]}"
do
do
key=${keyvalue%=*}
value=${keyvalue#*=}
echo $var1

View File

@ -7,10 +7,10 @@ on:
forceflag:
description: 'To update an existing PR, use -f or --force flag here'
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:
branches:
- master
- main
paths:
- 'VERSION'

View File

@ -1,6 +1,6 @@
# Che/CodeReady Workspaces Operator
[![codecov](https://codecov.io/gh/eclipse-che/che-operator/branch/master/graph/badge.svg?token=IlYvrVU5nB)](https://codecov.io/gh/eclipse-che/che-operator)
[![codecov](https://codecov.io/gh/eclipse-che/che-operator/branch/main/graph/badge.svg?token=IlYvrVU5nB)](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.
@ -378,7 +378,7 @@ $ export NO_DATE_UPDATE="true" \
### 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.

View File

@ -68,7 +68,7 @@ Validate that the release version is installed and workspace can be created:
## 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)

View File

@ -5,7 +5,7 @@ projects:
source:
location: 'https://github.com/eclipse-che/che-operator.git'
type: git
branch: master
branch: main
clonePath: src/github.com/eclipse-che/che-operator
components:
- id: golang/go/latest

View File

@ -27,7 +27,7 @@ init() {
RELEASE_DIR=$(cd "$(dirname "$0")"; pwd)
FORCE_UPDATE=""
BUILDX_PLATFORMS="linux/amd64,linux/ppc64le"
DEV_WORKSPACE_CONTROLLER_VERSION="master"
DEV_WORKSPACE_CONTROLLER_VERSION="main"
DEV_WORKSPACE_CHE_OPERATOR_VERSION="main"
if [[ $# -lt 1 ]]; then usage; exit; fi
@ -82,9 +82,9 @@ checkoutToReleaseBranch() {
echo "[INFO] $BRANCH exists."
resetChanges $BRANCH
else
echo "[INFO] $BRANCH does not exist. Will be created a new one from master."
resetChanges master
git push origin master:$BRANCH
echo "[INFO] $BRANCH does not exist. Will be created a new one from main."
resetChanges main
git push origin main:$BRANCH
fi
git checkout -B $RELEASE_BRANCH
}
@ -126,7 +126,6 @@ checkImageReferences() {
echo "[ERROR] Unable to find ubi8_minimal image in the $filename"; exit 1
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
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
}
createPRToMasterBranch() {
echo "[INFO] createPRToMasterBranch :: Create pull request into master branch to copy csv"
resetChanges master
local tmpBranch="copy-csv-to-master"
createPRToMainBranch() {
echo "[INFO] createPRToMainBranch :: Create pull request into main branch to copy csv"
resetChanges main
local tmpBranch="copy-csv-to-main"
git checkout -B $tmpBranch
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
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
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)
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
}
@ -291,7 +290,7 @@ fi
if [[ $CREATE_PULL_REQUESTS == "true" ]]; then
createPRToXBranch
createPRToMasterBranch
createPRToMainBranch
fi
if [[ $PREPARE_COMMUNITY_OPERATORS_UPDATE == "true" ]]; then

View File

@ -5,9 +5,9 @@
defaultsFile=${0%/*}/defaults.go
if [[ ! -f ${defaultsFile} ]]; then
echo "$defaultsFile not found, downloading from master..."
echo "$defaultsFile not found, downloading from main..."
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
excludes="eclipse/che-keycloak|centos/postgresql-96-centos7"