Skip to content

Commit

Permalink
Bump 1.0.0
Browse files Browse the repository at this point in the history
Target src 1.0.0
Generate cert at install too
  • Loading branch information
pva committed Jun 11, 2019
1 parent 6b22c22 commit c39e51d
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion extra/00-gen-cert
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ if [ ! -f "$SNAP_COMMON/certificate.pem" ]; then
snapctl set tcp.pk="$SNAP_COMMON/privkey.pem"
snapctl set tcp.auth=false
snapctl set tcp.authkey="$(cat /proc/sys/kernel/random/uuid)"
fi
fi
4 changes: 2 additions & 2 deletions snap/hooks/configure
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,15 @@ if tcp_ssl == "true" and tcp_pk == "":
exit(1)

if tcp_ssl == "true" and tcp_pk != "" and not os.path.exists(tcp_pk):
print("Given tcp.pk - no such path '{0}'".format(tcp_pk))
print("Given tcp.pk does not exist at '{0}'".format(tcp_pk))
exit(1)

if tcp_ssl == "true" and tcp_cert == "":
print("Given tcp.cert empty while tcp.ssl is set to 'true'")
exit(1)

if tcp_ssl == "true" and tcp_cert != "" and not os.path.exists(tcp_cert):
print("Given tcp.cert - no such path '{0}'".format(tcp_cert))
print("Given tcp.cert does not exist at '{0}'".format(tcp_cert))
exit(1)

if tcp_auth != "true" and tcp_auth != "false":
Expand Down
5 changes: 4 additions & 1 deletion snap/hooks/install
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/sh
set -e

snapctl set tcp.port=27015 tcp.relay=true serial.autodiscover=true serial.port=/dev/ttyAMA0 logging.type=info logging.output=stream
snapctl set tcp.port=27015 tcp.relay=true serial.autodiscover=true serial.port=/dev/ttyAMA0 logging.type=info logging.output=stream tcp.ssl=false tcp.auth=false

# Generate certificate
sh $SNAP/00-gen-cert
3 changes: 2 additions & 1 deletion snap/snapcraft.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: velbus-tcp
version: '0.0.6'
version: '1.0.0'
summary: Python application that bridges a Velbus installation with TCP
description: |
Python application that bridges a Velbus installation with TCP.
Expand All @@ -17,6 +17,7 @@ parts:
src:
plugin: dump
source: https://github.com/velbus/python-velbustcp.git
source-tag: 1.0.0
stage-packages: [openssl]

extra:
Expand Down

0 comments on commit c39e51d

Please sign in to comment.