-
Notifications
You must be signed in to change notification settings - Fork 88
91 lines (90 loc) · 3.25 KB
/
release-next-catalog-and-operator-image.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
#
# Copyright (c) 2019-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
#
name: Release next catalog
on:
# manual trigger if required
workflow_dispatch:
inputs:
reason:
description: 'Reason to trigger a build'
required: false
push:
branches:
- main
jobs:
build-operator-image:
runs-on: ubuntu-22.04
steps:
- name: Checkout source code
uses: actions/checkout@v3
- name: Install yq
run: sudo pip install yq
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to quay.io
uses: docker/login-action@v2
with:
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_PASSWORD }}
registry: quay.io
- name: Build operator image
uses: docker/build-push-action@v3
with:
file: Dockerfile
platforms: linux/amd64,linux/ppc64le,linux/arm64
push: true
tags: quay.io/eclipse/che-operator:next
build-catalog:
runs-on: ubuntu-22.04
needs: build-operator-image
steps:
- name: Checkout source code
uses: actions/checkout@v3
- name: Install yq
run: sudo pip install yq
- name: Login to quay.io
uses: docker/login-action@v2
with:
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_PASSWORD }}
registry: quay.io
- name: Build catalog source
run: ${GITHUB_WORKSPACE}/build/scripts/olm/release-catalog.sh --channel 'next' --catalog-image quay.io/eclipse/eclipse-che-olm-catalog:next
build-catalog-with-digest:
runs-on: ubuntu-22.04
needs: build-operator-image
steps:
- name: Checkout source code
uses: actions/checkout@v3
- name: Install yq
run: sudo pip install yq
- name: Login to quay.io
uses: docker/login-action@v2
with:
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_PASSWORD }}
registry: quay.io
- name: Build catalog source
run: |
${GITHUB_WORKSPACE}/build/scripts/release/editors-definitions.sh update-manager-yaml \
--yaml-path ${GITHUB_WORKSPACE}/config/manager/manager.yaml
${GITHUB_WORKSPACE}/build/scripts/release/samples.sh update-manager-yaml \
--yaml-path ${GITHUB_WORKSPACE}/config/manager/manager.yaml \
--index-json-url "https://raw.githubusercontent.com/eclipse-che/che-dashboard/main/packages/devfile-registry/air-gap/index.json"
make update-dev-resources
${GITHUB_WORKSPACE}/build/scripts/release/addDigests.sh -s $(make csv-path CHANNEL=next) -t next
${GITHUB_WORKSPACE}/build/scripts/olm/release-catalog.sh \
--channel next \
--catalog-image quay.io/eclipse/eclipse-che-olm-catalog:next-digest \
--bundle-image quay.io/eclipse/eclipse-che-olm-bundle:$(make bundle-version CHANNEL=next)-digest