Rameses Mss
2010-Dec-14 15:39 UTC
[Puppet Users] Environment specified by external nodes ignored
My custom external nodes script sets the environment variable, but Puppet ignores it. For testing, I have a manifest that deploys this template to a file: environment = <%= environment %> The output from my external nodes script: --- classes: - devhost environment: development parameters: memcached_memory: ''32'' But running "puppetd --test" results in the file''s contents: environment = production Why is my external nodes environment being ignored? -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Rameses Mss
2010-Dec-14 15:39 UTC
[Puppet Users] Re: Environment specified by external nodes ignored
Oops, this is Puppet 0.25.5 on Ubuntu 10.04 LTS. On Tue, Dec 14, 2010 at 10:39 AM, Rameses Mss <rmss60287@gmail.com> wrote:> My custom external nodes script sets the environment variable, but Puppet > ignores it. > > For testing, I have a manifest that deploys this template to a file: > environment = <%= environment %> > > The output from my external nodes script: > --- > classes: > - devhost > environment: development > parameters: > memcached_memory: ''32'' > > But running "puppetd --test" results in the file''s contents: > environment = production > > Why is my external nodes environment being ignored? > > > >-- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Nigel Kersten
2010-Dec-14 16:22 UTC
Re: [Puppet Users] Environment specified by external nodes ignored
On Tue, Dec 14, 2010 at 7:39 AM, Rameses Mss <rmss60287@gmail.com> wrote:> My custom external nodes script sets the environment variable, but Puppet > ignores it. > > For testing, I have a manifest that deploys this template to a file: > environment = <%= environment %> > > The output from my external nodes script: > --- > classes: > - devhost > environment: development > parameters: > memcached_memory: ''32'' > > But running "puppetd --test" results in the file''s contents: > environment = production > > Why is my external nodes environment being ignored? >http://projects.puppetlabs.com/issues/3910> > > > -- > You received this message because you are subscribed to the Google Groups > "Puppet Users" group. > To post to this group, send email to puppet-users@googlegroups.com. > To unsubscribe from this group, send email to > puppet-users+unsubscribe@googlegroups.com<puppet-users%2Bunsubscribe@googlegroups.com> > . > For more options, visit this group at > http://groups.google.com/group/puppet-users?hl=en. >-- Nigel Kersten - Puppet Labs - http://www.puppetlabs.com -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Rameses Mss
2010-Dec-14 16:39 UTC
Re: [Puppet Users] Environment specified by external nodes ignored
On Tue, Dec 14, 2010 at 11:22 AM, Nigel Kersten <nigel@puppetlabs.com>wrote:> > > On Tue, Dec 14, 2010 at 7:39 AM, Rameses Mss <rmss60287@gmail.com> wrote: > >> My custom external nodes script sets the environment variable, but Puppet >> ignores it. >> >> For testing, I have a manifest that deploys this template to a file: >> environment = <%= environment %> >> >> The output from my external nodes script: >> --- >> classes: >> - devhost >> environment: development >> parameters: >> memcached_memory: ''32'' >> >> But running "puppetd --test" results in the file''s contents: >> environment = production >> >> Why is my external nodes environment being ignored? >> > > http://projects.puppetlabs.com/issues/3910 >My client is not specifying an environment. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Ohad Levy
2010-Dec-14 17:01 UTC
Re: [Puppet Users] Environment specified by external nodes ignored
On Tue, Dec 14, 2010 at 6:39 PM, Rameses Mss <rmss60287@gmail.com> wrote:> On Tue, Dec 14, 2010 at 11:22 AM, Nigel Kersten <nigel@puppetlabs.com>wrote: > >> >> >> On Tue, Dec 14, 2010 at 7:39 AM, Rameses Mss <rmss60287@gmail.com> wrote: >> >>> My custom external nodes script sets the environment variable, but Puppet >>> ignores it. >>> >>> For testing, I have a manifest that deploys this template to a file: >>> environment = <%= environment %> >>> >>> The output from my external nodes script: >>> --- >>> classes: >>> - devhost >>> environment: development >>> parameters: >>> memcached_memory: ''32'' >>> >>> But running "puppetd --test" results in the file''s contents: >>> environment = production >>> >>> Why is my external nodes environment being ignored? >>> >> >> http://projects.puppetlabs.com/issues/3910 >> > > My client is not specifying an environment. >The problem here is that the puppet client request the catalog from a the master and encode the environment in the url, if none is defined, it fall backs to default = "production".... Ohad> -- > You received this message because you are subscribed to the Google Groups > "Puppet Users" group. > To post to this group, send email to puppet-users@googlegroups.com. > To unsubscribe from this group, send email to > puppet-users+unsubscribe@googlegroups.com<puppet-users%2Bunsubscribe@googlegroups.com> > . > For more options, visit this group at > http://groups.google.com/group/puppet-users?hl=en. >-- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Rameses Mss
2010-Dec-14 17:05 UTC
Re: [Puppet Users] Environment specified by external nodes ignored
On Tue, Dec 14, 2010 at 12:01 PM, Ohad Levy <ohadlevy@gmail.com> wrote:> > On Tue, Dec 14, 2010 at 6:39 PM, Rameses Mss <rmss60287@gmail.com> wrote: > >> On Tue, Dec 14, 2010 at 11:22 AM, Nigel Kersten <nigel@puppetlabs.com>wrote: >> >>> >>> >>> On Tue, Dec 14, 2010 at 7:39 AM, Rameses Mss <rmss60287@gmail.com>wrote: >>> >>>> My custom external nodes script sets the environment variable, but >>>> Puppet ignores it. >>>> >>>> For testing, I have a manifest that deploys this template to a file: >>>> environment = <%= environment %> >>>> >>>> The output from my external nodes script: >>>> --- >>>> classes: >>>> - devhost >>>> environment: development >>>> parameters: >>>> memcached_memory: ''32'' >>>> >>>> But running "puppetd --test" results in the file''s contents: >>>> environment = production >>>> >>>> Why is my external nodes environment being ignored? >>>> >>> >>> http://projects.puppetlabs.com/issues/3910 >>> >> >> My client is not specifying an environment. >> > The problem here is that the puppet client request the catalog from a the > master and encode the environment in the url, if none is defined, it fall > backs to default = "production".... > > Ohad >Ah. So if using external nodes, I don''t get to use the environment variable in my templates. Ick. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Nigel Kersten
2010-Dec-14 17:09 UTC
Re: [Puppet Users] Environment specified by external nodes ignored
On Tue, Dec 14, 2010 at 9:05 AM, Rameses Mss <rmss60287@gmail.com> wrote:> On Tue, Dec 14, 2010 at 12:01 PM, Ohad Levy <ohadlevy@gmail.com> wrote: > >> >> On Tue, Dec 14, 2010 at 6:39 PM, Rameses Mss <rmss60287@gmail.com> wrote: >> >>> On Tue, Dec 14, 2010 at 11:22 AM, Nigel Kersten <nigel@puppetlabs.com>wrote: >>> >>>> >>>> >>>> On Tue, Dec 14, 2010 at 7:39 AM, Rameses Mss <rmss60287@gmail.com>wrote: >>>> >>>>> My custom external nodes script sets the environment variable, but >>>>> Puppet ignores it. >>>>> >>>>> For testing, I have a manifest that deploys this template to a file: >>>>> environment = <%= environment %> >>>>> >>>>> The output from my external nodes script: >>>>> --- >>>>> classes: >>>>> - devhost >>>>> environment: development >>>>> parameters: >>>>> memcached_memory: ''32'' >>>>> >>>>> But running "puppetd --test" results in the file''s contents: >>>>> environment = production >>>>> >>>>> Why is my external nodes environment being ignored? >>>>> >>>> >>>> http://projects.puppetlabs.com/issues/3910 >>>> >>> >>> My client is not specifying an environment. >>> >> The problem here is that the puppet client request the catalog from a the >> master and encode the environment in the url, if none is defined, it fall >> backs to default = "production".... >> >> Ohad >> > > Ah. So if using external nodes, I don''t get to use the environment variable > in my templates. Ick. >No, you just need to set the environment client-side and not in the classifier. There are ways around this bug, it''s just really annoying. How do you make the environment determination now? -- Nigel Kersten - Puppet Labs - http://www.puppetlabs.com -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Rameses Mss
2010-Dec-14 17:27 UTC
Re: [Puppet Users] Environment specified by external nodes ignored
On Tue, Dec 14, 2010 at 12:09 PM, Nigel Kersten <nigel@puppetlabs.com>wrote:> > > On Tue, Dec 14, 2010 at 9:05 AM, Rameses Mss <rmss60287@gmail.com> wrote: > >> On Tue, Dec 14, 2010 at 12:01 PM, Ohad Levy <ohadlevy@gmail.com> wrote: >> >>> >>> On Tue, Dec 14, 2010 at 6:39 PM, Rameses Mss <rmss60287@gmail.com>wrote: >>> >>>> On Tue, Dec 14, 2010 at 11:22 AM, Nigel Kersten <nigel@puppetlabs.com>wrote: >>>> >>>>> >>>>> >>>>> On Tue, Dec 14, 2010 at 7:39 AM, Rameses Mss <rmss60287@gmail.com>wrote: >>>>> >>>>>> My custom external nodes script sets the environment variable, but >>>>>> Puppet ignores it. >>>>>> >>>>>> For testing, I have a manifest that deploys this template to a file: >>>>>> environment = <%= environment %> >>>>>> >>>>>> The output from my external nodes script: >>>>>> --- >>>>>> classes: >>>>>> - devhost >>>>>> environment: development >>>>>> parameters: >>>>>> memcached_memory: ''32'' >>>>>> >>>>>> But running "puppetd --test" results in the file''s contents: >>>>>> environment = production >>>>>> >>>>>> Why is my external nodes environment being ignored? >>>>>> >>>>> >>>>> http://projects.puppetlabs.com/issues/3910 >>>>> >>>> >>>> My client is not specifying an environment. >>>> >>> The problem here is that the puppet client request the catalog from a the >>> master and encode the environment in the url, if none is defined, it fall >>> backs to default = "production".... >>> >>> Ohad >>> >> >> Ah. So if using external nodes, I don''t get to use the environment >> variable in my templates. Ick. >> > > No, you just need to set the environment client-side and not in the > classifier. > > There are ways around this bug, it''s just really annoying. How do you make > the environment determination now? > > -- > Nigel Kersten - Puppet Labs - http://www.puppetlabs.com >It''s stored in a database on the puppetmaster that''s used as the source for a bunch of other scripts. The client doesn''t have access to the information, sadly. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.