From 67cf35791a9084781136c140b91899694f51b4d8 Mon Sep 17 00:00:00 2001 From: Grische <2787581+grische@users.noreply.github.com> Date: Wed, 22 Nov 2023 23:42:27 +0100 Subject: [PATCH 1/2] readme: update TOC --- README.md | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 88a466c..94b1135 100644 --- a/README.md +++ b/README.md @@ -4,15 +4,18 @@ [![Bazel tests](https://github.com/freifunkMUC/wgkex/actions/workflows/bazel.yml/badge.svg)](https://github.com/freifunkMUC/wgkex/actions/workflows/bazel.yml) - [WireGuard Key Exchange](#wireguard-key-exchange) - * [Overview](#overview) - + [Frontend broker](#frontend-broker) - - [POST /api/v1/wg/key/exchange](#post--api-v1-wg-key-exchange) - + [Backend worker](#backend-worker) - * [Installation](#installation) - * [Configuration](#configuration) - * [Running the broker](#running-the-broker) - * [Client usage](#client-usage) - * [Contact](#contact) + - [Overview](#overview) + - [Frontend broker](#frontend-broker) + - [POST /api/v1/wg/key/exchange](#post-apiv1wgkeyexchange) + - [Backend worker](#backend-worker) + - [Installation](#installation) + - [Configuration](#configuration) + - [Running the broker and worker](#running-the-broker-and-worker) + - [Build using Bazel](#build-using-bazel) + - [Run using Python](#run-using-python) + - [Client usage](#client-usage) + - [Worker](#worker) + - [Contact](#contact) # WireGuard Key Exchange From cf65b32482b4459b425c0d23c105ad125ec5aa81 Mon Sep 17 00:00:00 2001 From: Grische <2787581+grische@users.noreply.github.com> Date: Wed, 22 Nov 2023 23:43:11 +0100 Subject: [PATCH 2/2] readme: fix markdown violations --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 94b1135..f2327cf 100644 --- a/README.md +++ b/README.md @@ -17,7 +17,6 @@ - [Worker](#worker) - [Contact](#contact) - # WireGuard Key Exchange wgkex is a WireGuard key exchange and management tool designed and run by FFMUC. @@ -82,11 +81,11 @@ For further information, please see this [presentation on the architecture](http ## Installation -* TBA +- TBA ## Configuration -* Configuration file +- Configuration file The `wgkex` configuration file defaults to `/etc/wgkex.yaml` ([Sample configuration file](wgkex.yaml.example)), however can also be overwritten by setting the environment variable `WGKEX_CONFIG_FILE`. @@ -133,6 +132,7 @@ python3 -c 'from wgkex.worker.app import main; main()' ## Client usage The client can be used via CLI: + ``` $ wget -q -O- --post-data='{"domain": "ffmuc_welt","public_key": "o52Ge+Rpj4CUSitVag9mS7pSXUesNM0ESnvj/wwehkg="}' --header='Content-Type:application/json' 'http://127.0.0.1:5000/api/v1/wg/key/exchange' { @@ -141,6 +141,7 @@ $ wget -q -O- --post-data='{"domain": "ffmuc_welt","public_key": "o52Ge+Rpj4CUS ``` Or via python: + ```python import requests key_data = {"domain": "ffmuc_welt","public_key": "o52Ge+Rpj4CUSitVag9mS7pSXUesNM0ESnvj/wwehkg="} @@ -172,7 +173,6 @@ sudo ip link set wg-welt up sudo ip link set vx-welt up ``` - ## Contact [Freifunk Munich Mattermost](https://chat.ffmuc.net)