summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAki <please@ignore.pl>2023-04-05 21:52:24 +0200
committerAki <please@ignore.pl>2023-04-05 21:52:24 +0200
commit60a8fb3e35ca46cf6d890a90e9f4a7f090e099f9 (patch)
tree181932bd4b4d8e14f6b48c5e1948f9ffe87df1a0
parentfab6199135d75c38f3cdc463884c618784c3655a (diff)
downloadwaterspout-radar-60a8fb3e35ca46cf6d890a90e9f4a7f090e099f9.zip
waterspout-radar-60a8fb3e35ca46cf6d890a90e9f4a7f090e099f9.tar.gz
waterspout-radar-60a8fb3e35ca46cf6d890a90e9f4a7f090e099f9.tar.bz2
Configuration files now use .ini extension
-rw-r--r--.gitignore2
-rw-r--r--contrib/.gitignore2
-rw-r--r--contrib/waterspout-pull.service2
-rw-r--r--contrib/waterspout-radar.ini (renamed from contrib/waterspout-radar.conf)2
-rw-r--r--contrib/waterspout-web.service2
-rw-r--r--waterspout_radar/_config.py2
6 files changed, 7 insertions, 5 deletions
diff --git a/.gitignore b/.gitignore
index ae42a40..c724fa5 100644
--- a/.gitignore
+++ b/.gitignore
@@ -4,5 +4,5 @@ build*/
dist/
.venv/
.env
-*.conf
+*.ini
*.json
diff --git a/contrib/.gitignore b/contrib/.gitignore
index f8d2b04..a578ca4 100644
--- a/contrib/.gitignore
+++ b/contrib/.gitignore
@@ -1 +1 @@
-!*.conf
+!*.ini
diff --git a/contrib/waterspout-pull.service b/contrib/waterspout-pull.service
index b584688..a212b63 100644
--- a/contrib/waterspout-pull.service
+++ b/contrib/waterspout-pull.service
@@ -3,5 +3,5 @@ Description=Pull data for Waterspout Radar
[Service]
Type=oneshot
-ExecStart=/usr/bin/env waterspout-radar -c /etc/waterspout-radar.conf
+ExecStart=/usr/bin/env waterspout-radar -c /etc/waterspout-radar.ini
User=waterspout
diff --git a/contrib/waterspout-radar.conf b/contrib/waterspout-radar.ini
index be204b7..6470d66 100644
--- a/contrib/waterspout-radar.conf
+++ b/contrib/waterspout-radar.ini
@@ -1,3 +1,5 @@
+; /etc/waterspout-radar.ini
+
[Waterspout Radar]
db = /srv/waterspout-radar/db.json
; key = <Your private Windy API key goes here>
diff --git a/contrib/waterspout-web.service b/contrib/waterspout-web.service
index 377a221..6b7f320 100644
--- a/contrib/waterspout-web.service
+++ b/contrib/waterspout-web.service
@@ -4,7 +4,7 @@ Description=Waterspout Radar Web Interface
[Service]
Type=simple
ExecStart=uwsgi --socket /run/waterspout-radar.sock --module waterspout_radar.web:app --vacuum
-Environment="WATERSPOUT_RADAR_CONFIG=/etc/waterspout-radar.conf"
+Environment="WATERSPOUT_RADAR_CONFIG=/etc/waterspout-radar.ini"
User=waterspout
[Install]
diff --git a/waterspout_radar/_config.py b/waterspout_radar/_config.py
index 222f023..1e740ae 100644
--- a/waterspout_radar/_config.py
+++ b/waterspout_radar/_config.py
@@ -35,7 +35,7 @@ class ConfigError(Exception):
def effective_pathname(pathname: str = None) -> str:
"Pathname of the configuration file based on optional *pathname*, environment, and default."
- return pathname or os.getenv("WATERSPOUT_RADAR_CONFIG") or "waterspout-radar.conf"
+ return pathname or os.getenv("WATERSPOUT_RADAR_CONFIG") or "waterspout-radar.ini"
def load(pathname: str) -> Config: