Skip to content
Snippets Groups Projects
Commit 75d5c208 authored by void's avatar void
Browse files

initiale konfiguration warphab mit homematic und openhab

parent 16304b87
No related branches found
No related tags found
No related merge requests found
...@@ -4,8 +4,22 @@ ...@@ -4,8 +4,22 @@
- name: create motd file - name: create motd file
template: src=motd.j2 dest=/etc/motd template: src=motd.j2 dest=/etc/motd
- name: install apt-transport-https packages before adding sources
apt:
pkg: "{{ item }}"
update_cache: yes
state: installed
with_items:
- apt-transport-https
- name: add debian repo keys
apt_key:
url: "{{ item }}"
state: present
with_items: "{{ debian_keys }}"
- name: set debian repos - name: set debian repos
template: src=sources.list.j2 dest=/etc/apt/sources.list template: src=sources.list.j2 dest=/etc/apt/sources.list
- name: install common packages - name: install common packages
apt: apt:
...@@ -13,10 +27,10 @@ ...@@ -13,10 +27,10 @@
update_cache: yes update_cache: yes
state: installed state: installed
with_items: with_items:
- psmisc
- tmux
- vim - vim
- wget - wget
- psmisc
- tree
- name: deploy sshd config - name: deploy sshd config
template: src=sshd_config.j2 dest=/etc/ssh/sshd_config template: src=sshd_config.j2 dest=/etc/ssh/sshd_config
......
# Gruppen-Spezifishe Variablen # Gruppen-Spezifishe Variablen
debian_sources:
- "deb http://mirrordirector.raspbian.org/raspbian/ jessie main contrib non-free rpi"
\ No newline at end of file
# Host spezifische Variablen # Host spezifische Variablen
debian_sources:
- "deb http://mirrordirector.raspbian.org/raspbian/ jessie main contrib non-free rpi"
administratorenteam: administratorenteam:
- "da1l6" - "da1l6"
- "larsm" - "larsm"
......
# Host spezifische Variablen
debian_sources:
- "deb http://mirrordirector.raspbian.org/raspbian/ jessie main contrib non-free rpi"
- "deb https://homegear.eu/packages/Raspbian/ jessie/"
- "deb http://dl.bintray.com/openhab/apt-repo2 testing main"
debian_keys:
- "https://homegear.eu/packages/Release.key"
- "https://bintray.com/user/downloadSubjectPublicKey?username=openhab"
administratorenteam:
- "user51"
- "void"
...@@ -20,3 +20,6 @@ webserver ansible_ssh_host=89.163.231.226 ...@@ -20,3 +20,6 @@ webserver ansible_ssh_host=89.163.231.226
# Vorstands-PI # Vorstands-PI
# Auch erreichbar unter vorstand.warpzone.ms # Auch erreichbar unter vorstand.warpzone.ms
vorstandspi ansible_ssh_host=10.0.0.206 vorstandspi ansible_ssh_host=10.0.0.206
# OpenHAB Server
warphab ansible_ssh_host=10.0.3.238
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCm7uTtTym/xEWwjvN1TCsvHMBAL82ml6+L7ju7eH3S0fkQ+lXUXJIhX6AQJhITqP7qUsBlM73bCDo0GcB/b8qlg1YaqkWaN8llJ9BwExvXqZ6IXfZj7F2eRwVknmgIY39H3NQt2pgZmX1VS0uK6dK7SGao43EUiZR6YqDg/rUIz8LMHDhiRyGaa5CFG3gUe5k4aXHiyYPmNhb5Q67PK8U2Shd2EW7C97eQBE0olGHYL0S2m4Z9dZ3S6q1wp/b1aFR7/LDzlGaHZYhrSuRQeBcVQcQFyy7gjFlXWJ3mAQHzdz/ldGuobPOSzG0h49J94sLET/Q2HodTD/QDzFmqLvgZ martin@W500.lan
\ No newline at end of file
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
- include: all/main.yml - include: all/main.yml
- include: vorstandspi/main.yml - include: vorstandspi/main.yml
- include: warphab/main.yml
- include: webserver/main.yml - include: webserver/main.yml
......
# Homegear configuration file
# Default: runAsUser = root
# runAsUser = homegear
# Default: runAsGroup = root
# runAsGroup = homegear
# Default: debugLevel = 3
debugLevel = 4
# Default: memoryDebugging = false
memoryDebugging = true
# Prints log information helping in fixing errors
# Default: devLog = false
devLog = false
# Set to false to disable core dumps. Currently to make fixing errors easier, core dumps are enabled by default.
# Default: enableCoreDumps = true
enableCoreDumps = true
# The working directory of Homegear. E. g. core dumps are written here. If workingDirectory is empty, the
# executable path is used.
# Default: workingDirectory =
workingDirectory = /var/lib/homegear
# The socket files are placed into this directory. If socketPath is empty, the executable path is used.
# Default: socketPath =
socketPath = /var/run/homegear
# If databasePath is empty, the executable path is used.
# Default: dataPath =
dataPath = /var/lib/homegear
# Default: dataPathPermissions = 770
# dataPathPermissions = 770
# Default: dataPathUser =
# dataPathUser = homegear
# Default: dataPathGroup =
# dataPathGroup = homegear
# If databaseMemoryJournal is set to true, database write operations are faster but if your system
# suffers a power loss the database might get corrupted.
# Default: databaseMemoryJournal = false
databaseMemoryJournal = false
# If databaseWALJournal is set to true database write operations are faster. This is more secure than
# settings databaseMemoryJournal. databaseWALJournal and databaseMemoryJournal cannot be used together.
# Default: databaseWALJournal = true
databaseWALJournal = true
# If databaseSynchronous is set to false database write operations are faster but if your system
# suffers a power loss the database might get corrupted.
# Default: databaseSynchronous = true
databaseSynchronous = true
# databaseMaxBackups defines the maximum number of database backups to create. When this number is reached,
# old backups are deleted.
# Default: databaseMaxBackups = 10
databaseMaxBackups = 10
# Default: logfilePath = /var/log/homegear
logfilePath = /var/log/homegear
# Enable
# Default: enableUPnP = true
enableUPnP = true
# Sets the IP address, the UPnP server listens on. By default auto discovery is used, but this might not work,
# if multiple interfaces exist. Only set specific IP addresses not "0.0.0.0".
# Default: uPnPIpAddress =
# uPnPIpAddress =
# Sets the IP address, the SSDP server listens on. By default auto discovery is used, but this might not work,
# if multiple interfaces exist. Only set specific IP addresses not "0.0.0.0".
# Default: ssdpIpAddress =
# ssdpIpAddress =
# Sets the port number, the SSDP server listens on. By default Homegear listens on port 1900, but this might not work,
# if other processes listen in this port as well.
# Default: ssdpPort = 1900
# ssdpPort =
#### SSL options ####
# You can create a new certificate pair with:
# openssl genrsa -out /etc/homegear/homegear.key 2048
# openssl req -new -key /etc/homegear/homegear.key -out /etc/homegear/homegear.csr
# openssl x509 -req -in /etc/homegear/homegear.csr -signkey /etc/homegear/homegear.key -out /etc/homegear/homegear.crt
# Default: certPath = /etc/homegear/homegear.crt
certPath = /etc/homegear/homegear.crt
# Default: keyPath = /etc/homegear/homegear.key
keyPath = /etc/homegear/homegear.key
# When "loadDHParamsFromFile" is set to "false", Diffie-Hellman parameters will be generated when Homegear starts.
# That actually is more secure, but the generation takes a long time on slow computers.
# Default: loadDHParamsFromFile = true
loadDHParamsFromFile = true
# Default: dhParamPath = /etc/homegear/dh1024.pem
dhParamPath = /etc/homegear/dh1024.pem
# Path to device description files
# Default: /etc/homegear/devices
deviceDescriptionPath = /etc/homegear/devices
# Path to the RPC clients event server settings file.
# Default: clientSettingsPath = /etc/homegear/rpcclients.conf
clientSettingsPath = /etc/homegear/rpcclients.conf
# Path to the RPC server settings file.
# Default: serverSettingsPath = /etc/homegear/rpcservers.conf
serverSettingsPath = /etc/homegear/rpcservers.conf
# Path to the MQTT settings file.
# Default: mqttSettingsPath = /etc/homegear/mqtt.conf
mqttSettingsPath = /etc/homegear/mqtt.conf
# Path to the device family config files.
# Default: familyConfigPath = /etc/homegear/families
familyConfigPath = /etc/homegear/families
# Path to php.ini.
# Default: phpIniPath = /etc/homegear/php.ini
phpIniPath = /etc/homegear/php.ini
# Path to the GPIO root directory. Only relevant if one of the physical devices needs GPIO access.
# Default: gpioPath = /sys/class/gpio
gpioPath = /sys/class/gpio
# Export these GPIOs and set permissions when running Homegear with "-s".
# exportGpios = 5, 6, 7
# Path to scripts which can be executed by calling "runScript"
# Default: scriptPath = /var/lib/homegear/scripts
scriptPath = /var/lib/homegear/scripts
# Default: scriptPathPermissions = 770
# scriptPathPermissions = 770
# Default: scriptPathUser =
# scriptPathUser = homegear
# Default: scriptPathGroup =
# scriptPathGroup = homegear
# Path to the family modules.
# Default: modulePath = /var/lib/homegear/modules
modulePath = /var/lib/homegear/modules
# Path to the directory with firmware updates
# Default: firmwarePath = /usr/share/homegear/firmware
firmwarePath = /usr/share/homegear/firmware
# Path to a directory where Homegear can store temporary data
# Default: tempPath = /var/lib/homegear/tmp
tempPath = /var/lib/homegear/tmp
# Some clients don't provide the option to set their hostname to
# "localhost" or "127.0.0.1" so a SSH tunnel normally wouldn't work.
# To redirect communication to a client's XML RPC event server through a
# SSH tunnel in this case, specify the client's XML RPC server address
# here. Homegear replaces the provided address (or hostname) with
# 127.0.0.1 (or ::1 when IPv6 is used). Multiple entries are allowed.
# redirectToSSHTunnel = 192.168.0.1
# redirectToSSHTunnel = fdef:abcd:bcda::1234
# redirectToSSHTunnel = 192.168.0.10
# redirectToSSHTunnel = MyHostname
# Some clients (like the CCU2) send localhost as address to a remote Homegear
# installation. Homegear then tries to connect to localhost which of course
# fails. As a workaround Homegear can replace the address sent from the client
# with a working address. $REMOTEIP is replaced automatically with the remote ip
# address.
# Address to search for Address to use
# | |
# V V
replaceClientServerAddress = xmlrpc_bin://127.0.0.1:1999 xmlrpc_bin://$REMOTEIP:1999
replaceClientServerAddress = http://127.0.0.1:9292/bidcos http://$REMOTEIP:9292/bidcos
#### !!!Don't change settings below unless you know exactly what you're doing!!! ####
#### !!!Don't change settings below unless you know exactly what you're doing!!! ####
#### !!!Don't change settings below unless you know exactly what you're doing!!! ####
# Default: prioritizeThreads = true
prioritizeThreads = true
# Default: workerThreadWindow = 3000
workerThreadWindow = 3000
# Default scriptEngineMaxThreadsPerScript = 4
scriptEngineMaxThreadsPerScript = 4
# Default scriptEngineMaxScriptsPerProcess = -1
scriptEngineMaxScriptsPerProcess = 50
# Default scriptEngineThreadCount = 10
scriptEngineThreadCount = 10
# Default: scriptEngineServerMaxConnections = 10
scriptEngineServerMaxConnections = 10
# Default: cliServerMaxConnections = 50
cliServerMaxConnections = 50
# Default: rpcServerMaxConnections = 50
rpcServerMaxConnections = 50
# Default: rpcServerThreadPriority = 0
rpcServerThreadPriority = 0
# Default: rpcServerThreadPolicy = SCHED_OTHER
# Valid policies: SCHED_OTHER, SCHED_BATCH, SCHED_IDLE, SCHED_FIFO, SCHED_RR
rpcServerThreadPolicy = SCHED_OTHER
# Default: rpcClientMaxServers = 50
rpcClientMaxServers = 50
# Default: rpcClientThreadPriority = 0
rpcClientThreadPriority = 0
# Default: rpcClientThreadPolicy = SCHED_OTHER
# Valid policies: SCHED_OTHER, SCHED_BATCH, SCHED_IDLE, SCHED_FIFO, SCHED_RR
rpcClientThreadPolicy = SCHED_OTHER
# Default: workerThreadPriority = 0
workerThreadPriority = 0
# Default: workerThreadPolicy = SCHED_OTHER
# Valid policies: SCHED_OTHER, SCHED_BATCH, SCHED_IDLE, SCHED_FIFO, SCHED_RR
workerThreadPolicy = SCHED_OTHER
# Default: packetQueueThreadPriority = 45
packetQueueThreadPriority = 45
# Default: packetQueueThreadPolicy = SCHED_FIFO
# Valid policies: SCHED_OTHER, SCHED_BATCH, SCHED_IDLE, SCHED_FIFO, SCHED_RR
packetQueueThreadPolicy = SCHED_FIFO
# Default: packetReceivedThreadPriority = 0
packetReceivedThreadPriority = 0
# Default: packetReceivedThreadPolicy = SCHED_OTHER
# Valid policies: SCHED_OTHER, SCHED_BATCH, SCHED_IDLE, SCHED_FIFO, SCHED_RR
packetReceivedThreadPolicy = SCHED_OTHER
# Default: eventMaxThreads = 20
eventThreadCount = 5
# Default: eventThreadPriority = 0
eventThreadPriority = 0
# Default: eventThreadPolicy = SCHED_OTHER
# Valid policies: SCHED_OTHER, SCHED_BATCH, SCHED_IDLE, SCHED_FIFO, SCHED_RR
eventThreadPolicy = SCHED_OTHER
___________________________________________________________________________
---------------------------------- MAX! ----------------------------------
___________________________________________________________________________
#######################################
################# CUL #################
#######################################
## The device family this interface is for
#[CUL]
## Specify an unique id here to identify this device in Homegear
#id = My-MAX-CUL
## When default is set to "true" Homegear will assign this device
## to new peers.
#default = true
## Options: cul, coc, cc1100
#deviceType = cul
#device = /dev/ttyACM0
## Should be "40" for MAX!
#responseDelay = 40
#######################################
########## TI CC1101 Module ##########
#######################################
## The device family this interface is for
#[TI CC1101 Module]
## Specify an unique id here to identify this device in Homegear
#id = My-MAX-CC1101
## When default is set to "true" Homegear will assign this device
## to new peers.
#default = true
## Options: cul, coc, cc1100
#deviceType = cc1100
#device = /dev/spidev0.0
## Default: responseDelay = 95
## Should be "40" for CUL or COC and "45" for TI CC1101.
#responseDelay = 45
## The interrupt pin to use. "0" for GDO0 or "2" for GDO2.
## You only need to connect one of them. Specify the GPIO
## you connected the interrupt pin to below.
#interruptPin = 2
## The GPIO GDO0 or GDO2 is connected to. Specify which GDO to use above.
#gpio1 = 23
### Additional TI CC1190 Config ###
## The GPIO high gain mode of the CC1190 is connected to.
## Default: -1 (disabled)
#gpio2 = 5
## The hexadecimal value for the PATABLE of the TI CC1101.
## Default:
## - Without high gain mode: 0xC2
## - With high gain mode: 0x27 (maximum legally allowed setting)
#txPowerSetting = 0x27
#######################################
################ CUNX ################
#######################################
## The device family this interface is for
#[CUNX]
## Specify an unique id here to identify this device in Homegear
#id = My-CUNX
## When default is set to "true" Homegear will assign this device
## to new peers.
#default = true
## Options: cul, cc1100, coc, cunx, hmcfglan, hmlgw
#deviceType = cunx
## IP address of your CUNO
#host = 192.168.178.100
## Port number your CUNX listens on. Normally 2323.
#port = 2323
## Default: responseDelay = 95
## Should be "40" for CUNX
#responseDelay = 40
---
- name: restart homegear
service: name=homegear state=restarted
---
- name: install packages
apt:
pkg: "{{ item }}"
update_cache: yes
state: installed
with_items:
- homegear
- homegear-max
notify: restart homegear
- name: main.conf
copy: src=main.conf dest=/etc/homegear/main.conf
notify: restart homegear
- name: max.conf
copy: src=max.conf dest=/etc/homegear/families/max.conf
notify: restart homegear
---
# Rollen, die nur auf dem WarpHAB-Server verwendet werden
- hosts: warphab
remote_user: root
roles:
- { role: homegear, tags: homegear }
- { role: openhab, tags: openhab }
---
- name: restart openhab
service: name=openhab2 state=restarted
---
- name: install packages
apt:
pkg: "{{ item }}"
update_cache: yes
state: installed
with_items:
- oracle-java8-jdk
- openhab2-offline
notify: restart openhab
#- name: main.conf
# copy: src=main.conf dest=/etc/homegear/main.conf
# notify: restart openhab
#- name: homematicbidcos.conf
# copy: src=homematicbidcos.conf dest=/etc/homegear/families/homematicbidcos.conf
# notify: restart openhab
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment