FAQ
HI.

Firstly, I'm bound to be doing something utterly basically wrong here, so
if I am I apologise.

Right now I have a fairly simple setup where the JAR files for a
Weblogic-based application server are stored in the file server on my
Puppet Master. I run scripts on the client that downloads the files from
the file server, puts them in the right place etc etc. All very simple. I
am now trying to automate the other side, getting the files into the file
server. I've looked all over the place online and I just can't seem to find
any answers.

Basically, the JAR files are in a zip file on another server. Right now I
have to manually download it and place the files in the right place on the
file server. Instead I'd like Puppet to do this for me.

The awkward bit is that due to annoying internal office politics this not
only has to be done by a script being run (puppetd -onetime) but it should
be run on the client (due to access control for who may have to run the
scripts) and not on the Puppet Master. So is there any way to, from a
client, trigger the Puppet Master to download a file to update the files on
the file server? I realise that what could be done is that the client
downloads the zip locally, instead of from the file server, but ideally I'd
like to download only once due to the possibility of changes being made to
the zip file between downloads.

Thanks in advance to anyone that can help or point out what I
am doing wrong ;o)

/Mark

--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/-L_tagstm-sJ.
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.

Search Discussions

  • Brian Gallew at Jun 12, 2012 at 7:44 pm
    So, yeah, you're doing it wrong.

    Really, you probably want to be running something like archiva and have the
    clients install from there, but I'm going to guess that's not really
    possible for you.

    I presume that "done by a script being run (puppetd -onetime) but it should
    be run on the client" really means, "run on the puppet client that is
    actually either the build server or some destination host". If that's the
    case, the script could be an scp (with the right ssh keys installs), or a
    copy to an NFS-mounted filesystem. Theoretically, it's also possible to
    set up a Puppet file server on the client in question, in which case the
    file can just be moved around locally, but I have no experience with
    actually doing that.
    On Tue, Jun 12, 2012 at 7:50 AM, Mark Baxter wrote:

    HI.

    Firstly, I'm bound to be doing something utterly basically wrong here, so
    if I am I apologise.

    Right now I have a fairly simple setup where the JAR files for a
    Weblogic-based application server are stored in the file server on my
    Puppet Master. I run scripts on the client that downloads the files from
    the file server, puts them in the right place etc etc. All very simple. I
    am now trying to automate the other side, getting the files into the file
    server. I've looked all over the place online and I just can't seem to find
    any answers.

    Basically, the JAR files are in a zip file on another server. Right now I
    have to manually download it and place the files in the right place on the
    file server. Instead I'd like Puppet to do this for me.

    The awkward bit is that due to annoying internal office politics this not
    only has to be done by a script being run (puppetd -onetime) but it should
    be run on the client (due to access control for who may have to run the
    scripts) and not on the Puppet Master. So is there any way to, from a
    client, trigger the Puppet Master to download a file to update the files on
    the file server? I realise that what could be done is that the client
    downloads the zip locally, instead of from the file server, but ideally I'd
    like to download only once due to the possibility of changes being made to
    the zip file between downloads.

    Thanks in advance to anyone that can help or point out what I
    am doing wrong ;o)

    /Mark

    --
    You received this message because you are subscribed to the Google Groups
    "Puppet Users" group.
    To view this discussion on the web visit
    https://groups.google.com/d/msg/puppet-users/-/-L_tagstm-sJ.
    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.
    --
    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.
  • Nan Liu at Jun 14, 2012 at 4:41 pm

    On Tue, Jun 12, 2012 at 7:50 AM, Mark Baxter wrote:
    HI.

    Firstly, I'm bound to be doing something utterly basically wrong here, so if
    I am I apologise.

    Right now I have a fairly simple setup where the JAR files for a
    Weblogic-based application server are stored in the file server on my Puppet
    Master. I run scripts on the client that downloads the files from the file
    server, puts them in the right place etc etc. All very simple. I am now
    trying to automate the other side, getting the files into the file server.
    I've looked all over the place online and I just can't seem to find any
    answers.
    Yeah, unfortunately your situation isn't unique.
    Basically, the JAR files are in a zip file on another server. Right now I
    have to manually download it and place the files in the right place on the
    file server. Instead I'd like Puppet to do this for me.
    There's two ways to do this. One deploy in two stages:

    1. Write a manifests so the puppet master fetch new jar files to the
    modules directory and extract it.

    staging::deploy { 'dukesbank.zip':
    source => 'http://buildserver/jar/dukesbank1.0.zip',
    target => '/etc/puppet/modules/dukesbank/files/',
    }

    2. Trigger a puppet agent run on the client to fetch new files from
    puppet master (i.e. mco).
    The awkward bit is that due to annoying internal office politics this not
    only has to be done by a script being run (puppetd -onetime) but it should
    be run on the client (due to access control for who may have to run the
    scripts) and not on the Puppet Master. So is there any way to, from a
    client, trigger the Puppet Master to download a file to update the files on
    the file server? I realise that what could be done is that the client
    downloads the zip locally, instead of from the file server, but ideally I'd
    like to download only once due to the possibility of changes being made to
    the zip file between downloads.
    The second method is you ask development to version the file. You can
    use something like puppet-staging to bring files from your build
    server directly to the puppet agent:

    staging::file { 'dukesbank.jar':
    source => 'http://buildserver/jar/dukesbank1.0.jar',
    }

    I was experimenting with hiera lookup with these modules and haven't
    had time to get them in a publishable state. There's a bit of
    dependencies, but you can take a look and get some ideas:
    https://github.com/nanliu/puppet-staging
    https://github.com/nanliu/puppet-jboss/blob/master/manifests/deploy.pp
    https://github.com/nanliu/puppet-dukesbank/blob/master/manifests/jboss.pp

    Since puppet 3.0 will support hiera lookup, I'm planning to remove
    heira functions from the staging module and move the repo to
    puppetlabs after it gets some review.

    Thanks,

    Nan

    --
    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.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppuppet-users @
categoriespuppet
postedJun 12, '12 at 2:50p
activeJun 14, '12 at 4:41p
posts3
users3
websitepuppetlabs.com

People

Translate

site design / logo © 2022 Grokbase