feat: change config from INI to JSON.
This commit is contained in:
1 parent
b18947ed9b
commit
656e1733d5
3 files changed
+39
-4
No files matched your search
@@ -1,9 +1,16 @@
|
||||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
# Apple container CLI on macOS, Docker CE on Linux.
|
||||
case "$(uname -s)" in
|
||||
Darwin) CONTAINER_RUNTIME=container ;;
|
||||
Linux) CONTAINER_RUNTIME=docker ;;
|
||||
*) printf 'ERROR: unsupported platform %s\n' "$(uname -s)" >&2; exit 1 ;;
|
||||
esac
|
||||
|
||||
mkdir -p out
|
||||
|
||||
container build --build-arg HOST_UID=$(id -u) --build-arg HOST_GID=$(id -g) -t vpn-router-builder "$@" .
|
||||
container run --rm -v "$(pwd)/out:/mnt" vpn-router-builder sh -c 'cp -p /out/* /mnt/'
|
||||
$CONTAINER_RUNTIME build --build-arg HOST_UID=$(id -u) --build-arg HOST_GID=$(id -g) -t vpn-router-builder "$@" .
|
||||
$CONTAINER_RUNTIME run --rm -v "$(pwd)/out:/mnt" vpn-router-builder sh -c 'cp -p /out/* /mnt/'
|
||||
|
||||
echo "Build artifacts written to out/"
|
||||
@@ -1,4 +1,25 @@
|
||||
vpn-router (1.0.0-1) unstable; urgency=medium
|
||||
vpn-router (0.2.0-1) unstable; urgency=medium
|
||||
|
||||
* Change the configuration file to JSON, /etc/vpn-router/vpn-router.json.
|
||||
Lists are arrays, booleans and the WireGuard listen port are native JSON
|
||||
types, and unknown sections, unknown settings and wrong value types are
|
||||
rejected.
|
||||
* Replace remote.psk_b64 with remote.psk, holding the pre-shared key as a
|
||||
plain string. remote.psk_file still takes precedence.
|
||||
* Ship /usr/share/doc/vpn-router/vpn-router.json.example in place of
|
||||
vpn-router.conf.example.
|
||||
* Add platform "none" as the default, so installing the package changes
|
||||
nothing on the machine until a platform is chosen.
|
||||
* Add the mode setting (manual, interfaces, auto) controlling how much of
|
||||
the network configuration is supplied and how much is read from the
|
||||
system.
|
||||
* Manage the configuration file with ucf, so dpkg-reconfigure reapplies
|
||||
debconf answers without overwriting local edits.
|
||||
* Apply NAT and forward rules to every local subnet, not only the first.
|
||||
|
||||
-- Sławomir Koszewski <slawek@koszewscy.waw.pl> Fri, 23 Oct 2026 08:00:06 +0200
|
||||
|
||||
vpn-router (0.1.0-1) unstable; urgency=medium
|
||||
|
||||
* Initial release.
|
||||
|
||||
|
||||
@@ -1,8 +1,15 @@
|
||||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
# Apple container CLI on macOS, Docker CE on Linux.
|
||||
case "$(uname -s)" in
|
||||
Darwin) CONTAINER_RUNTIME=container ;;
|
||||
Linux) CONTAINER_RUNTIME=docker ;;
|
||||
*) printf 'ERROR: unsupported platform %s\n' "$(uname -s)" >&2; exit 1 ;;
|
||||
esac
|
||||
|
||||
changelog_field() {
|
||||
container run --rm -v "$(pwd):/mnt" vpn-router-builder \
|
||||
$CONTAINER_RUNTIME run --rm -v "$(pwd):/mnt" vpn-router-builder \
|
||||
dpkg-parsechangelog --show-field "$1" -l /mnt/debian/changelog
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user