Skip to content

Commit

Permalink
multiple changes as part of upstream claire
Browse files Browse the repository at this point in the history
- add amq-broker version 7.11.2
- add amq-broker version 7.11.4
- add amq-broker version 7.11.6 and artemiscloud version 1.0.17
- add container image build, test and push workflow
- add dependabot support
- add LICENSE, claire_properties files
- add new amq-broker 7.11.5 version and artemis 2.32.0 version
- add new artemis-operator upstream v1.0.16
- add operator-crd generation as submodule
- add standalone upstream versions 2.31.1 and 2.31.2
- add support to test operator nightly build (snapshots)
- add support to test standalone nightly build (snapshots)
- add upstream operator version to 1.1.0
- add yacfg 2.31.1 and snapshot confg files
- reorganization of folders
- Simplify container file
- start to remove internal information
- unify upstream/downstream makefiles
- update build and test workflow
- update gitignore / dockerignore
- update libraries version
- update makefile clean_all target
- update run-test-arg-parser.sh to to use defaults when printing the help
- update run-test.sh script to copy logs and temp files from container
  • Loading branch information
tlbueno committed Mar 20, 2024
1 parent c01c9b4 commit f37f052
Show file tree
Hide file tree
Showing 51 changed files with 2,121 additions and 652 deletions.
13 changes: 13 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
.dockerignore
.git*
.idea/
operator-crd/artemis
standalone-suite/artemis
*/test-logs/
*/test-tmp/
container_build_*.log
performance/
pom.xml.versionsBackup
standalone-suite/https_console_tune.yaml
test-results/
tmp/
28 changes: 28 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
#
# Copyright RedHat AMQ Broker QE authors.
# License: Apache License 2.0 (see the file LICENSE or http://apache.org/licenses/LICENSE-2.0.html).
#
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
- package-ecosystem: "maven"
directory: "/"
schedule:
interval: "daily"
assignees:
- "tlbueno"
reviewers:
- "tlbueno"

- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"
assignees:
- "tlbueno"
reviewers:
- "tlbueno"
27 changes: 18 additions & 9 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
name: Java Maven build
name: Claire Build and Smoke Test

on:
workflow_dispatch:
push:
pull_request:
branches:
Expand All @@ -10,28 +11,36 @@ permissions: read-all

jobs:
build_and_test:
name: Build Maven
name: Build and Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Checkout
uses: actions/checkout@v3

- name: Set up a cache for Maven
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}

- uses: actions/setup-java@v3
- name: Setup Java
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
cache: 'maven'

- name: Configure GitHub Packages Maven repository
run: cp .github/workflows/settings.xml ~/.m2/

- name: Build with Maven
- name: Build
run: make build

- name: Run standalone smoke tests
run: make standalone_test_smoke

- name: Create k8s Kind Cluster
uses: helm/kind-action@v1
with:
cluster_name: testing-cluster

- name: Run operator smoke tests
run: make operator_test_smoke

99 changes: 68 additions & 31 deletions .github/workflows/image_build.yml
Original file line number Diff line number Diff line change
@@ -1,50 +1,87 @@
name: Build and Push Image
name: Build and Push Images

on:
workflow_dispatch:

env:
IMAGE_NAME: claire
IMAGE_REGISTRY: quay.io
IMAGE_NAMESPACE: rhmessagingqe
ARCHS: amd64, arm64, ppc64le, s390x

jobs:
build_image:
name: Build and push image
runs-on: ubuntu-22.04

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Checkout
uses: actions/checkout@v3

- name: Set up a cache for Maven
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}

- name: Build Image
id: build-image
uses: redhat-actions/buildah-build@v2
- name: Setup Java
uses: actions/setup-java@v4
with:
image: ${{ env.IMAGE_NAME }}
tags: latest ${{ github.sha }} ${{ github.ref_name }}
archs: ${{ env.ARCHS }}
containerfiles: |
./Containerfile
- name: Push To quay.io
id: push-to-quay
uses: redhat-actions/push-to-registry@v2
distribution: 'temurin'
java-version: '17'
cache: 'maven'

- name: Log in to Quay.io
uses: redhat-actions/podman-login@v1
with:
image: ${{ steps.build-image.outputs.image }}
tags: ${{ steps.build-image.outputs.tags }}
registry: ${{ env.IMAGE_REGISTRY }}/${{ env.IMAGE_NAMESPACE }}
username: ${{ secrets.QUAY_USER }}
password: ${{ secrets.QUAY_TOKEN }}
registry: quay.io

- name: Create k8s Kind Cluster
uses: helm/kind-action@v1
with:
cluster_name: testing-cluster

- name: Prepare kind kubeconfig files
run: |
kubectl config view --minify --raw > ./kubeconfig
kubectl --kubeconfig=./kubeconfig config set clusters.kind-kind.server https://kubernetes.default.svc
- name: Retrieve activemq-artemis latest version from properties file
id: activemq_artemis_version
run: echo "VERSION=$(yq '.operator.versions.latest.activemq-artemis' claire_properties.yaml)" >> "$GITHUB_OUTPUT"

- name: Build Claire for Artemis
run: make operator_build OPERATOR_VERSION=${{ steps.activemq_artemis_version.outputs.VERSION }}

- name: Build Claire for Artemis container image
run: |
make build_container OPERATOR_CONTAINER_NAMESPACE=${{ secrets.QUAY_NAMESPACE }} OPERATOR_VERSION=${{ steps.activemq_artemis_version.outputs.VERSION }}
- name: Load Claire for Artemis container image into KinD
run: |
podman save quay.io/${{ secrets.QUAY_NAMESPACE }}/claire:activemq-artemis-${{ steps.activemq_artemis_version.outputs.VERSION }}.amd64 | docker load
kind load docker-image --name testing-cluster quay.io/${{ secrets.QUAY_NAMESPACE }}/claire:activemq-artemis-${{ steps.activemq_artemis_version.outputs.VERSION }}.amd64
- name: Test Claire for Artemis container image
run: operator-suite/container/scripts/run-test.sh -r quay.io/${{ secrets.QUAY_NAMESPACE }}/claire --image-tag activemq-artemis-${{ steps.activemq_artemis_version.outputs.VERSION }}.amd64 --image-namespace ${{ secrets.QUAY_NAMESPACE }}

- name: Push Claire for Artemis container image to registry
run: make build_container OPERATOR_CONTAINER_DEPLOY=true OPERATOR_CONTAINER_SKIP_BUILD=true OPERATOR_CONTAINER_NAMESPACE=${{ secrets.QUAY_NAMESPACE }}

- name: Retrieve AMQ-Broker latest version from properties file
id: amq_broker_version
run: echo "VERSION=$(yq '.operator.versions.latest.amq-broker' claire_properties.yaml)" >> "$GITHUB_OUTPUT"

- name: Build Claire for AMQ-Broker
run: make clean_all operator_build OPERATOR_TYPE=amq-broker OPERATOR_VERSION=${{ steps.amq_broker_version.outputs.VERSION }}

- name: Build Claire for AMQ-Broker container image
run: |
make build_container OPERATOR_TYPE=amq-broker OPERATOR_VERSION=${{ steps.amq_broker_version.outputs.VERSION }} OPERATOR_CONTAINER_GENERATE_LPT_TAG=true OPERATOR_CONTAINER_NAMESPACE=${{ secrets.QUAY_NAMESPACE }}
- name: Load Claire for AMQ-Broker container image into KinD
run: |
podman save quay.io/${{ secrets.QUAY_NAMESPACE }}/claire:amq-broker-${{ steps.amq_broker_version.outputs.VERSION }}.amd64 | docker load
kind load docker-image --name testing-cluster quay.io/${{ secrets.QUAY_NAMESPACE }}/claire:amq-broker-${{ steps.amq_broker_version.outputs.VERSION }}.amd64
- name: Test Claire for AMQ-Broker container image
run: operator-suite/container/scripts/run-test.sh --image-tag amq-broker-${{ steps.amq_broker_version.outputs.VERSION }}.amd64 --image-namespace ${{ secrets.QUAY_NAMESPACE }}

- name: Push Claire for AMQ-Broker container image to registry
run: make build_container OPERATOR_TYPE=amq-broker OPERATOR_CONTAINER_DEPLOY=true OPERATOR_CONTAINER_SKIP_BUILD=true OPERATOR_CONTAINER_GENERATE_LPT_TAG=true OPERATOR_CONTAINER_NAMESPACE=${{ secrets.QUAY_NAMESPACE }}

- name: Print images URL
run: echo "Images pushed to ${{ steps.push-to-quay.outputs.registry-paths }}"
17 changes: 0 additions & 17 deletions .github/workflows/settings.xml

This file was deleted.

28 changes: 10 additions & 18 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,21 +1,13 @@
.idea/
*.iml
/target/*
*/target/*
.m2/
*/artemis/
*/test-logs/
*/test-tmp/*

test_upgrade_plan.yaml
version_map.yaml
common.yaml
settings.xml
operator-suite/artemis/
operator-suite/certificates/
operator-suite/operator-suite.log
standalone-suite/artemis/
standalone-suite/standalone-suite.log
standalone-suite/test_cfg/
standalone-suite/dockerfiles/artemis/*.gz
standalone-suite/dockerfiles/artemis/*.xz
standalone-suite/certificates/
*/test-tmp/
build_properties.yaml
container_build_*.log
performance/
pom.xml.versionsBackup
standalone-suite/https_console_tune.yaml
target/
test-results/
tmp/
38 changes: 0 additions & 38 deletions .mvn/settings.xml

This file was deleted.

Loading

0 comments on commit f37f052

Please sign in to comment.