Hi,

I have created a new environment for windows server, but the agent does not 
use it. Can somebody please help me?

message on agent run:
puppet local environment windows doesn't match server specified node 
environment switching agent to production

puppet.conf of windows agent

    [main]
    server=puppet-simu.baag
    ca_server=puppet1-simu.baag
    autoflush=true

    [agent]
    environment=windows
    pluginsync=true

puppet.conf of master
[main]
    autosign        = $confdir/autosign.conf { mode = 664 }
    environmentpath = $confdir/environments
    logdir          = /var/log/puppet
    rundir          = /var/run/puppet
    ssldir          = $vardir/ssl
    privatekeydir   = $ssldir/private_keys { group = service }
    hostprivkey     = $privatekeydir/$certname.pem { mode = 640 }
    pluginsync      = true

[agent]
    classfile         = $vardir/classes.txt
    localconfig       = $vardir/localconfig
    default_schedules = false
    report            = true
    pluginsync        = true
    masterport        = 8140
    environment       = production
    certname          = sv2655.muc.baag
    dns_alt_names     = puppet-simu.baag, puppet1-simu.baag
    server            = sv2655.muc.baag
    listen            = false
    splay             = false
    runinterval       = 1800
    noop              = false
    show_diff         = false

[master]
    autosign       = $confdir/autosign.conf { mode = 664 }
    reports        = foreman
    external_nodes = /etc/puppet/node.rb
    node_terminus  = exec
    ca             = true
    ssldir         = /var/lib/puppet/ssl

cat environment.conf 
config_version = /usr/bin/git --git-dir /data/git/windows/.git show --stat 
| head -1| cut -d" " -f2
manifest       = /data/git/windows/manifests
modulepath     = /data/git/windows/modules

# pwd
/etc/puppet/environments
# ls -l
total 20
drwxr-xr-x 2 root root 4096 Oct 18  2013 common
drwxr-xr-x 3 root root 4096 Oct 18  2013 development
drwxr-xr-x 4 root root 4096 Sep 21 09:48 example_env
drwxr-xr-x 3 root root 4096 Sep 21 10:09 production
drwxr-xr-x 2 root root 4096 Sep 22 08:48 windows

# pwd
/data/git/windows/manifests

# ls -l
total 4
-rw-rw-r-- 1 gitwin gitwin  23 Sep 22 08:41 nodes.pp
-rw-rw-r-- 1 gitwin gitwin 195 Sep 22 08:41 site.pp
# cat site.pp
node default {
  notify { 'Server ist noch nicht in Puppet definiert': }
}
if versioncmp($::puppetversion, '3.6.0') >= 0 {
  Package {
    allow_virtual => true,
  }
}
hiera_include('classes')

# cat nodes.pp
node 'vm7523.baag' {
}

Best regards,
Andreas

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/3b134331-5c38-47b4-bef5-9dd467318b4a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to