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

make foreman puppet module dir optional #600

Merged
merged 1 commit into from Jun 19, 2018

Conversation

bastelfreak
Copy link
Member

No description provided.

@bastelfreak
Copy link
Member Author

This is currently work in progress. I'm not sure yet if the tests pass and I also need to adjust the docs. @ekohl @mmoll feedback is highly appreciated :)


I noticed that the module creates this directory. I never saw a foreman installation that uses this so I want to make it optional (or get rid of the exec at all). If there are usecases for the directory I will change the default from false to true.

exec { 'mkdir -p /usr/share/puppet/modules':
creates => '/usr/share/puppet/modules',
path => ['/usr/bin', '/bin'],
if ($puppet::server::create_foreman_modules_directory == true) {
Copy link
Member

Choose a reason for hiding this comment

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

I think we can avoid a parameter:

if '/usr/share/puppet/modules' in $puppet::server::common_modules_path {}

@bastelfreak
Copy link
Member Author

@ekohl I updated the code

Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

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

I think you can remove the WIP label

exec { 'mkdir -p /usr/share/puppet/modules':
creates => '/usr/share/puppet/modules',
path => ['/usr/bin', '/bin'],
if ('/usr/share/puppet/modules' in $puppet::server::common_modules_path) {
Copy link
Member

Choose a reason for hiding this comment

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

the parenthesis aren't needed

@bastelfreak bastelfreak changed the title [WIP] make foreman puppet module dir optional make foreman puppet module dir optional Jun 19, 2018
@mmoll mmoll merged commit 55cdf17 into theforeman:master Jun 19, 2018
@mmoll
Copy link
Contributor

mmoll commented Jun 19, 2018

merged, danke @bastelfreak!

@bastelfreak bastelfreak deleted the uselessdir branch June 20, 2018 19:29
@ekohl ekohl added the Bug label Jul 16, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants