Commit de526386 authored by Matthieu FAURE's avatar Matthieu FAURE
Browse files

Merge branch 'use_nextcloud_module'

# Conflicts:
#	BUILD.sh
#	Puppetfile
#	manifests/default.pp
parents 05ab9fa3 c6f03662
#!/bin/bash
r10k puppetfile install -v
MY_PROJECT_NAME="puppet-nextcloud"
MY_MODULE_URL="git@gitlab.com:matt.faure/${MY_PROJECT_NAME}.git"
MY_REFSPEC="master"
MY_PUPPET_MODULE_NAME="nextcloud"
r10k puppetfile install -v \
&& cd modules \
&& git clone "${MY_MODULE_URL}" \
&& mv "${MY_PROJECT_NAME}" "${MY_PUPPET_MODULE_NAME}" \
&& cd "${MY_PUPPET_MODULE_NAME}" \
&& git checkout "${MY_REFSPEC}"
# Modules from Puppet (VoxPupuli): A -> Z
mod 'puppet-archive', '4.2.0'
mod 'puppet-php', '7.0.0'
mod 'puppet-zypprepo', '2.2.2'
mod 'puppet-archive', '4.2.0' # for php
mod 'puppet-php', '7.0.0' # DIRECT soft dependency
mod 'puppet-zypprepo', '2.2.2' # for php
# Modules from Puppetlabs: A -> Z
mod 'puppetlabs-apache', '5.0.0'
mod 'puppetlabs-apt', '7.1.0'
mod 'puppetlabs-concat', '6.1.0'
mod 'puppetlabs-inifile', '3.1.0'
mod 'puppetlabs-stdlib', '6.0.0'
mod 'puppetlabs-translate', '2.0.0'
mod 'puppetlabs-apache', '5.0.0' # DIRECT soft dependency
mod 'puppetlabs-apt', '7.1.0' # for php
mod 'puppetlabs-concat', '6.1.0' # for apache
mod 'puppetlabs-inifile', '3.1.0' # for php
mod 'puppetlabs-stdlib', '6.0.0' # DIRECT dependency
mod 'puppetlabs-translate', '2.0.0' # for concat
# Modules from others: A -> Z
$apache_hostname = 'nextcloud.example.org'
$apache_port = 80
$apache_docroot = '/var/www/html'
$apache_default_vhost = true
$php_version = '7.2'
$fastcgi_socket = 'fcgi://127.0.0.1:9000'
# See https://httpd.apache.org/docs/2.4/mod/mod_proxy_fcgi.html#examples
$_my_custom_fragment = "ProxyPassMatch ^/(.*\\.php)\$ ${fastcgi_socket}${apache_docroot}/ enablereuse=on"
$_phpinfo = "${apache_docroot}/t.php"
class { 'apache':
default_vhost => false,
default_ssl_vhost => false,
}
class { 'apache::mod::proxy': }
class { 'apache::mod::proxy_fcgi': }
apache::vhost { $apache_hostname:
docroot => $apache_docroot,
default_vhost => $apache_default_vhost,
port => $apache_port,
override => 'all',
custom_fragment => $_my_custom_fragment,
class { 'nextcloud':
manage_apache => true,
}
class { 'php::globals':
php_version => '7.2',
}
-> class { 'php':
extensions => {
apcu => {},
bz2 => {},
ctype => {},
curl => {},
dom => {},
# exif => {}, # already installed
gd => {},
iconv => {},
imagick => {},
intl => {},
json => {},
# fileinfo => {}, # already installed
# libxml => {}, # already installed
mbstring => {},
# openssl => {}, # already installed
mysql => {},
posix => {},
# session => {}, # already installed
simplexml => {},
xmlreader => {},
xmlwriter => {},
zip => {},
# zlib => {}, # already installed
},
}
# TODO configure APCu in NextCloud. See https://docs.nextcloud.com/server/16/admin_manual/configuration_server/caching_configuration.html#id1
file { 't.php':
path => $_phpinfo,
ensure => file,
......@@ -68,7 +12,3 @@ file_line { 'phpinfo':
path => $_phpinfo,
line => '<?php phpinfo(); ?>',
}
# Manage Redis
# Optionnally deal with Redis installation + configuration in NextCloud
# See https://docs.nextcloud.com/server/16/admin_manual/configuration_server/caching_configuration.html
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment