Giter Club home page Giter Club logo

vpn-container's Introduction

Introduction

It's not uncommon to need to be connected to a bunch of overlapping VPNs, network namespaces offer an easy way out of that problem. Additionally user namespaces offer the ability to run a VPN entirely as a user while still sharing the filesystem with the outside allowing all your usual commands to work.

Also, it was a fun way to show how easy it is to work with namespaces using the tools provided alongside LXC.

How

The start-vpn script creates a new user namespace where your user is root, then does a few trick so openvpn and byobu can happily run. openvpn is then started and a byobu server started so you can easily attach inside the container.

Dependencies

  • socat
  • openvpn
  • byobu
  • uidmap
  • lxc
  • A 3.13 or higher kernel with usernamespaces enabled

Using

git clone git://github.com/stgraber/vpn-container
cd vpn-container
./start-vpn \<VPN NAME\> \<VPN CONFIG\>

The vpn name is used for the socket/pid files and for the container's hostname (so you can easily see what VPN you're working on).

The vpn config is a standard OpenVPN configuration file.

Contributing

Contributions are always appreciated!

The project is licensed under the GNU GPL version 2 (and not any latter version). Contributors must sign-off on their commits, indicating that they agree with the Developer Certificate of Ownership (developercertificate.org).

Please try to follow the existing code style and for the shell scripts, stick with POSIX shell.

vpn-container's People

Contributors

stgraber avatar jjo avatar

Stargazers

Travis Clarke avatar

Watchers

James Cloos avatar Travis Clarke avatar  avatar

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.