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

unit: drop PHP 8.0 support, add PHP 8.2 support #227026

Merged
merged 2 commits into from
Apr 21, 2023

Conversation

LeSuisse
Copy link
Contributor

Description of changes

Related to #224505

Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 23.05 Release Notes (or backporting 22.11 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Result of nixpkgs-review run on x86_64-linux 1

1 package built:
  • unit

PHP 8.0 will be end-of-life before the end of life of the next stable
version of NixOS. Related to NixOS#224505.
@LeSuisse LeSuisse mentioned this pull request Apr 19, 2023
8 tasks
@ofborg ofborg bot requested a review from Izorkin April 19, 2023 09:24
@ofborg ofborg bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild 10.rebuild-linux: 1-10 10.rebuild-linux: 1 labels Apr 19, 2023
Copy link
Member

@RaitoBezarius RaitoBezarius left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM; untested

@RaitoBezarius
Copy link
Member

(CI tests are passing, so I'm inclined to merge)

@LeSuisse LeSuisse added the 12.approved-by: package-maintainer This PR was reviewed and approved by a maintainer listed in the package label Apr 19, 2023
@RaitoBezarius RaitoBezarius merged commit 1bcb219 into NixOS:master Apr 21, 2023
@LeSuisse LeSuisse deleted the unit-drop-php80 branch April 21, 2023 15:59
@RafaelKr
Copy link
Contributor

@LeSuisse you used --module=php81 for PHP 8.2, this doesn't seem to be correct?

@LeSuisse
Copy link
Contributor Author

Indeed it is wrong, thanks for catching it. I'm happy to merge the fix if you open a PR.

@RafaelKr
Copy link
Contributor

Maybe I can submit a PR later today.

I need some custom PHP config anyways. My current workaround is using:

services.unit.package =
  let
    php82-unit =
      (pkgs.php82.withExtensions (
        { all, enabled }:
        enabled
        ++ (with all; [
          imagick
          redis
        ])
      )).override
        {
          embedSupport = true;
          apxs2Support = false;
          systemdSupport = false;
          phpdbgSupport = false;
          cgiSupport = false;
          fpmSupport = false;
        };
  in
  pkgs.unit.overrideAttrs (
    finalAttrs: previousAttrs: {
      postConfigure = ''
        ${previousAttrs.postConfigure}
        ./configure php    --module=php82    --config=${php82-unit.unwrapped.dev}/bin/php-config --lib-path=${php82-unit}/lib
      '';
    }
  );

@RafaelKr
Copy link
Contributor

@LeSuisse There we go :)
#343025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
10.rebuild-darwin: 0 This PR does not cause any packages to rebuild 10.rebuild-linux: 1-10 10.rebuild-linux: 1 12.approved-by: package-maintainer This PR was reviewed and approved by a maintainer listed in the package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants