mirror of
https://github.com/vimagick/dockerfiles.git
synced 2024-12-23 01:39:27 +02:00
update
This commit is contained in:
parent
14ab509418
commit
f7cf0846a1
@ -500,6 +500,7 @@ A collection of delicious docker recipes.
|
||||
- [x] yourls
|
||||
- [x] ghcr.io/linuxserver/wireguard
|
||||
- [x] apache/zeppelin
|
||||
- [x] koenkk/zigbee2mqtt
|
||||
- [x] zookeeper
|
||||
- [x] elkozmon/zoonavigator
|
||||
|
||||
|
20
semaphore/keygen.sh
Executable file
20
semaphore/keygen.sh
Executable file
@ -0,0 +1,20 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# https://docs.semui.co/administration-guide/api
|
||||
#
|
||||
|
||||
set -euo pipefail
|
||||
|
||||
API_ENDPOINT=http://192.168.1.100:3000
|
||||
API_USERNAME=username
|
||||
API_PASSWORD=password
|
||||
|
||||
cookie=$(jq -n --arg auth $API_USERNAME --arg password $API_PASSWORD '{$auth, $password}' | curl -s -c- $API_ENDPOINT/api/auth/login -d @- -o /dev/null | awk '$6=="semaphore"{print $7}')
|
||||
|
||||
if curl -s -H "Cookie: semaphore=$cookie" $API_ENDPOINT/api/user/tokens | jq -e 'length==0' > /dev/null; then
|
||||
curl -s -X POST -H "Cookie: semaphore=$cookie" $API_ENDPOINT/api/user/tokens
|
||||
fi
|
||||
|
||||
token=$(curl -s -H "Cookie: semaphore=$cookie" $API_ENDPOINT/api/user/tokens | jq -r .[0].id)
|
||||
|
||||
curl -s -H "Authorization: Bearer $token" $API_ENDPOINT/api/user/tokens | jq .
|
2
zigbee2mqtt/README.md
Normal file
2
zigbee2mqtt/README.md
Normal file
@ -0,0 +1,2 @@
|
||||
zigbee2mqtt
|
||||
===========
|
20
zigbee2mqtt/data/configuration.yaml
Normal file
20
zigbee2mqtt/data/configuration.yaml
Normal file
@ -0,0 +1,20 @@
|
||||
# Home Assistant integration (MQTT discovery)
|
||||
homeassistant: false
|
||||
|
||||
# allow new devices to join
|
||||
permit_join: false
|
||||
|
||||
# MQTT settings
|
||||
mqtt:
|
||||
# MQTT base topic for zigbee2mqtt MQTT messages
|
||||
base_topic: zigbee2mqtt
|
||||
# MQTT server URL
|
||||
server: 'mqtt://localhost'
|
||||
# MQTT server authentication, uncomment if required:
|
||||
# user: my_user
|
||||
# password: my_password
|
||||
|
||||
# Serial settings
|
||||
serial:
|
||||
# Location of CC2531 USB sniffer
|
||||
port: /dev/ttyACM0
|
14
zigbee2mqtt/docker-compose.yml
Normal file
14
zigbee2mqtt/docker-compose.yml
Normal file
@ -0,0 +1,14 @@
|
||||
version: "3.8"
|
||||
services:
|
||||
zigbee2mqtt:
|
||||
image: koenkk/zigbee2mqtt
|
||||
ports:
|
||||
- "8080:8080"
|
||||
volumes:
|
||||
- ./data:/app/data
|
||||
- /run/udev:/run/udev:ro
|
||||
environment:
|
||||
- TZ=Asia/Shanghai
|
||||
devices:
|
||||
- /dev/serial/by-id/usb-Texas_Instruments_XXXXXX:/dev/ttyACM0
|
||||
restart: unless-stopped
|
Loading…
Reference in New Issue
Block a user