From 800e0aba3c6dda9ee703ef6795f1a081d0209aa5 Mon Sep 17 00:00:00 2001 From: Alvaro Cabanas Date: Thu, 9 Jan 2025 12:30:30 +0100 Subject: [PATCH] Add conflicts to the newrelic-infra packages to not allow having both fips and non fips installed at the same time (#1987) --- .github/workflows/component_molecule_packaging.yml | 1 + build/goreleaser/linux/al2023_amd64.yml | 2 ++ build/goreleaser/linux/al2023_arm64.yml | 2 ++ build/goreleaser/linux/al2_amd64.yml | 2 ++ build/goreleaser/linux/al2_arm64.yml | 2 ++ build/goreleaser/linux/centos_7_amd64.yml | 2 ++ build/goreleaser/linux/centos_7_arm64.yml | 2 ++ build/goreleaser/linux/centos_8_amd64.yml | 2 ++ build/goreleaser/linux/centos_8_arm64.yml | 2 ++ build/goreleaser/linux/debian_systemd_amd64.yml | 2 ++ build/goreleaser/linux/debian_systemd_arm64.yml | 2 ++ build/goreleaser/linux/debian_upstart_amd64.yml | 2 ++ build/goreleaser/linux/rhel_9_amd64.yml | 2 ++ build/goreleaser/linux/rhel_9_arm64.yml | 2 ++ build/goreleaser/linux/sles_125_amd64.yml | 2 ++ build/goreleaser/linux/sles_125_arm64.yml | 2 ++ build/goreleaser/linux/sles_152_amd64.yml | 2 ++ build/goreleaser/linux/sles_152_arm64.yml | 2 ++ build/goreleaser/linux/sles_153_amd64.yml | 2 ++ build/goreleaser/linux/sles_153_arm64.yml | 2 ++ build/goreleaser/linux/sles_154_amd64.yml | 2 ++ build/goreleaser/linux/sles_154_arm64.yml | 2 ++ build/goreleaser/linux/sles_155_amd64.yml | 2 ++ build/goreleaser/linux/sles_155_arm64.yml | 2 ++ build/goreleaser/linux/sles_156_amd64.yml | 2 ++ build/goreleaser/linux/sles_156_arm64.yml | 2 ++ 26 files changed, 51 insertions(+) diff --git a/.github/workflows/component_molecule_packaging.yml b/.github/workflows/component_molecule_packaging.yml index 82f508f8d..bae272ecf 100644 --- a/.github/workflows/component_molecule_packaging.yml +++ b/.github/workflows/component_molecule_packaging.yml @@ -35,5 +35,6 @@ jobs: gpg_key: 'https://download.newrelic.com/infrastructure_agent/gpg/newrelic-infra.gpg' repo_base_url: ${{ inputs.REPO_ENDPOINT }} package_name: 'newrelic-infra-fips' + exec_name: 'newrelic-infra' package_version: ${{ inputs.TAG }} platforms: "al2,al2023,debian-bullseye,debian-bookworm,redhat8,redhat9,suse15.3,suse15.4,suse15.5,suse15.6,ubuntu1604,ubuntu1804,ubuntu2004,ubuntu2204,ubuntu2404" diff --git a/build/goreleaser/linux/al2023_amd64.yml b/build/goreleaser/linux/al2023_amd64.yml index 303772918..dbe57a236 100644 --- a/build/goreleaser/linux/al2023_amd64.yml +++ b/build/goreleaser/linux/al2023_amd64.yml @@ -88,5 +88,7 @@ # Required packages. rpm version 4.11.3 does not support weak dependencies recommends: - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end AL2023 adm64 diff --git a/build/goreleaser/linux/al2023_arm64.yml b/build/goreleaser/linux/al2023_arm64.yml index 2a5e0419d..18b8e1cad 100644 --- a/build/goreleaser/linux/al2023_arm64.yml +++ b/build/goreleaser/linux/al2023_arm64.yml @@ -81,5 +81,7 @@ # Recommended packages. If they fail to install installation of the agent will not be interrupted. recommends: - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end AL2023 arm64 diff --git a/build/goreleaser/linux/al2_amd64.yml b/build/goreleaser/linux/al2_amd64.yml index 3a33530ae..54da3b83f 100644 --- a/build/goreleaser/linux/al2_amd64.yml +++ b/build/goreleaser/linux/al2_amd64.yml @@ -89,5 +89,7 @@ dependencies: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end AL2 adm64 diff --git a/build/goreleaser/linux/al2_arm64.yml b/build/goreleaser/linux/al2_arm64.yml index 169b7c9f3..82aad5180 100644 --- a/build/goreleaser/linux/al2_arm64.yml +++ b/build/goreleaser/linux/al2_arm64.yml @@ -82,5 +82,7 @@ dependencies: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end AL2 arm64 diff --git a/build/goreleaser/linux/centos_7_amd64.yml b/build/goreleaser/linux/centos_7_amd64.yml index 119eace95..4a490354e 100644 --- a/build/goreleaser/linux/centos_7_amd64.yml +++ b/build/goreleaser/linux/centos_7_amd64.yml @@ -88,5 +88,7 @@ dependencies: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end CentOS 7 amd64 diff --git a/build/goreleaser/linux/centos_7_arm64.yml b/build/goreleaser/linux/centos_7_arm64.yml index dd80014e6..10fd94d25 100644 --- a/build/goreleaser/linux/centos_7_arm64.yml +++ b/build/goreleaser/linux/centos_7_arm64.yml @@ -83,5 +83,7 @@ dependencies: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end CentOS 7 arm64 diff --git a/build/goreleaser/linux/centos_8_amd64.yml b/build/goreleaser/linux/centos_8_amd64.yml index 45697f2e9..2f88f54ce 100644 --- a/build/goreleaser/linux/centos_8_amd64.yml +++ b/build/goreleaser/linux/centos_8_amd64.yml @@ -89,5 +89,7 @@ recommends: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end CentOS 8 amd64 diff --git a/build/goreleaser/linux/centos_8_arm64.yml b/build/goreleaser/linux/centos_8_arm64.yml index 692e361d0..395ddf86e 100644 --- a/build/goreleaser/linux/centos_8_arm64.yml +++ b/build/goreleaser/linux/centos_8_arm64.yml @@ -82,5 +82,7 @@ recommends: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end CentOS 8 arm64 diff --git a/build/goreleaser/linux/debian_systemd_amd64.yml b/build/goreleaser/linux/debian_systemd_amd64.yml index 557c3beac..684919991 100644 --- a/build/goreleaser/linux/debian_systemd_amd64.yml +++ b/build/goreleaser/linux/debian_systemd_amd64.yml @@ -73,5 +73,7 @@ recommends: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end Debian systemd amd64 diff --git a/build/goreleaser/linux/debian_systemd_arm64.yml b/build/goreleaser/linux/debian_systemd_arm64.yml index 9dea8fe7b..d373168fc 100644 --- a/build/goreleaser/linux/debian_systemd_arm64.yml +++ b/build/goreleaser/linux/debian_systemd_arm64.yml @@ -73,5 +73,7 @@ recommends: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end Debian systemd arm64 diff --git a/build/goreleaser/linux/debian_upstart_amd64.yml b/build/goreleaser/linux/debian_upstart_amd64.yml index ddff42635..1a839b42b 100644 --- a/build/goreleaser/linux/debian_upstart_amd64.yml +++ b/build/goreleaser/linux/debian_upstart_amd64.yml @@ -69,5 +69,7 @@ recommends: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end Debian upstart amd64 diff --git a/build/goreleaser/linux/rhel_9_amd64.yml b/build/goreleaser/linux/rhel_9_amd64.yml index ab7a82422..7259b48c8 100644 --- a/build/goreleaser/linux/rhel_9_amd64.yml +++ b/build/goreleaser/linux/rhel_9_amd64.yml @@ -88,5 +88,7 @@ # Recommended packages. If they fail to install installation of the agent will not be interrupted. recommends: - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end RHEL 9 amd64 diff --git a/build/goreleaser/linux/rhel_9_arm64.yml b/build/goreleaser/linux/rhel_9_arm64.yml index b9bc502a2..46d32e2a4 100644 --- a/build/goreleaser/linux/rhel_9_arm64.yml +++ b/build/goreleaser/linux/rhel_9_arm64.yml @@ -81,5 +81,7 @@ # Recommended packages. If they fail to install installation of the agent will not be interrupted. recommends: - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end RHEL 9 arm64 diff --git a/build/goreleaser/linux/sles_125_amd64.yml b/build/goreleaser/linux/sles_125_amd64.yml index 3d02150cf..06c3514a9 100644 --- a/build/goreleaser/linux/sles_125_amd64.yml +++ b/build/goreleaser/linux/sles_125_amd64.yml @@ -91,5 +91,7 @@ recommends: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end SLES 12.5 amd64 diff --git a/build/goreleaser/linux/sles_125_arm64.yml b/build/goreleaser/linux/sles_125_arm64.yml index e8d3c84e8..924ccf551 100644 --- a/build/goreleaser/linux/sles_125_arm64.yml +++ b/build/goreleaser/linux/sles_125_arm64.yml @@ -79,6 +79,8 @@ posttrans: "build/package/rpm/postinst-systemd.sh" summary: "New Relic Infrastructure Agent" group: default + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # Recommended packages. If they fail to install installation of the agent will not be interrupted. # recommends: # FB not supported yet diff --git a/build/goreleaser/linux/sles_152_amd64.yml b/build/goreleaser/linux/sles_152_amd64.yml index ac423b247..4e5e4fda4 100644 --- a/build/goreleaser/linux/sles_152_amd64.yml +++ b/build/goreleaser/linux/sles_152_amd64.yml @@ -89,5 +89,7 @@ recommends: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end SLES 15.2 amd64 diff --git a/build/goreleaser/linux/sles_152_arm64.yml b/build/goreleaser/linux/sles_152_arm64.yml index a24f23090..8737ee9f1 100644 --- a/build/goreleaser/linux/sles_152_arm64.yml +++ b/build/goreleaser/linux/sles_152_arm64.yml @@ -79,6 +79,8 @@ posttrans: "build/package/rpm/postinst-systemd.sh" summary: "New Relic Infrastructure Agent" group: default + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # Recommended packages. If they fail to install installation of the agent will not be interrupted. # recommends: # FB not supported yet diff --git a/build/goreleaser/linux/sles_153_amd64.yml b/build/goreleaser/linux/sles_153_amd64.yml index b2dc10912..60eb708d6 100644 --- a/build/goreleaser/linux/sles_153_amd64.yml +++ b/build/goreleaser/linux/sles_153_amd64.yml @@ -89,5 +89,7 @@ recommends: - td-agent-bit #To be removed on removal of the ff fluent_bit_19 - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end SLES 15.3 amd64 diff --git a/build/goreleaser/linux/sles_153_arm64.yml b/build/goreleaser/linux/sles_153_arm64.yml index 17b85ee44..c7744347a 100644 --- a/build/goreleaser/linux/sles_153_arm64.yml +++ b/build/goreleaser/linux/sles_153_arm64.yml @@ -79,6 +79,8 @@ posttrans: "build/package/rpm/postinst-systemd.sh" summary: "New Relic Infrastructure Agent" group: default + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # Recommended packages. If they fail to install installation of the agent will not be interrupted. # recommends: # FB not supported yet diff --git a/build/goreleaser/linux/sles_154_amd64.yml b/build/goreleaser/linux/sles_154_amd64.yml index edc7070f1..250811726 100644 --- a/build/goreleaser/linux/sles_154_amd64.yml +++ b/build/goreleaser/linux/sles_154_amd64.yml @@ -88,5 +88,7 @@ # Recommended packages. If they fail to install installation of the agent will not be interrupted. recommends: - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end SLES 15.4 amd64 diff --git a/build/goreleaser/linux/sles_154_arm64.yml b/build/goreleaser/linux/sles_154_arm64.yml index 1e129e0df..ec59b1cbc 100644 --- a/build/goreleaser/linux/sles_154_arm64.yml +++ b/build/goreleaser/linux/sles_154_arm64.yml @@ -79,6 +79,8 @@ posttrans: "build/package/rpm/postinst-systemd.sh" summary: "New Relic Infrastructure Agent" group: default + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # Recommended packages. If they fail to install installation of the agent will not be interrupted. # recommends: # FB not supported yet diff --git a/build/goreleaser/linux/sles_155_amd64.yml b/build/goreleaser/linux/sles_155_amd64.yml index 19993c81d..f99d4cef0 100644 --- a/build/goreleaser/linux/sles_155_amd64.yml +++ b/build/goreleaser/linux/sles_155_amd64.yml @@ -88,5 +88,7 @@ # Recommended packages. If they fail to install installation of the agent will not be interrupted. recommends: - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end SLES 15.5 amd64 diff --git a/build/goreleaser/linux/sles_155_arm64.yml b/build/goreleaser/linux/sles_155_arm64.yml index 1c70bdaab..97238c146 100644 --- a/build/goreleaser/linux/sles_155_arm64.yml +++ b/build/goreleaser/linux/sles_155_arm64.yml @@ -79,6 +79,8 @@ posttrans: "build/package/rpm/postinst-systemd.sh" summary: "New Relic Infrastructure Agent" group: default + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # Recommended packages. If they fail to install installation of the agent will not be interrupted. # recommends: # FB not supported yet diff --git a/build/goreleaser/linux/sles_156_amd64.yml b/build/goreleaser/linux/sles_156_amd64.yml index af8f779a8..e9ad6b829 100644 --- a/build/goreleaser/linux/sles_156_amd64.yml +++ b/build/goreleaser/linux/sles_156_amd64.yml @@ -88,5 +88,7 @@ # Recommended packages. If they fail to install installation of the agent will not be interrupted. recommends: - fluent-bit + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # end SLES 15.6 amd64 diff --git a/build/goreleaser/linux/sles_156_arm64.yml b/build/goreleaser/linux/sles_156_arm64.yml index cd82ff315..aaef64c52 100644 --- a/build/goreleaser/linux/sles_156_arm64.yml +++ b/build/goreleaser/linux/sles_156_arm64.yml @@ -68,6 +68,8 @@ posttrans: "build/package/rpm/postinst-systemd.sh" summary: "New Relic Infrastructure Agent" group: default + conflicts: + - newrelic-infra{{ if eq .Env.FIPS "" -}}-fips{{ end }} # Recommended packages. If they fail to install installation of the agent will not be interrupted. # recommends: # FB not supported yet