From 3e8301bf1060d15d44650a49b6a69de755fd2c46 Mon Sep 17 00:00:00 2001 From: May <110405507+paul-oureib@users.noreply.github.com> Date: Fri, 19 Apr 2024 11:23:11 +0200 Subject: [PATCH 1/2] fix(permissions): fix permissions on centengine log files (#1282) * fix permission rights on systemd files packaged on centreon * fix * fix --- engine/scripts/logrotate_systemd.conf.in | 2 +- engine/scripts/logrotate_sysv.conf.in | 4 ++-- engine/scripts/logrotate_upstart.conf.in | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/engine/scripts/logrotate_systemd.conf.in b/engine/scripts/logrotate_systemd.conf.in index eab7d6965ac..2b86f7632c0 100644 --- a/engine/scripts/logrotate_systemd.conf.in +++ b/engine/scripts/logrotate_systemd.conf.in @@ -1,6 +1,6 @@ @ENGINE_VAR_LOG_DIR@/*.log { compress - create 640 @USER@ @GROUP@ + create 644 @USER@ @GROUP@ daily delaycompress missingok diff --git a/engine/scripts/logrotate_sysv.conf.in b/engine/scripts/logrotate_sysv.conf.in index 50f694b91d4..7ed01459d4e 100644 --- a/engine/scripts/logrotate_sysv.conf.in +++ b/engine/scripts/logrotate_sysv.conf.in @@ -1,6 +1,6 @@ @VAR_DIR@/centengine.log { compress - create 640 @USER@ @GROUP@ + create 644 @USER@ @GROUP@ daily delaycompress missingok @@ -14,7 +14,7 @@ @VAR_DIR@/centengine.debug { compress - create 640 @USER@ @GROUP@ + create 644 @USER@ @GROUP@ delaycompress missingok olddir @ENGINE_VAR_LOG_ARCHIVE_DIR@ diff --git a/engine/scripts/logrotate_upstart.conf.in b/engine/scripts/logrotate_upstart.conf.in index de02677d72d..f7c94a9de42 100644 --- a/engine/scripts/logrotate_upstart.conf.in +++ b/engine/scripts/logrotate_upstart.conf.in @@ -1,6 +1,6 @@ @VAR_DIR@/centengine.log { compress - create 640 @USER@ @GROUP@ + create 644 @USER@ @GROUP@ daily delaycompress missingok @@ -14,7 +14,7 @@ @VAR_DIR@/centengine.debug { compress - create 640 @USER@ @GROUP@ + create 644 @USER@ @GROUP@ delaycompress missingok olddir @ENGINE_VAR_LOG_ARCHIVE_DIR@ From 112b7d16a46d2512abefec75f029a1ff4ca81f2e Mon Sep 17 00:00:00 2001 From: Paul Oureib Date: Fri, 8 Nov 2024 11:14:18 +0100 Subject: [PATCH 2/2] chore(ci): updated upload/download-artifact actions to offset v3 deprecation --- .github/actions/package-legacy/action.yml | 7 +++++-- .github/workflows/gorgone.yml | 1 + .github/workflows/package.yml | 5 +++++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.github/actions/package-legacy/action.yml b/.github/actions/package-legacy/action.yml index cf5c5afeeb7..3f8b577ba68 100644 --- a/.github/actions/package-legacy/action.yml +++ b/.github/actions/package-legacy/action.yml @@ -10,6 +10,9 @@ inputs: package_extension: description: The package extension (deb or rpm) required: true + distrib: + description: The distribution + required: true frontend_index_cache_key: description: The index.html cache key frontend_index_file: @@ -166,9 +169,9 @@ runs: shell: bash - name: Upload package artifacts - uses: actions/upload-artifact@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 # v3.1.3 + uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3 with: - name: packages-${{ inputs.package_extension }} + name: packages-${{ inputs.package_extension }}-${{ inputs.distrib }} path: ./*.${{ inputs.package_extension }} retention-days: 1 diff --git a/.github/workflows/gorgone.yml b/.github/workflows/gorgone.yml index 1f3874fcac8..aa4c828b537 100644 --- a/.github/workflows/gorgone.yml +++ b/.github/workflows/gorgone.yml @@ -79,6 +79,7 @@ jobs: base_directory: gorgone spec_file: gorgone/packaging/centreon-gorgone.spectemplate package_extension: ${{ matrix.package_extension }} + distrib: ${{ matrix.distrib }} image_name: ${{ matrix.image }} module_name: gorgone major_version: ${{ needs.get-environment.outputs.major_version }} diff --git a/.github/workflows/package.yml b/.github/workflows/package.yml index cd1bda7047f..13f2f270bed 100644 --- a/.github/workflows/package.yml +++ b/.github/workflows/package.yml @@ -13,6 +13,10 @@ on: type: string description: The package extension (deb or rpm) required: true + distrib: + type: string + description: The package distribution + required: true frontend_index_cache_key: type: string description: The index.html cache key @@ -102,6 +106,7 @@ jobs: base_directory: ${{ inputs.base_directory }} spec_file: ${{ inputs.spec_file }} package_extension: ${{ inputs.package_extension }} + distrib: ${{ inputs.distrib }} frontend_index_cache_key: ${{ inputs.frontend_index_cache_key }} frontend_index_file: ${{ inputs.frontend_index_file }} frontend_static_cache_key: ${{ inputs.frontend_static_cache_key }}