Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7062607
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T04:36:51+00:00 2026-05-28T04:36:51+00:00

I have an app written in PHP, MySQL, etc. The app has a few

  • 0

I have an app written in PHP, MySQL, etc. The app has a few dependencies such as beanstalkd, Solr and a few PHP extensions.

For each customer we have a separate installation of the app, either on a server shared with other customers or on a server with only that customer.

For now we’re using a Puppet script to bootstrap new customers and then we manually go to each customer to make a git pull, update the db, etc., whenever something changes.

What we’re looking for is really a tool that has as many of the following features as possible:

  1. Web interface that allows us to see all customers and their current revision
  2. Ability to bootstrap new installations
  3. Ability to update existing installations to a specific revision or branch

We’re not looking for a tool to bootstrap new servers – we still do that manually. Instead we’re looking for a way to automate the setup of clients on an existing server.

Would Chef or Puppet be sufficient for this, is there a more suitable tool, or would you recommend rolling something ourselves?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T04:36:52+00:00Added an answer on May 28, 2026 at 4:36 am

    I’m a full time developer working on Puppet at Puppet Labs. I’m also the co-author of Pro Puppet.

    Puppet is certainly sufficient for your goals. Here’s one way to solve this problem using Puppet. First, I’ll address the dependency management since these should only be managed once regardless of how many instances of the application are being managed. Then, I’ll address how to handle multiple installations of your app using a defined resource type in Puppet and the vcsrepo resource type.

    First, regarding the organization of the puppet code to handle multiple installations of the same app. The dependencies you mention such as beanstalkd, solr, and the PHP extensions should be modeled using a Puppet class. This class will be included in the configuration catalog only once, regardless of how many copies of the application are managed on the node. An example of this class might be something like:

    # <modulepath>/site/manifests/app_dependencies.pp
    class site::app_dependencies {
      # Make all package resources in this class default to
      # being managed as installed on the node
      Package { ensure => installed }
      # Now manage the dependencies
      package { 'php': }
      package { 'solr': }
      package { 'beanstalk': }
      # The beanstalk worker queue service needs to be running
      service { 'beanstalkd':
        ensure  => running,
        require => Package['beanstalk'],
      }
    }
    

    Now that you have your dependencies in a class, you can simply include this class on the nodes where your application will be deployed. This usually happens in the site.pp file or in the Puppet Dashboard if you’re using the web interface.

    # $(puppet config print confdir)/manifests/site.pp
    node www01 {
      include site::app_dependencies
    }
    

    Next, you need a way to declare multiple instances of the application on the system. Unfortunately, there’s not an easy way to do this from a web interface right now but it is possible using Puppet manifests and a defined resource type. This solution uses the vcsrepo resource to manage the git repository checkout for the application.

    # <modulepath>/myapp/manifests/instance.pp
    define myapp::instance($git_rev='master') {
      # Resource defaults.  The owner and group might be the web
      # service account instead of the root account.
      File {
        owner => 0,
        group => 0,
        mode  => 0644,
      }
      # Create a directory for the app.  The resource title will be copied
      # into the $name variable when this resource is declared in Puppet
      file { "/var/lib/myapp/${name}":
        ensure => directory
      }
      # Check out the GIT repository at a specific version
      vcsrepo { "/var/lib/myapp/${name}/working_copy":
        ensure   => present,
        provider => git,
        source   => 'git://github.com/puppetlabs/facter.git',
        revision => $git_rev,
      }
    }
    

    With this defined resource type, you can declare multiple installations of your application like so:

    # $(puppet config print confdir)/manifests/site.pp
    node www01 {
      include site::app_dependencies
      # Our app instances always need their dependencies to be managed first.
      Myapp::Instance { require => Class['site::app_dependencies'] }
    
      # Multiple instances of the application
      myapp::instance { 'jeff.acme.com': git_rev => 'tags/1.0.0' }
      myapp::instance { 'josh.acme.com': git_rev => 'tags/1.0.2' }
      myapp::instance { 'luke.acme.com': git_rev => 'tags/1.1.0' }
      myapp::instance { 'teyo.acme.com': git_rev => 'master' }
    }
    

    Unfortunately, there’s not currently an easy to use out of the box way to make this information visible from a web GUI. It is certainly possible to do, however, using the External Node Classifier API. For more information about pulling external data into Puppet please see these resources:

    • External Nodes Documentation
    • R.I. Pienaar’s Hiera (Hierarchical data store)

    Hope this information helps.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have written a small chat app that uses mysql + php to facilitate
I have written a web app in PHP which makes use of Ajax requests
I have a GUI app written in C++/CLI which has a load of configurable
I have an existing app written in PHP (using Kohana framework) and I want
I have developed an app and its written in PHP (with a bunch of
I have a web application written in PHP. It uses MySQL for data storage.
I have a completed web app in PHP 5 + MySQL. I have not
Suppose my web app is written in PHP & Mysql on the standard LAMP
I have written a app in PHP on my localhost server using XAMP, which
In one app, I have an administrative backend written in PHP, which allows to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.