diff options
author | Renken <renken@shione.net> | 2023-12-25 22:55:06 +0100 |
---|---|---|
committer | Renken <renken@shione.net> | 2024-02-20 22:54:05 +0100 |
commit | 900156b511187d9ce393a55475a8b205e3afeb13 (patch) | |
tree | a25e1af805214289e8bba0a4130e49b358c75b2f /config/shione/wireguard | |
parent | 81b8b02ac9486a1e5248b56351712059faede632 (diff) | |
download | shione-900156b511187d9ce393a55475a8b205e3afeb13.tar.gz shione-900156b511187d9ce393a55475a8b205e3afeb13.zip |
config: shione: incomplete wireguard setup
Diffstat (limited to 'config/shione/wireguard')
-rw-r--r-- | config/shione/wireguard/debian/changelog | 5 | ||||
-rw-r--r-- | config/shione/wireguard/debian/compat | 1 | ||||
-rw-r--r-- | config/shione/wireguard/debian/control | 16 | ||||
-rw-r--r-- | config/shione/wireguard/debian/copyright | 8 | ||||
-rw-r--r-- | config/shione/wireguard/debian/files | 2 | ||||
-rwxr-xr-x | config/shione/wireguard/debian/rules | 4 | ||||
-rw-r--r-- | config/shione/wireguard/debian/source/format | 1 | ||||
-rw-r--r-- | config/shione/wireguard/debian/wireguard-config.install | 1 | ||||
-rw-r--r-- | config/shione/wireguard/files/etc/sysctl.d/wireguard.conf | 3 | ||||
-rwxr-xr-x | config/shione/wireguard/generate_keys.sh | 9 |
10 files changed, 50 insertions, 0 deletions
diff --git a/config/shione/wireguard/debian/changelog b/config/shione/wireguard/debian/changelog new file mode 100644 index 0000000..534c970 --- /dev/null +++ b/config/shione/wireguard/debian/changelog @@ -0,0 +1,5 @@ +wireguard-config (1.0) unstable; urgency=low + + * Initial release. + + -- Renken <renken@shione.net> Sun, 24 Dec 2023 23:46:00 +0100 diff --git a/config/shione/wireguard/debian/compat b/config/shione/wireguard/debian/compat new file mode 100644 index 0000000..ec63514 --- /dev/null +++ b/config/shione/wireguard/debian/compat @@ -0,0 +1 @@ +9 diff --git a/config/shione/wireguard/debian/control b/config/shione/wireguard/debian/control new file mode 100644 index 0000000..81d04ba --- /dev/null +++ b/config/shione/wireguard/debian/control @@ -0,0 +1,16 @@ +Source: wireguard-config +Section: tasks +Priority: optional +Maintainer: Renken <renken@shione.net> +Rules-Requires-Root: no +Build-Depends: debhelper (>= 13.11~), config-package-dev (>= 4.15~) +Standards-Version: 4.1.0 + +Package: wireguard-config +Architecture: all +Multi-Arch: foreign +Depends: ${misc:Depends}, wireguard, wireguard-tools +Provides: ${diverted-files} +Conflicts: ${diverted-files} +Description: Shione wireguard configuration. + Shione wireguard configuration. diff --git a/config/shione/wireguard/debian/copyright b/config/shione/wireguard/debian/copyright new file mode 100644 index 0000000..2fff8a7 --- /dev/null +++ b/config/shione/wireguard/debian/copyright @@ -0,0 +1,8 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Source: https://gitlab.com/renken/nichijou +Upstream-Contact: Renken <renken@shione.net> + +Files: + * +Copyright: 2023, Renken <renken@shione.net> +License: GPL-3 diff --git a/config/shione/wireguard/debian/files b/config/shione/wireguard/debian/files new file mode 100644 index 0000000..287ae41 --- /dev/null +++ b/config/shione/wireguard/debian/files @@ -0,0 +1,2 @@ +wireguard-config_1.0_all.deb tasks optional +wireguard-config_1.0_amd64.buildinfo tasks optional diff --git a/config/shione/wireguard/debian/rules b/config/shione/wireguard/debian/rules new file mode 100755 index 0000000..a089a9e --- /dev/null +++ b/config/shione/wireguard/debian/rules @@ -0,0 +1,4 @@ +#!/usr/bin/make -f + +%: + dh $@ --with config-package diff --git a/config/shione/wireguard/debian/source/format b/config/shione/wireguard/debian/source/format new file mode 100644 index 0000000..89ae9db --- /dev/null +++ b/config/shione/wireguard/debian/source/format @@ -0,0 +1 @@ +3.0 (native) diff --git a/config/shione/wireguard/debian/wireguard-config.install b/config/shione/wireguard/debian/wireguard-config.install new file mode 100644 index 0000000..5b79850 --- /dev/null +++ b/config/shione/wireguard/debian/wireguard-config.install @@ -0,0 +1 @@ +files/* / diff --git a/config/shione/wireguard/files/etc/sysctl.d/wireguard.conf b/config/shione/wireguard/files/etc/sysctl.d/wireguard.conf new file mode 100644 index 0000000..d51aa3c --- /dev/null +++ b/config/shione/wireguard/files/etc/sysctl.d/wireguard.conf @@ -0,0 +1,3 @@ +# Configuration required for wireguard. +net.ipv4.ip_forward = 1 +net.ipv6.conf.all.forwarding = 1 diff --git a/config/shione/wireguard/generate_keys.sh b/config/shione/wireguard/generate_keys.sh new file mode 100755 index 0000000..4c564a4 --- /dev/null +++ b/config/shione/wireguard/generate_keys.sh @@ -0,0 +1,9 @@ +#!/bin/sh + +set -eux + +cd -- files/etc/wireguard +(umask 077; wg genkey | tee shione.private.key | wg pubkey > shione.public.key) +# TODO: chmod 0600 all files under files/etc/wireguard. +# TODO: Update files/etc/wireguard/wg0.conf accordingly. +cd -- - |