Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
HTPasswd management using Puppet
<% @accounts.each do |user, password| -%>
<%= user %>:<%= scope.call_function('apache_pw_hash', [password]) %>
<% end -%>
# @summary Manages a HTPasswd file
# @param [String] filename The name and path of the htpasswd file
# @param [Hash] accounts The accounts to manage (username => password)
class profiles::htpasswd (
String $filename,
Hash $accounts
) {
file {
content => template("${module_name}/htpasswd/htpasswd.erb")

This comment has been minimized.

Copy link
Owner Author

dploeger commented Sep 19, 2018

Based on this Blog post

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.