Skip to content
Snippets Groups Projects
Commit 3cdb16e1 authored by void's avatar void
Browse files

upgrade openhab, fix infuxdb persistence

parent 04b60d80
No related branches found
No related tags found
No related merge requests found
...@@ -3,7 +3,8 @@ ...@@ -3,7 +3,8 @@
- include: ../functions/get_secret.yml - include: ../functions/get_secret.yml
with_items: with_items:
- { path: /srv/openhab/openweathermap_apikey, length: -1 } - { path: /srv/openhab/openweathermap_apikey, length: -1 }
- { path: /srv/openhab/influxdb_password, length: 12 } - { path: /srv/openhab/influxdb_password, length: 12 }
- { path: /srv/openhab/influxdb_token, length: 32 }
- name: pakete installieren - name: pakete installieren
...@@ -35,8 +36,7 @@ ...@@ -35,8 +36,7 @@
- /srv/openhab/conf/rules/ - /srv/openhab/conf/rules/
- /srv/openhab/conf/things/ - /srv/openhab/conf/things/
- /srv/openhab/userdata/ - /srv/openhab/userdata/
- /srv/openhab/influxdb-data/ - /srv/openhab/influxdb/
- /srv/openhab/influxdb-conf/
- name: Docker-Konfig-Dateien erstellen - name: Docker-Konfig-Dateien erstellen
template: template:
......
...@@ -25,7 +25,7 @@ binding = astro,mqtt,network,openweathermap,wled ...@@ -25,7 +25,7 @@ binding = astro,mqtt,network,openweathermap,wled
# ui = habpanel # ui = habpanel
# A comma-separated list of persistence services to install (e.g. "rrd4j,jpa") # A comma-separated list of persistence services to install (e.g. "rrd4j,jpa")
persistence = influxdb,rrd4j persistence = rrd4j,influxdb
# A comma-separated list of actions to install (e.g. "mail,pushover") # A comma-separated list of actions to install (e.g. "mail,pushover")
# action = pushover # action = pushover
......
url=http://influxdb:8086 version=V2
url=http://{{ int_ip4 }}:{{ influxdb_port }}
user=openhab user=openhab
password={{ influxdb_password }} token={{ influxdb_token }}
db=openhab db=openhab
retentionPolicy=openhab
...@@ -4,55 +4,56 @@ ...@@ -4,55 +4,56 @@
# The ISO 639 alpha-2 or alpha-3 language code (if there is no alpha-2 one). # The ISO 639 alpha-2 or alpha-3 language code (if there is no alpha-2 one).
# Example: "en" (English), "de" (German), "ja" (Japanese), "kok" (Konkani) # Example: "en" (English), "de" (German), "ja" (Japanese), "kok" (Konkani)
# #
org.eclipse.smarthome.core.localeprovider:language=de org.openhab.i18n:language=de
# The region that should be used. # The region that should be used.
# ISO 3166 alpha-2 country code or UN M.49 numeric-3 area code. # ISO 3166 alpha-2 country code or UN M.49 numeric-3 area code.
# Example: "US" (United States), "DE" (Germany), "FR" (France), "029" (Caribbean) # Example: "US" (United States), "DE" (Germany), "FR" (France), "029" (Caribbean)
# #
org.eclipse.smarthome.core.localeprovider:region=DE org.openhab.i18n:region=DE
# Location # Location
org.eclipse.smarthome.core.i18nprovider:location=51.944514, 7.638933 org.openhab.i18n:location=51.944514, 7.638933
# Timezone # Timezone
org.eclipse.smarthome.core.i18nprovider:timezone=Europe/Berlin org.openhab.i18n:timezon=Europe/Berlin
################ PERSISTENCE #################### ################ PERSISTENCE ####################
# The persistence service to use if no other is specified. # The persistence service to use if no other is specified.
# #
org.eclipse.smarthome.persistence:default=influxdb org.openhab.persistence:default=rrd4j
################### AUDIO ####################### ################### AUDIO #######################
# This parameter defines the default audio source to use (if not set, the first available one will be used. # This parameter defines the default audio source to use (if not set, the first available one will be used.
# #
#org.eclipse.smarthome.audio:defaultSource= #org.openhab.audio:defaultSource=
# This parameter defines the default audio sink to use (if not set, the first available one will be used. # This parameter defines the default audio sink to use (if not set, the first available one will be used.
# #
#org.eclipse.smarthome.audio:defaultSink= #org.openhab.audio:defaultSink=
##################### VOICE #################### ##################### VOICE #####################
# This parameter defines the default text-to-speech service to use (if not set, the first available one will be used. # This parameter defines the default text-to-speech service to use (if not set, the first available one will be used.
# #
#org.eclipse.smarthome.voice:defaultTTS= #org.openhab.voice:defaultTTS=
# This parameter defines the default speech-to-text service to use (if not set, the first available one will be used. # This parameter defines the default speech-to-text service to use (if not set, the first available one will be used.
# #
#org.eclipse.smarthome.voice:defaultSTT= #org.openhab.voice:defaultSTT=
# The default voice to use if no specific TTS service or voice is specified. # The default voice to use if no specific TTS service or voice is specified.
# #
#org.eclipse.smarthome.voice:defaultVoice= #org.openhab.voice:defaultVoice=
# The default human language interpreter to use if no other is specified. # The default human language interpreter to use if no other is specified.
# #
#org.eclipse.smarthome.voice:defaultHLI= #org.openhab.voice:defaultHLI=
################ MISCELLANOUS #################### ################ MISCELLANOUS ###################
# The karaf sshHost parameter configures the bind address for the ssh login to karaf. # The karaf sshHost parameter configures the bind address for the ssh login to karaf.
# Default is 127.0.0.1 (localhost), so it is only possible to login from the local machine. # Default is 127.0.0.1 (localhost), so it is only possible to login from the local machine.
...@@ -69,13 +70,37 @@ org.eclipse.smarthome.persistence:default=influxdb ...@@ -69,13 +70,37 @@ org.eclipse.smarthome.persistence:default=influxdb
# Setting this to true will automatically approve all inbox entries and create Things for them, # Setting this to true will automatically approve all inbox entries and create Things for them,
# so that they are immediately available in the system (default is false) # so that they are immediately available in the system (default is false)
# #
org.eclipse.smarthome.inbox:autoApprove=true #org.openhab.inbox:autoApprove=true
# Cross-origin resource sharing (CORS) is a browser security feature that restricts cross-origin
# HTTP requests that are initiated from scripts running in the browser. Setting this option to 'true'
# will disable the browser cross-origin check. This is required if you want to use a web UI that is not
# hosted on the openHAB server domain.
#org.openhab.cors:enable=true
# This parameter defines how the members of a group are sorted in UIs rendering sitemaps.
# 3 values are accepted:
# - NONE: no sorting (this is the default)
# - LABEL: sorted by label
# - NAME: sorted by name
#org.openhab.sitemap:groupMembersSorting=NONE
################ REST API ###################
# Allow the use of Basic authentication to access protected API resources, in addition to access tokens and API tokens
#
#org.openhab.restauth:allowBasicAuth=true
# When basic authentication is activated, credentials are put in a cache in order to speed up request
# authorization. The entries in the cache expire after a while in order to not keep credentials in memory indefinitely.
# This value defines the expiration time in hours. Set it to 0 for disabling the cache.
#
#org.openhab.restauth:cacheExpiration=6
# This setting allows to switch between a "simple" and an "advanced" mode for item management. # By default, operations requiring the "user" role are available when unauthenticated.
# In simple mode (autoLinks=true), links and their according items are automatically created for new Things. # Disabling this option will enforce authorization for these operations.
# In advanced mode (autoLinks=false), the user has the full control about which items channels are linked to. # Warning: This causes clients that do not support authentication to break.
# Existing links will remain untouched. (default is true)
# #
org.eclipse.smarthome.links:autoLinks=false #org.openhab.restauth:implicitUserRole=false
...@@ -6,7 +6,7 @@ services: ...@@ -6,7 +6,7 @@ services:
app: app:
image: openhab/openhab:3.1.0-debian image: openhab/openhab:3.3.0-debian
restart: always restart: always
privileged: true privileged: true
network_mode: host network_mode: host
...@@ -31,17 +31,18 @@ services: ...@@ -31,17 +31,18 @@ services:
influxdb: influxdb:
image: influxdb:2.0.8 image: influxdb:2.3.0
restart: always restart: always
ports: ports:
- {{ int_ip4 }}:{{ influxdb_port }}:8086 - {{ int_ip4 }}:{{ influxdb_port }}:8086
volumes: volumes:
- /srv/openhab/influxdb-data:/var/lib/influxdb2 - /srv/openhab/influxdb:/var/lib/influxdb2
- /srv/openhab/influxdb-conf:/etc/influxdb2
environment: environment:
DOCKER_INFLUXDB_INIT_MODE: setup
DOCKER_INFLUXDB_INIT_USERNAME: openhab DOCKER_INFLUXDB_INIT_USERNAME: openhab
DOCKER_INFLUXDB_INIT_PASSWORD: {{ influxdb_password }} DOCKER_INFLUXDB_INIT_PASSWORD: {{ influxdb_password }}
DOCKER_INFLUXDB_INIT_ORG: openhab DOCKER_INFLUXDB_INIT_ORG: openhab
DOCKER_INFLUXDB_INIT_BUCKET: openhab DOCKER_INFLUXDB_INIT_BUCKET: openhab
DOCKER_INFLUXDB_INIT_ADMIN_TOKEN: {{ influxdb_token }}
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