-
-
Notifications
You must be signed in to change notification settings - Fork 451
Issue #140: Added a memory-limit setting for the CLI #347
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
Open
colans
wants to merge
3
commits into
geerlingguy:master
Choose a base branch
from
consensus-enterprises:issue-140
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 2 commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
--- | ||
|
||
- name: Set PHP CLI memory limit. | ||
block: | ||
- name: Ensure PHP CLI config directory exists. | ||
file: | ||
dest: "/etc/php/{{ php_default_version_debian }}/cli/conf.d/" | ||
state: directory | ||
- name: Set PHP CLI memory limit. | ||
template: | ||
src: memory_limit.ini.j2 | ||
dest: "/etc/php/{{ php_default_version_debian }}/cli/conf.d/20-memory_limit.ini" | ||
become: yes | ||
when: php_set_cli_memory_limit | bool | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
; {{ ansible_managed }} | ||
|
||
; configuration for increasing PHP CLI memory limit | ||
; priority=20 | ||
memory_limit = {{ php_cli_memory_limit }} |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we have this set up for RedHat-derivatives too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@geerlingguy No, sorry. We've standardized on Ubuntu LTS over here; I don't typically work with non-Debian-based OSes (and wouldn't recommend them, but that's another story). What I'd recommend doing, which is what we do for Aegir, is get support for each alternative component as it comes in. So whenever this is good to go, merge it, but leave the issue open for someone else to come along and work on the Red Hat support (and then close it once that gets in). Would that work for you?
I'll take a look at the Lint problems and see if I can get those fixed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tests were passing for Red Hat though. So maybe it's all good?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd still rather not merge it if it only works on Debian.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@geerlingguy But if tests are passing, doesn't this prove that it also works on Red Hat, or whatever?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
well
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The role still works, but if I add a feature that has a default variable that only applies to one distro (or a few) of any that are supported, then I start having to remember (for myself) which features of the role work on only one distro but not the other, and I have to start adding complexity to the documentation for features which shouldn't need to be distro-specific.
I prefer for my own roles to have defaults that work across any distro the role supports, but I'm always happy for people to fork my roles and modify them according to their own needs. I typically only add features that work on all distros unless it's something extremely specific to one OS (e.g. apt PPA url settings).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fair points. To benefit everyone, however, can we tag this as Planned and then let others push to the PR to complete it eventually, when someone else gets to it? GitLab allows this, but I don't work on GitHub enough to know if that's possible here.
Unless someone is able to provide funding (please contact us if interested), I have no plans to add Red Hat support here, but it would be a shame to simply throw away the work I did.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, I have no problem with that—it's useful functionality, and if someone can come along and make it work on RHEL/RockyLinux as well, I'd be happy to merge.