Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MON-152201 Centreon next 24.11 (Jira release #20182#) #1828

Open
wants to merge 41 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
9c745e0
enh(clib):Remove basic/interruption_error (#1650)
sechkem Sep 5, 2024
a64e8d2
no engine_otl_endpoint parameter in telegraf config (#1676)
jean-christophe81 Sep 6, 2024
395e512
fix(common/engine_conf): multiple inheritence broken because of a mis…
bouda1 Sep 12, 2024
710f1b2
enh(ci): run promote job in dry-run mode on testing branches (#1691)
kduret Sep 13, 2024
0b976d1
MON 137835 cma windows robot tests (#1555)
jean-christophe81 Sep 13, 2024
b1bbe26
fix(engine): host's name instead of template name as alias (#1690)
sechkem Sep 17, 2024
7e81c80
fix(ci): check PR status from head branch name (#1707)
kduret Sep 17, 2024
db95964
fix(broker/bbdo):grpc_stream.proto is bad generated (#1713)
sechkem Sep 18, 2024
721d859
fix(ci): legacy conf engine enabled
bouda1 Sep 18, 2024
2f2ab6b
enh(ci): detect automatically cloud versions (#1712)
kduret Sep 18, 2024
d643129
fix(broker/neb): fix bbdov2 hostgroup to correctly set enabled flag (…
vuntz Sep 26, 2024
31ed5da
MON-148688-telegraf-certificate-parameters-harmonization (#1716)
jean-christophe81 Sep 26, 2024
06b13a5
Mon 131997 cma telegraf whitelist (#1723)
jean-christophe81 Sep 30, 2024
fb9dd6f
installer (#1715)
jean-christophe81 Sep 30, 2024
45206e0
enh(engine/gRPC): GetHost function return all about host (#1719)
sechkem Sep 30, 2024
9117d77
chore(packaging): update deb packages naming convention (#1725)
kduret Sep 30, 2024
63e9663
chore(release): bump major to 24.10 (#1729)
tuntoja Oct 2, 2024
016451f
fix(ci): consider new major version as cloud (#1741)
kduret Oct 3, 2024
ce58da6
centreon-engine-daemon package depends from centreon-engine-opentelem…
jean-christophe81 Oct 3, 2024
5cde3d9
add promote to windows-agent.xml (#1743)
jean-christophe81 Oct 4, 2024
723d343
fix(packaging): add gorgone dependency to install Safe.pm (#1746)
kduret Oct 4, 2024
994c5d7
MON-149538-prepare agent project for native checks (#1747)
jean-christophe81 Oct 7, 2024
371ffac
fix(disco): adapt paths and whitelist to new autodisco script locatio…
kduret Oct 7, 2024
619df53
silent mode for installer and modifier (#1737)
jean-christophe81 Oct 8, 2024
0704126
MON-150242-silent mode for installer and modifier (#1737) (#1751)
pkippes Oct 8, 2024
3f11589
fix(ci): fix cloud context detection when onprem and cloud have the s…
tuntoja Oct 8, 2024
33f361d
chore(ci): disable jammy delivery in 24.10 (#1754)
tuntoja Oct 8, 2024
e58231b
fix(packaging): always set release number provided by action inputs (…
kduret Oct 10, 2024
5de908d
fix(ci): update push jobs in workflows (#1773)
tuntoja Oct 18, 2024
43eabd3
feat(gorgone): when pushing engine conf, push centreon_vmware daemon …
Evan-Adam Oct 14, 2024
ce93029
Mon 144663 gorgone pull tests fail some time on the ci (#1753)
Evan-Adam Oct 15, 2024
b183045
feat(gorgone): when pushing engine conf, push centreon_vmware daemon …
pkippes Oct 21, 2024
c7af5ad
MON-150047 Centreon next 24.10 (Jira release #20136#) (#1749)
pkippes Oct 30, 2024
0231a89
remove condition on promote and release_cloud input
tuntoja Oct 30, 2024
2c1bcc6
fix(ci): re enable debian promotion for on prem (#1797)
tuntoja Oct 30, 2024
b4b3dee
chore(release) bump collect to 24.11.0
pkippes Nov 5, 2024
eec9632
update dockerfile of gorgone testing
tuntoja Nov 5, 2024
fb3ffe5
fix(ci): compilation on ci fixed concerning legacy_engine (#1834) (#1…
bouda1 Nov 6, 2024
5db88ff
fix agent compile (#1838)
jean-christophe81 Nov 6, 2024
23b958e
fix(gorgone): use Centreon version to create 1 docker images per vers…
sdepassio Nov 13, 2024
096a54b
enh(broker): AdaptiveHostStatus and AdaptiveServiceStatus added (#1869)
bouda1 Nov 18, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
14 changes: 8 additions & 6 deletions .github/actions/package/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,12 @@ runs:
using: composite

steps:
- name: Parse distrib name
id: parse-distrib
uses: ./.github/actions/parse-distrib
with:
distrib: ${{ inputs.distrib }}

- name: Import gpg key
env:
RPM_GPG_SIGNING_KEY: ${{ inputs.rpm_gpg_key }}
Expand All @@ -62,14 +68,10 @@ runs:
export ARCH="${{ inputs.arch }}"

if [ "${{ inputs.package_extension }}" = "rpm" ]; then
export DIST=".${{ inputs.distrib }}"
export DIST="${{ steps.parse-distrib.outputs.package_distrib_separator }}${{ steps.parse-distrib.outputs.package_distrib_name }}"
else
export DIST=""
if [ "${{ inputs.stability }}" = "unstable" ] || [ "${{ inputs.stability }}" = "canary" ]; then
export RELEASE="$RELEASE~${{ inputs.distrib }}"
else
export RELEASE="1~${{ inputs.distrib }}"
fi
export RELEASE="$RELEASE${{ steps.parse-distrib.outputs.package_distrib_separator }}${{ steps.parse-distrib.outputs.package_distrib_name }}"
fi

MAJOR_LEFT=$( echo $MAJOR_VERSION | cut -d "." -f1 )
Expand Down
45 changes: 45 additions & 0 deletions .github/actions/parse-distrib/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: "parse-distrib"
description: "parse distrib name."
inputs:
distrib:
description: "The distribution name"
required: true
outputs:
package_distrib_separator:
description: "Separator between package version and distrib number"
value: ${{ steps.parse-distrib.outputs.package_distrib_separator }}
package_distrib_name:
description: "Distribution suffix in package name"
value: ${{ steps.parse-distrib.outputs.package_distrib_name }}

runs:
using: "composite"
steps:
- name: Parse distrib
id: parse-distrib
run: |
if [[ "${{ inputs.distrib }}" == "centos7" || "${{ inputs.distrib }}" == "el7" ]]; then
PACKAGE_DISTRIB_SEPARATOR="."
PACKAGE_DISTRIB_NAME="el7"
elif [[ "${{ inputs.distrib }}" == "alma8" || "${{ inputs.distrib }}" == "el8" ]]; then
PACKAGE_DISTRIB_SEPARATOR="."
PACKAGE_DISTRIB_NAME="el8"
elif [[ "${{ inputs.distrib }}" == "alma9" || "${{ inputs.distrib }}" == "el9" ]]; then
PACKAGE_DISTRIB_SEPARATOR="."
PACKAGE_DISTRIB_NAME="el9"
elif [[ "${{ inputs.distrib }}" == "bullseye" ]]; then
PACKAGE_DISTRIB_SEPARATOR="+"
PACKAGE_DISTRIB_NAME="deb11u1"
elif [[ "${{ inputs.distrib }}" == "bookworm" ]]; then
PACKAGE_DISTRIB_SEPARATOR="+"
PACKAGE_DISTRIB_NAME="deb12u1"
elif [[ "${{ inputs.distrib }}" == "jammy" ]]; then
PACKAGE_DISTRIB_SEPARATOR="-"
PACKAGE_DISTRIB_NAME="0ubuntu.22.04"
else
echo "::error::Distrib ${{ inputs.distrib }} cannot be parsed"
exit 1
fi
echo "package_distrib_separator=$PACKAGE_DISTRIB_SEPARATOR" >> $GITHUB_OUTPUT
echo "package_distrib_name=$PACKAGE_DISTRIB_NAME" >> $GITHUB_OUTPUT
shell: bash
35 changes: 25 additions & 10 deletions .github/actions/promote-to-stable/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ runs:
JF_URL: https://centreon.jfrog.io
JF_ACCESS_TOKEN: ${{ inputs.artifactory_token }}

- name: Parse distrib name
id: parse-distrib
uses: ./.github/actions/parse-distrib
with:
distrib: ${{ inputs.distrib }}

- name: Promote RPM packages to stable
if: ${{ startsWith(inputs.distrib, 'el') }}
run: |
Expand Down Expand Up @@ -81,7 +87,7 @@ runs:

# Build target path based on ARCH
echo "[DEBUG] - Build $ARCH target path."
TARGET_PATH="$ROOT_REPO_PATH/${{ inputs.major_version }}/${{ inputs.distrib }}/${{ inputs.stability }}/$ARCH/RPMS/${{ inputs.module_name }}/"
TARGET_PATH="$ROOT_REPO_PATH/${{ inputs.major_version }}/${{ inputs.distrib }}/stable/$ARCH/RPMS/${{ inputs.module_name }}/"
echo "[DEBUG] - Target path: $TARGET_PATH"

# Download candidates for promote
Expand All @@ -91,10 +97,15 @@ runs:
jf rt download $ARTIFACT --flat
done

DRY_RUN_FLAG="--dry-run"
if [ "${{ inputs.stability }}" == "stable" ]; then
DRY_RUN_FLAG=""
fi

# Upload previously downloaded candidates to TARGET_PATH
for ARTIFACT_DL in $(dir|grep -E "*.rpm"); do
echo "[DEBUG] - Promoting (upload) $ARTIFACT_DL to stable $TARGET_PATH."
jf rt upload "$ARTIFACT_DL" "$TARGET_PATH" --flat
jf rt upload "$ARTIFACT_DL" "$TARGET_PATH" --flat $DRY_RUN_FLAG
done

# Cleanup before next round of candidates
Expand All @@ -104,7 +115,7 @@ runs:
shell: bash

- name: Promote DEB packages to stable
if: ${{ !inputs.release_cloud && contains(fromJSON('["bullseye", "bookworm"]'), inputs.distrib) }}
if: ${{ contains(fromJSON('["bullseye", "bookworm"]'), inputs.distrib) }}
run: |
set -eux

Expand All @@ -123,7 +134,7 @@ runs:
SRC_PATHS=$(jf rt search --include-dirs $ROOT_REPO_PATH-testing/pool/${{ inputs.module_name }}/*.deb | jq -r '.[].path')
;;
*)
SRC_PATHS=$(jf rt search --include-dirs $ROOT_REPO_PATH-testing/pool/${{ inputs.module_name }}/*${{ inputs.distrib }}*.deb | jq -r '.[].path')
SRC_PATHS=$(jf rt search --include-dirs $ROOT_REPO_PATH-testing/pool/${{ inputs.module_name }}/*${{ steps.parse-distrib.outputs.package_distrib_name }}*.deb | jq -r '.[].path')
;;
esac

Expand All @@ -132,12 +143,12 @@ runs:
echo "[DEBUG] - Source path found: $SRC_PATH"
done
else
echo "[DEBUG] - No source path found."
continue
echo "::warning::No source path found."
exit 0
fi

echo "[DEBUG] - Build target path."
TARGET_PATH="$ROOT_REPO_PATH-${{ inputs.stability }}/pool/${{ inputs.module_name }}/"
TARGET_PATH="$ROOT_REPO_PATH-stable/pool/${{ inputs.module_name }}/"
echo "[DEBUG] - Target path: $TARGET_PATH"

echo "[DEBUG] - Promoting DEB testing artifacts to stable."
Expand All @@ -151,16 +162,20 @@ runs:
ARTIFACT_SEARCH_PATTERN=".+\.deb"
;;
*)
ARTIFACT_SEARCH_PATTERN=".+${{ inputs.distrib }}.+\.deb"
ARTIFACT_SEARCH_PATTERN=".+${{ steps.parse-distrib.outputs.package_distrib_name }}.+\.deb"
;;
esac

DRY_RUN_FLAG="--dry-run"
if [ "${{ inputs.stability }}" == "stable" ]; then
DRY_RUN_FLAG=""
fi

for ARTIFACT_DL in $(dir -1|grep -E $ARTIFACT_SEARCH_PATTERN); do
ARCH=$(echo $ARTIFACT_DL | cut -d '_' -f3 | cut -d '.' -f1)
echo "[DEBUG] - Promoting (upload) $ARTIFACT_DL to stable $TARGET_PATH."
jf rt upload "$ARTIFACT_DL" "$TARGET_PATH" --deb "${{ inputs.distrib }}/main/$ARCH" --flat
jf rt upload "$ARTIFACT_DL" "$TARGET_PATH" --deb "${{ inputs.distrib }}/main/$ARCH" --flat $DRY_RUN_FLAG
done

rm -f *.deb

shell: bash
23 changes: 19 additions & 4 deletions .github/docker/Dockerfile.gorgone-testing-alma8
Original file line number Diff line number Diff line change
@@ -1,12 +1,27 @@
FROM almalinux:8
ARG REGISTRY_URL=docker.io
ARG VERSION

RUN bash -e <<EOF
FROM ${REGISTRY_URL}/almalinux:8

ARG VERSION
ARG IS_CLOUD

RUN --mount=type=secret,id=ARTIFACTORY_INTERNAL_REPO_USERNAME \
--mount=type=secret,id=ARTIFACTORY_INTERNAL_REPO_PASSWORD \
bash -e <<EOF

dnf install -y dnf-plugins-core zstd curl mariadb iproute procps lsof
dnf install -y https://rpms.remirepo.net/enterprise/remi-release-8.rpm
dnf config-manager --set-enabled 'powertools'
dnf -y config-manager --add-repo https://packages.centreon.com/rpm-standard/23.10/el8/centreon-23.10.repo
dnf -y clean all --enablerepo=*

if [[ "${IS_CLOUD}" == "1" ]]; then
dnf config-manager --add-repo https://$(cat /run/secrets/ARTIFACTORY_INTERNAL_REPO_USERNAME):$(cat /run/secrets/ARTIFACTORY_INTERNAL_REPO_PASSWORD)@packages.centreon.com/rpm-standard-internal/${VERSION}/el8/centreon-${VERSION}-internal.repo
sed -i "s#packages.centreon.com/rpm-standard-internal#$(cat /run/secrets/ARTIFACTORY_INTERNAL_REPO_USERNAME):$(cat /run/secrets/ARTIFACTORY_INTERNAL_REPO_PASSWORD)@packages.centreon.com/rpm-standard-internal#" /etc/yum.repos.d/centreon-${VERSION}-internal.repo
else
dnf config-manager --add-repo https://packages.centreon.com/rpm-standard/${VERSION}/el8/centreon-${VERSION}.repo
fi
dnf config-manager --set-enabled 'centreon*'

dnf install -y python3.11 python3.11-pip
pip3.11 install robotframework robotframework-examples robotframework-databaselibrary pymysql robotframework-requests robotframework-jsonlibrary

Expand Down
23 changes: 19 additions & 4 deletions .github/docker/Dockerfile.gorgone-testing-alma9
Original file line number Diff line number Diff line change
@@ -1,14 +1,29 @@
FROM almalinux:9
ARG REGISTRY_URL=docker.io
ARG VERSION

RUN bash -e <<EOF
FROM ${REGISTRY_URL}/almalinux:9

ARG VERSION
ARG IS_CLOUD

RUN --mount=type=secret,id=ARTIFACTORY_INTERNAL_REPO_USERNAME \
--mount=type=secret,id=ARTIFACTORY_INTERNAL_REPO_PASSWORD \
bash -e <<EOF

dnf install -y dnf-plugins-core zstd mariadb iproute epel-release procps lsof
dnf config-manager --set-enabled crb
dnf config-manager --add-repo https://packages.centreon.com/rpm-standard/23.10/el9/centreon-23.10.repo

if [[ "${IS_CLOUD}" == "1" ]]; then
dnf config-manager --add-repo https://$(cat /run/secrets/ARTIFACTORY_INTERNAL_REPO_USERNAME):$(cat /run/secrets/ARTIFACTORY_INTERNAL_REPO_PASSWORD)@packages.centreon.com/rpm-standard-internal/${VERSION}/el9/centreon-${VERSION}-internal.repo
sed -i "s#packages.centreon.com/rpm-standard-internal#$(cat /run/secrets/ARTIFACTORY_INTERNAL_REPO_USERNAME):$(cat /run/secrets/ARTIFACTORY_INTERNAL_REPO_PASSWORD)@packages.centreon.com/rpm-standard-internal#" /etc/yum.repos.d/centreon-${VERSION}-internal.repo
else
dnf config-manager --add-repo https://packages.centreon.com/rpm-standard/${VERSION}/el9/centreon-${VERSION}.repo
fi
dnf config-manager --set-enabled 'centreon*'

dnf install -y python3.11 python3.11-pip
pip3.11 install robotframework robotframework-examples robotframework-databaselibrary pymysql robotframework-requests robotframework-jsonlibrary


dnf clean all

EOF
25 changes: 20 additions & 5 deletions .github/docker/Dockerfile.gorgone-testing-bookworm
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
FROM debian:bookworm
ARG REGISTRY_URL=docker.io
ARG VERSION

FROM ${REGISTRY_URL}/debian:bookworm

ARG VERSION

ENV DEBIAN_FRONTEND=noninteractive

Expand All @@ -18,11 +23,21 @@ pip3 install --break-system-packages --no-cache-dir \
robotframework robotframework-examples robotframework-databaselibrary \
pymysql robotframework-requests robotframework-jsonlibrary

# can't use \$() method it would be executed before the main script, and lsb_release would not be installed.
lsb_release -sc | xargs -I % sh -c 'echo deb https://packages.centreon.com/apt-standard-24.05-stable/ % main' | tee /etc/apt/sources.list.d/centreon.list
lsb_release -sc | xargs -I % sh -c 'echo deb https://packages.centreon.com/apt-plugins-stable/ % main' | tee /etc/apt/sources.list.d/centreon-plugins.list
VERSION_CODENAME=\$(
. /etc/os-release
echo \$VERSION_CODENAME
)

echo "deb https://packages.centreon.com/apt-standard-${VERSION}-stable/ \$VERSION_CODENAME main" | tee -a /etc/apt/sources.list.d/centreon-stable.list
echo "deb https://packages.centreon.com/apt-standard-${VERSION}-testing/ \$VERSION_CODENAME main" | tee -a /etc/apt/sources.list.d/centreon-testing.list
echo "deb https://packages.centreon.com/apt-standard-${VERSION}-unstable/ \$VERSION_CODENAME main" | tee -a /etc/apt/sources.list.d/centreon-unstable.list
echo "deb https://packages.centreon.com/apt-plugins-stable/ \$VERSION_CODENAME main" | tee -a /etc/apt/sources.list.d/centreon-plugins-stable.list
echo "deb https://packages.centreon.com/apt-plugins-testing/ \$VERSION_CODENAME main" | tee -a /etc/apt/sources.list.d/centreon-plugins-testing.list
echo "deb https://packages.centreon.com/apt-plugins-unstable/ \$VERSION_CODENAME main" | tee -a /etc/apt/sources.list.d/centreon-plugins-unstable.list
wget -O- https://packages.centreon.com/api/security/keypair/APT-GPG-KEY/public | gpg --dearmor | tee /etc/apt/trusted.gpg.d/centreon.gpg > /dev/null 2>&1

apt-get update

wget -O- https://apt-key.centreon.com | gpg --dearmor | tee /etc/apt/trusted.gpg.d/centreon.gpg > /dev/null 2>&1
apt-get clean
rm -rf /var/lib/apt/lists/*

Expand Down
28 changes: 0 additions & 28 deletions .github/docker/Dockerfile.gorgone-testing-bullseye

This file was deleted.

41 changes: 0 additions & 41 deletions .github/docker/Dockerfile.gorgone-testing-jammy

This file was deleted.

Loading
Loading