1
0
Fork 0
mirror of https://github.com/iiab/iiab.git synced 2025-02-12 19:22:24 +00:00

conventions accross platforms

This commit is contained in:
George Hunt 2017-05-29 19:37:12 -07:00
parent 9376910f7f
commit 70c9f95383
5 changed files with 33 additions and 11 deletions

View file

@ -2,6 +2,7 @@ dependencies:
- { role: mysql, tags: ['generic','mysql'], when: mysql_install } - { role: mysql, tags: ['generic','mysql'], when: mysql_install }
- { role: elgg, tags: ['generic','elgg'], when: elgg_install } - { role: elgg, tags: ['generic','elgg'], when: elgg_install }
- { role: owncloud, tags: ['generic','owncloud'], when: owncloud_install } - { role: owncloud, tags: ['generic','owncloud'], when: owncloud_install }
- { role: nextcloud, tags: ['generic','nextcloud'], when: nextcloud_install }
- { role: dokuwiki, tags: ['generic','dokuwiki'], when: dokuwiki_install } - { role: dokuwiki, tags: ['generic','dokuwiki'], when: dokuwiki_install }
- { role: wordpress, tags: ['generic','wordpress'], when: wordpress_install } - { role: wordpress, tags: ['generic','wordpress'], when: wordpress_install }
- { role: calibre, tags: ['generic','calibre'], when: calibre_install } - { role: calibre, tags: ['generic','calibre'], when: calibre_install }

View file

@ -5,7 +5,7 @@ nextcloud_url: /nextcloud
nextcloud_prefix: /opt nextcloud_prefix: /opt
nextcloud_data_dir: /library/nextcloud/data nextcloud_data_dir: /library/nextcloud/data
nextcloud_dl_url: https://download.nextcloud.com/server/releases/ nextcloud_dl_url: https://download.nextcloud.com/server/releases/
nextcloud_src_file: latest-11.tar.bz2 nextcloud_src_file: latest-12.tar.bz2
# we install on mysql with these setting or those from default_vars, etc. # we install on mysql with these setting or those from default_vars, etc.
nextcloud_dbname: nextcloud nextcloud_dbname: nextcloud

View file

@ -16,17 +16,31 @@
tags: tags:
- download - download
- name: Install list of packages for debuntu
apt: name={{ item }} state=installed
with_items:
- libapache2-mod-php5
- php{{ php_version }}-gd
- php{{ php_version }}-json
- php{{ php_version }}-mysql
- php{{ php_version }}-curl
- php{{ php_version }}-intl
- php{{ php_version }}-mcrypt
- php{{ php_version }}-imagick
when: is_debuntu
- name: Install list of packages - name: Install list of packages
apt: name={{ item }} state=installed apt: name={{ item }} state=installed
with_items: with_items:
- libapache2-mod-php5 - libapache2-mod-php5
- php5-gd - php-gd
- php5-json - php-json
- php5-mysql - php-mysql
- php5-curl - php-curl
- php5-intl - php-intl
- php5-mcrypt - php-mcrypt
- php5-imagick - php-imagick
when: is_redhat
- name: Copy it to permanent location /opt - name: Copy it to permanent location /opt
unarchive: src={{ downloads_dir }}/{{ nextcloud_src_file }} unarchive: src={{ downloads_dir }}/{{ nextcloud_src_file }}
@ -43,6 +57,7 @@
- name: in Centos, the following config dir is symlink to /etc/nextcloud - name: in Centos, the following config dir is symlink to /etc/nextcloud
file: path=/etc/nextcloud file: path=/etc/nextcloud
state=directory state=directory
when: is_centos
- name: Add autoconfig file - name: Add autoconfig file
template: src=autoconfig.php.j2 template: src=autoconfig.php.j2
@ -50,6 +65,7 @@
owner={{ apache_user }} owner={{ apache_user }}
group=apache group=apache
mode=0640 mode=0640
when: is_centos
- name: Make apache owner - name: Make apache owner
file: path={{ nextcloud_prefix }}/nextcloud file: path={{ nextcloud_prefix }}/nextcloud
@ -86,8 +102,8 @@
# Enable nextcloud by copying template to httpd config # Enable nextcloud by copying template to httpd config
# following enables and disables
- include: nextcloud_enabled.yml - include: nextcloud_enabled.yml
when: nextcloud_enabled
- name: Add nextcloud to service list - name: Add nextcloud to service list
ini_file: dest='{{ service_filelist }}' ini_file: dest='{{ service_filelist }}'

View file

@ -11,12 +11,17 @@
owner=root owner=root
group=root group=root
mode=0644 mode=0644
when: nextcloud_enabled
- name: For redhat, remove the config file
file: path=/etc/{{ apache_config_dir }}/nextcloud.conf
state=absent
- name: Enable nextcloud - name: Enable nextcloud
file: path=/etc/apache2/sites-enabled/nextcloud.conf file: path=/etc/apache2/sites-enabled/nextcloud.conf
src=/etc/apache2/sites-available/nextcloud.conf src=/etc/apache2/sites-available/nextcloud.conf
state=link state=link
when: nextcloud_enabled and is_debian when: nextcloud_enabled and is_debuntu
- name: Disable nextcloud - name: Disable nextcloud
file: path=/etc/apache2/sites-enabled/nextcloud.conf file: path=/etc/apache2/sites-enabled/nextcloud.conf

View file

@ -193,7 +193,7 @@ elgg_enabled: False
elgg_mysql_password: elgg4kids elgg_mysql_password: elgg4kids
# OwnCloud # OwnCloud
owncloud_install: True owncloud_install: False
owncloud_enabled: False owncloud_enabled: False
# WordPress # WordPress