Forge Home

apaxy

A puppet module that manages Apaxy

8,924 downloads

8,714 latest version

3.8 quality score

We run a couple of automated
scans to help you access a
module's quality. Each module is
given a score based on how well
the author has formatted their
code and documentation and
modules are also checked for
malware using VirusTotal.

Please note, the information below
is for guidance only and neither of
these methods should be considered
an endorsement by Puppet.

Version information

  • 0.1.1 (latest)
  • 0.1.0
released Nov 21st 2013

Start using this module

  • r10k or Code Manager
  • Bolt
  • Manual installation
  • Direct download

Add this module to your Puppetfile:

mod 'Aethylred-apaxy', '0.1.1'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add Aethylred-apaxy
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install Aethylred-apaxy --version 0.1.1

Direct download is not typically how you would use a Puppet module to manage your infrastructure, but you may want to download the module in order to inspect the code.

Download

Documentation

Aethylred/apaxy — version 0.1.1 Nov 21st 2013

apaxy

Build Status

This Puppet module installs and configures a HTTP file directory with the Apaxy theme.

Usage

Apaxy on the document root

The following puppet code will put Apaxy on the root document of a web server, replacing the default web site.

class{'apache':
  default_vhost     => false,
  default_ssl_vhost => true,
}
include apaxy
apaxy::theme{'default':
  manage_vhost => true,
}

Resources

apaxy

The apaxy class uses git to clone a local repository of Apaxy from a repository. An alternative repository or git revision can be specified by parameters.

Parameters

  • install_dir: setting this will change where Apaxy is cloned to. The default is to use /var/opt/apaxy
  • source: setting this will change the source URI used by git to clone Apaxy. The default is to use the Apaxy Github repository
  • revision: This can be set to a branch name, tag or commit hash to specify which revision of the Apaxy repository is to be cloned. It defaults to the head of the master branch.

apaxy::theme

The apaxy::theme resource copies the clone from the local repository created by the apaxy class into a directory of a web site. Currently it applies the apaxy theme by putting a .htaccess file into the specified directory. These should really be in the site vhost.conf file, but the Puppetlabs Apache Module is not yet complete enough to do this. Fortunatly, when this changes the module will transparently change this over.

Parameters

  • docroot: this is the toplevel root directory where the Apaxy theme is to be installed. The Apaxy theme will apply to this directory and all it's subdirectories. By default it will be applied to the document root specified by the docroot of the apache class from the Puppetlabs Apache Module, which is OS dependent.
  • header_source: Setting this will replace the default header.html template with the file from the specified source. This source parameter is handled as the source attribute of the puppet file resource.
  • footer_source: Setting this will replace the default footer.html template with the file from the specified source. This source parameter is handled as the source attribute of the puppet file resource.
  • manage_vhost: If this is set to true, the apaxy::theme resource will create an apaxy::vhost which will deploy and enable the Apaxy site.

Custom vhost

There must be an AllowOverride all declaration in an Apaxy site's vhost.conf to enable the Apaxy theme. This should appear in the <Directory $docroot> block, where $docroot matches what's passed as the docroot parameter to apaxy::theme. This vhost.conf file should be managed by using the apache::vhost resource from the Puppetlabs Apache Module. An example apache::vhost declaration is given below:

class{'apache':
  default_vhost     => false,
  default_ssl_vhost => true,
}
include apaxy
apaxy::theme{'default': }
apache::vhost { 'default':
  port            => 80,
  docroot         => $docroot,
  access_log_file => 'apaxy_access.log',
  directories     => [
    {
      path           => $docroot,
      allow_override => ['all'],
    },
  ],
  priority        => '15',
  require => Apaxy::Theme['default'],
}

Dependencies

To Do

  • Remove the need for a .htaccess file and incorporate the Apaxy configuration directly into the site vhost.conf file. Needs Alias and AliasMatch directives to be properly implemented into the Puppetlabs Apache Module, see #483 and it's corresponding pull request.

Attribution

The puppet-apaxy module was written by Aaron Hicks (2013).

Apaxy

Apaxy was written and is maintained by Adam Whitcroft.

puppet-blank

This module is derived from the puppet-blank module by Aaron Hicks (aethylred@gmail.com)

This module has been developed for the use with Open Source Puppet (Apache 2.0 license) for automating server & service deployment.

rspec-puppet-augeas

This module includes the Travis configuration to use rspec-puppet-augeas to test and verify changes made to files using the augeas resource available in Puppet. Check the rspec-puppet-augeas documentation for usage.

This will require a copy of the original input files to spec/fixtures/augeas using the same filesystem layout that the resource expects:

$ tree spec/fixtures/augeas/
spec/fixtures/augeas/
`-- etc
    `-- ssh
        `-- sshd_config

Gnu General Public License

GPL3

This file is part of the apaxy Puppet module.

The apaxy Puppet module is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

The apaxy Puppet module is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with the apaxy Puppet module. If not, see http://www.gnu.org/licenses/.