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

fix(installer): tarball installer checks for ini in mods-available #971

Merged
merged 3 commits into from
Oct 15, 2024

Conversation

ZNeumann
Copy link
Contributor

@ZNeumann ZNeumann commented Oct 9, 2024

Debian uses a directory called "mods-available" to house ini files. It's phpenmod and phpdismod allow command-line management of extensions in directory. It also creates a symlink ini file to this "mods-available" directory in the normal conf.d directory. The issue is that this symlink is prefixed with a number (for example 20-newrelic.ini). This prefix prevents our tarball installer from recognizing that a newrelic.ini already exists, resulting in 2 ini files: a newrelic.ini and a 20-newrelic.ini.

Our .deb package installer scouts out the "mods-available" directory and installs therein when possible. That means that if a customer installs via package but upgrades via tarball (not recommended), then their system gets the duplicates.

This change makes our tarball installer scout for a potential previous installation in mods-available.

Fixes #399

@newrelic-php-agent-bot
Copy link

newrelic-php-agent-bot commented Oct 9, 2024

Test Suite Status Result
Multiverse 7/7 passing
SOAK 54/56 passing

@codecov-commenter
Copy link

codecov-commenter commented Oct 9, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 78.54%. Comparing base (f9530ed) to head (faa309e).

Additional details and impacted files
@@           Coverage Diff           @@
##              dev     #971   +/-   ##
=======================================
  Coverage   78.54%   78.54%           
=======================================
  Files         196      196           
  Lines       27103    27103           
=======================================
  Hits        21287    21287           
  Misses       5816     5816           
Flag Coverage Δ
agent-for-php-7.2 78.55% <ø> (ø)
agent-for-php-7.3 78.57% <ø> (ø)
agent-for-php-7.4 78.27% <ø> (ø)
agent-for-php-8.0 78.29% <ø> (ø)
agent-for-php-8.1 78.28% <ø> (ø)
agent-for-php-8.2 77.87% <ø> (ø)
agent-for-php-8.3 77.87% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

agent/newrelic-install.sh Outdated Show resolved Hide resolved
Co-authored-by: Michal Nowacki <mnowacki@newrelic.com>
@lavarou lavarou added this to the next-release milestone Oct 15, 2024
@ZNeumann ZNeumann merged commit 597bad6 into dev Oct 15, 2024
55 checks passed
@ZNeumann ZNeumann deleted the zjn/mods-available branch October 22, 2024 20:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants