default['hosts']['hostname'] = node['hostname'] ? node['hostname'] : 'localhost'
default['hosts']['domain'] = node['domain'] ? node['domain'] : 'localdomain'

# Create a 1Gb swap disk; the script is idempotent
# (if swap already exists, wont be created)
default['swap']['enabled'] = true
default['swap']['file_path'] = '/mnt/swapfile'
default['swap']['size'] = 4096

default['alfresco']['restart_services'] = %w(tomcat-alfresco tomcat-share tomcat-solr)
default['alfresco']['repo_tomcat_instance']['xmx_ratio'] = 0.28
default['alfresco']['share_tomcat_instance']['xmx_ratio'] = 0.22
default['alfresco']['solr_tomcat_instance']['xmx_ratio'] = 0.17

default['libreoffice']['initialise'] = true

# TODO: - use caching - instead of the following configurations - to avoid network issues
# when downloading JDK from oracle.com servers (curl exits with error 18)
#
# To update JDK on minislaven1:
# cd /srv/repos/third-party/
# curl --create-dirs -L --retry 5 --retry-delay 2 --cookie "oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u66-b17/jdk-8u66-linux-x64.tar.gz -o /root/.chef/local-mode-cache/cache/jdk-8u66-linux-x64.tar.gz --connect-timeout 600
# shasum -a 256 jdk-8u66-linux-x64.tar.gz
#
# default['java']['jdk']['8']['x86_64']['url'] = "http://yumuser:possum4passtop@minislaven1.alfresco.pri/third-party/jdk-8u66-linux-x64.tar.gz"
# default['java']['jdk']['8']['x86_64']['checksum'] = '7e95ad5fa1c75bc65d54aaac9e9986063d0a442f39a53f77909b044cef63dc0a'
