Skip to content

Commit 0536e0c

Browse files
committed
Initial commit
0 parents  commit 0536e0c

File tree

4 files changed

+56
-0
lines changed

4 files changed

+56
-0
lines changed

.travis.yml

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
language: ruby
2+
3+
install:
4+
- gem install puppet-lint
5+
6+
script:
7+
- puppet-lint --fail-on-warnings --no-2sp_soft_tabs-check --no-hard_tabs-check --no-names_containing_dash-check --no-autoloader_layout-check --no-nested_classes_or_defines-check modules

README.md

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# igbinary
2+
3+
A Chassis extension to install and configure [igbinary](https://www.php.net/manual/en/book.igbinary.php) on your Chassis server.
4+
5+
## Global Installation
6+
7+
We recommend [installing this extension globally](http://docs.chassis.io/en/latest/extend/#globally-installing-extensions) to make it available on every Chassis box.
8+
9+
```
10+
git clone https://github.com/Chassis/igbinary ~/.chassis/extensions/igbinary
11+
```
12+
13+
## Project Installation
14+
15+
1. Add this extension to your extensions directory `git clone [email protected]:Chassis/igbinary.git extensions/igbinary` or alternatively add the following to one of your [`.yaml`](https://github.com/Chassis/Chassis/blob/master/config.yaml) files:
16+
```
17+
extensions:
18+
- chassis/igbinary
19+
```
20+
2. Set your `config.local.yaml` PHP version to 5.6 or higher.
21+
3. Run `vagrant provision`.

chassis.yaml

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Extension version.
2+
#
3+
# All modern extensions should use 2 here. Version 1 uses a chassis.pp
4+
# instead, which requires a deprecated feature of Puppet.
5+
#
6+
# Values: 2
7+
version: 2

modules/igbinary/manifests/init.pp

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# A Chassis extension to install and configure igbinary on your Chassis server
2+
class igbinary (
3+
$config,
4+
$path = '/vagrant/extensions/igbinary',
5+
$php_version = $config[php]
6+
) {
7+
# Install the gmp package
8+
if ( ! empty( $config[disabled_extensions] ) and 'chassis/igbinary' in $config[disabled_extensions] ) {
9+
$package = absent
10+
$file = absent
11+
} else {
12+
$package = latest
13+
$file = 'present'
14+
}
15+
16+
package { "php${php_version}-igbinary":
17+
ensure => $package,
18+
require => Package["php${php_version}-fpm", "php${php_version}-cli"],
19+
}
20+
21+
}

0 commit comments

Comments
 (0)