Git Product home page Git Product logo

wireguard-docker's Issues

seems require more permissions

How do I start it:

ln -s $PWD/server.conf /etc/wireguard/wg0.conf
docker run -it --rm --cap-add net_admin --cap-add sys_module \
    --name wireguard \
    -v /etc/wireguard:/etc/wireguard -v /lib/modules:/lib/modules \
    -p 51820:51820/udp activeeos/wireguard-docker

Error message:

Fri Mar 29 07:13:53 UTC 2019: Starting Wireguard
Warning: `/etc/wireguard/wg0.conf' is world accessible
[#] ip link add wg0 type wireguard
[#] wg setconf wg0 /dev/fd/63
[#] ip link set mtu 1420 up dev wg0
[#] wg set wg0 fwmark 51820
[#] ip -4 route add 0.0.0.0/0 dev wg0 table 51820
[#] ip -4 rule add not fwmark 51820 table 51820
[#] ip -4 rule add table main suppress_prefixlength 0
sysctl: setting key "net.ipv4.conf.all.rp_filter": Read-only file system
sysctl: setting key "net.ipv4.conf.default.rp_filter": Read-only file system
sysctl: setting key "net.ipv4.conf.eth0.rp_filter": Read-only file system
sysctl: setting key "net.ipv4.conf.lo.rp_filter": Read-only file system
sysctl: setting key "net.ipv4.conf.wg0.rp_filter": Read-only file system

Clarification regarding server and client setup

Hi,
I run an openvpn server in docker with Tunnelblick on my mac.

I'm curious to give this a shot. But the things is, I don't understand the README where things should run. server versus client, there is no distinctions.

Assuming this is for the server:

docker run -it --rm --cap-add net_admin --cap-add sys_module \
       -v /etc/wireguard:/etc/wireguard -v /lib/wireguard:/lib/wireguard \
       -p 5555:5555/udp activeeos/wireguard-docker

, how should I run it on my mac as a client?

Thanks!

Does it support raspberry pi docker?

[root@barge bargee]# uname -a
Linux barge 4.4.20-rpi-barge #1 SMP PREEMPT Tue Sep 20 02:14:51 UTC 2016 armv7l GNU/Linux
[root@barge bargee]# docker run -it --rm --cap-add net_admin --cap-add sys_module -v /etc/wireguard:/etc/wireguard -v /lib/modules:/lib/modules -p 21403:5555/udp activeeos/wireguard-docker
exec format error
docker: Error response from daemon: Cannot start container 55bb0e7545061f530705e4a7da556a4596d5c6edcec6eb0558750c7e23aa3550: [9] System error: exec format error.

How do I use this docker image?

I have tried this docker image on a Ubuntu 16.04 machine,I have no idea what should I do the next?any help would be apperciated

cuz I hate running the program on the physical machine,I like running everything on the docker,then I tried to copy the configuration files from a wrieguard file from a CentOS 7 to this machine which is wireguard working fine there,

$ pwd
/etc/wireguard

$ ls
client.conf cprivatekey cpublickey sprivatekey spublickey wg0.conf

then I run the docker command

docker run -it --rm --cap-add net_admin --cap-add sys_module
-v /etc/wireguard:/etc/wireguard -v /lib/modules:/lib/modules
-p 5555:5555/udp activeeos/wireguard-docker

finaly I have such a concequence:

Good news! Module version 0.0.20181218 for wireguard.ko
exactly matches what is already found in kernel 4.4.0-21-generic.
DKMS will not replace this module.
You may override by specifying --force.

depmod.......

DKMS: install completed.
Setting up wireguard-tools (0.0.20181218-wg1xenial) ...
Setting up wireguard (0.0.20181218-wg1
xenial) ...
Processing triggers for libc-bin (2.23-0ubuntu10) ...
Processing triggers for systemd (229-4ubuntu21.2) ...
Processing triggers for menu (2.1.47ubuntu1.16.04.1) ...
Sat Jan 19 06:00:57 UTC 2019: Starting Wireguard
Usage: wg-quick [ up | down | save ] [ CONFIG_FILE | INTERFACE ]

CONFIG_FILE is a configuration file, whose filename is the interface name
followed by .conf'. Otherwise, INTERFACE is an interface name, with configuration found at /etc/wireguard/INTERFACE.conf. It is to be readable by wg(8)'s setconf' sub-command, with the exception of the following additions
to the [Interface] section, which are handled by wg-quick:

  • Address: may be specified one or more times and contains one or more
    IP addresses (with an optional CIDR mask) to be set for the interface.
  • DNS: an optional DNS server to use while the device is up.
  • MTU: an optional MTU for the interface; if unspecified, auto-calculated.
  • Table: an optional routing table to which routes will be added; if
    unspecified or auto', the default table is used. If off', no routes
    are added.
  • PreUp, PostUp, PreDown, PostDown: script snippets which will be executed
    by bash(1) at the corresponding phases of the link, most commonly used
    to configure DNS. The string `%i' is expanded to INTERFACE.
  • SaveConfig: if set to `true', the configuration is saved from the current
    state of the interface upon shutdown.

See wg-quick(8) for more info and examples.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.