puppetlabs / puppetlabs/puppetlabs-apache

add Hash $vhosts_defaults to apache::vhosts class?

Open
#2,325 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

community feature
Dominant language
Puppet
Stars
356
Forks
1.1k
Avg merge
3m
Merged PRs (30d)
1

Description

Use Case

In our environment we have a some per-vhosts-settings which are identical in multiple vhosts. Therefore it would be great to be able to set defaults for multiple vhosts through the apache::vhosts class.

Describe the Solution You Would Like

add a parameter to the apache::vhosts class, that would be passed to the create_resources function:

Hash $vhosts_defaults = {},

Describe Alternatives You've Considered

Alternatively it would be possible to use resource defaults, but we have a Hiera-heavy setup on some nodes, where we just define the apache::vhosts::vhosts in Hiera and include the apache::vhosts class to make sure these get picked up and that would work more smoothly with a $vhosts_defaults parameter.

Additional Context

If there was nothing against implementing such a defaults Hash in principle, I'd try to create a pull request.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the apache::vhosts class and locate the create_resources call mentioned in the issue. Add the vhosts_defaults parameter and pass it to that call, then verify that defaults can be supplied alongside apache::vhosts::vhosts through Hiera.

Written by the indexing model from the issue text.

Assessment

Tech stack
apache
Domain
infrastructure
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.