Project

General

Profile

Actions

Bug #7909

closed

Importing Environments

Added by Riley Shott almost 10 years ago. Updated over 9 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
Puppet
Target version:
-
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Smart-Proxy should support the use of using solely environmentpath in puppet.conf to import directory environments. Currently it only looks for modulepath, which has been deprecated.

https://docs.puppetlabs.com/references/latest/configuration.html#modulepath

As an alternative I would try to import our environments using the API, but that seems to be broken in our setup. For the curious:

http://pastie.org/private/nuz3rx6hpneqnegwnzqhq

Actions #1

Updated by Riley Shott almost 10 years ago

Also, if it helps, this is what our config/settings.d/puppet.yml looks like:

---
:enabled: true

:puppet_conf: /etc/puppet/puppet.conf

  1. URL of the puppet master itself for API requests
    #:puppet_url: https://[haproxy_loadbalancer]:8140
  2. SSL certificates used to access the puppet master API
    #:puppet_ssl_ca: /var/lib/puppet/ssl/certs/ca.pem
    #:puppet_ssl_cert: /var/lib/puppet/ssl/certs/[name].pem
    #:puppet_ssl_key: /var/lib/puppet/ssl/private_keys/[name].pem
  1. Override use of Puppet's API to list environments, by default it will use only if
  2. environmentpath is given in puppet.conf, else will look for environments in puppet.conf
    :puppet_use_environment_api: false
Actions #2

Updated by Riley Shott almost 10 years ago

Bah...

---
:enabled: true

:puppet_conf: /etc/puppet/puppet.conf

# URL of the puppet master itself for API requests
#:puppet_url: https://[haproxy_loadbalancer]:8140
# SSL certificates used to access the puppet master API
#:puppet_ssl_ca: /var/lib/puppet/ssl/certs/ca.pem
#:puppet_ssl_cert: /var/lib/puppet/ssl/certs/[name].pem
#:puppet_ssl_key: /var/lib/puppet/ssl/private_keys/[name].pem

# Override use of Puppet's API to list environments, by default it will use only if
# environmentpath is given in puppet.conf, else will look for environments in puppet.conf
:puppet_use_environment_api: false
Actions #3

Updated by Corey Osman over 9 years ago

Can this be closed?

Actions #4

Updated by Dominic Cleal over 9 years ago

  • Status changed from New to Feedback

Yeah, the API option is what is supposed to work with environmentpath (directory environments). The error in the pastebin shows the following response from Puppet:

{"message":"Server Error: Invalid line 31: allow \n", ...

Which I'd suggest is just a configuration error in /etc/puppet/auth.conf.

(I don't intend to reimplement the 'modulepath' logic for directory envs, I'd prefer to rely on the API so we're more configuration agnostic.)

Actions #5

Updated by Riley Shott over 9 years ago

This can be closed. Dominic was right, I realized soon after posting that it was an error in my auth.conf. My apologies for not reporting back.

Actions #6

Updated by Dominic Cleal over 9 years ago

  • Status changed from Feedback to Resolved

Thanks for confirming!

Actions

Also available in: Atom PDF