GingerCal 1.3: month view, Galician interface, Nginx Proxy Manager bridge option
This commit is contained in:
1 parent
f44ecf4871
commit
42c3d6da91
39 files changed
+1409
-220
No files matched your search
+10
-8
@@ -1,15 +1,17 @@
|
||||
#!/bin/sh
|
||||
# Creates the bridge's self-signed certificate (10 years) and prints the SHA-256
|
||||
# Creates the legacy endpoint's self-signed certificate (10 years) and prints the SHA-256
|
||||
# fingerprint to compare with what the phone shows when you tap "Trust".
|
||||
# ./make-cert.sh [name] [output-dir]
|
||||
# e.g. for Nginx Proxy Manager: ./make-cert.sh nxc.anosanube.ovh /opt/npm/data/legacy-caldav
|
||||
set -eu
|
||||
cd "$(dirname "$0")"
|
||||
mkdir -p certs
|
||||
NAME=${1:-caldav-bridge}
|
||||
if [ ! -f certs/bridge.key ]; then
|
||||
DIR=${2:-"$(dirname "$0")/certs"}
|
||||
mkdir -p "$DIR"
|
||||
if [ ! -f "$DIR/bridge.key" ]; then
|
||||
openssl req -x509 -newkey rsa:2048 -sha256 -days 3650 -nodes \
|
||||
-keyout certs/bridge.key -out certs/bridge.crt -subj "/CN=$NAME" 2>/dev/null
|
||||
chmod 600 certs/bridge.key
|
||||
echo "Created certs/bridge.crt"
|
||||
-keyout "$DIR/bridge.key" -out "$DIR/bridge.crt" -subj "/CN=$NAME" 2>/dev/null
|
||||
chmod 600 "$DIR/bridge.key"
|
||||
echo "Created $DIR/bridge.crt"
|
||||
fi
|
||||
echo "SHA-256 fingerprint (must match the phone):"
|
||||
openssl x509 -in certs/bridge.crt -noout -fingerprint -sha256 | cut -d= -f2
|
||||
openssl x509 -in "$DIR/bridge.crt" -noout -fingerprint -sha256 | cut -d= -f2
|
||||
Reference in new issue
Block a user