Skip to content

Commit

Permalink
Merge pull request #16 from freedomofpress/infer-hostname
Browse files Browse the repository at this point in the history
Infers hostname for "localvm" setting
  • Loading branch information
emkll authored Mar 11, 2020
2 parents 7976e0f + 89668e2 commit 6e0dc3f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.1.0
0.1.1
4 changes: 4 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## 0.1.1

* Infers hostname from system settings, if no config value found.

## 0.1.0

* Initial beta release.
Expand Down
3 changes: 2 additions & 1 deletion sd-rsyslog
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import os
import logging
import configparser
from subprocess import Popen, PIPE
from socket import gethostname

# Global definitions specific to your plugin
process = None
Expand Down Expand Up @@ -81,7 +82,7 @@ def onInit():
config = configparser.ConfigParser()
config.read('/etc/sd-rsyslog.conf')
logvmname = config['sd-rsyslog']['remotevm']
localvmname = config['sd-rsyslog']['localvm']
localvmname = config['sd-rsyslog'].get('localvm', gethostname())
process = Popen(
["/usr/lib/qubes/qrexec-client-vm", logvmname, "securedrop.Log"],
stdin=PIPE,
Expand Down

0 comments on commit 6e0dc3f

Please sign in to comment.