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

Fixes for licensing #5688

Merged
merged 4 commits into from Nov 23, 2023
Merged

Fixes for licensing #5688

merged 4 commits into from Nov 23, 2023

Conversation

nolanpro
Copy link
Collaborator

@nolanpro nolanpro commented Nov 22, 2023

Issue & Reproduction Steps

Packages that were disabled via licenses are being re-enabled after install

Solution

If the bootstrap/config/packges.php gets re-built before our custom LicensedPackageManifest is registered, the all packages will be enabled regardless of the license. This happens on several cache commands, such as clear-compiled, or if the package.php file is removed, which is what optimize:clear does.

  • Do not run clear-compiled when settings change. clear-compiled will remove other cached files (like packages.php, which is responsible for the license restrictions). The config:cache that runs after is sufficient.
  • Run package:discover automatically after running processmaker:license-remove so all packages are available again when the license is removed.
  • Fix home page not found when dynamic UI package is not enabled
  • In https://github.com/ProcessMaker/pm4-k8s-distribution/pull/27
    • Remove all optimize:clear calls
    • Call optimize only once and only after packages are installed and before the license is installed. Otherwise, optimize will disabled the licenses by overwriting packages.php

How to Test

Describe how to test that this solution works.

Related Tickets & Packages

Requires

Code Review Checklist

  • I have pulled this code locally and tested it on my instance, along with any associated packages.
  • This code adheres to ProcessMaker Coding Guidelines.
  • This code includes a unit test or an E2E test that tests its functionality, or is covered by an existing test.
  • This solution fixes the bug reported in the original ticket.
  • This solution does not alter the expected output of a component in a way that would break existing Processes.
  • This solution does not implement any breaking changes that would invalidate documentation or cause existing Processes to fail.
  • This solution has been tested with enterprise packages that rely on its functionality and does not introduce bugs in those packages.
  • This code does not duplicate functionality that already exists in the framework or in ProcessMaker.
  • This ticket conforms to the PRD associated with this part of ProcessMaker.

Copy link

processmaker-sonarqube bot commented Nov 23, 2023

@nolanpro nolanpro changed the title Bugfix/four 12535 Fixes for licensing Nov 23, 2023
@ryancooley ryancooley merged commit 36f9af1 into develop Nov 23, 2023
11 of 18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants