Giter VIP home page Giter VIP logo

setup-wireguard's Introduction

Set up WireGuard

Test

This GitHub action sets up a WireGuard connection in your workflow run.

  1. Installs WireGuard if it's missing.
  2. Sets up a connection using the provided credentials.

Use it your workflow like this:

- name: Set up WireGuard
  uses: egor-tensin/setup-wireguard@v1
  with:
    endpoint: 46.46.46.46:51820
    endpoint_public_key: 9IHlvJqgkVWMq57a0A56XI5IjhnL5gaRhI1Pszk7S24=
    ips: 192.168.143.254/24,fd8c:bc10:5021::192.168.143.254/48
    allowed_ips: 192.168.143.0/24,fd8c:bc10:5021::/48
    private_key: GLEiXhRwFuhw8aPy+HQfSMwwoLU0Sw8jE8MOxZ8GV3w=
    preshared_key: PWAfvVWCjiNV0Uh2DhmXhdRaT326qosSOcaDB3j9dwI=

Of couse it's highly advised to store all sensitive data in your repository's secrets. It could then become something like:

- name: Set up WireGuard
  uses: egor-tensin/setup-wireguard@v1
  with:
    endpoint: '${{ secrets.ENDPOINT }}'
    endpoint_public_key: '${{ secrets.ENDPOINT_PUBLIC }}'
    ips: '${{ secrets.IPS }}'
    allowed_ips: '${{ secrets.ALLOWED_IPS }}'
    private_key: '${{ secrets.PRIVATE }}'
    preshared_key: '${{ secrets.PRESHARED }}'

API

Input Example Description
endpoint 46.46.46.46:51820 Endpoint to connect to in the HOST:PORT format.
endpoint_public_key 9IHlvJqgkVWMq57a0A56XI5IjhnL5gaRhI1Pszk7S24= Endpoint's public key.
ips 192.168.143.254/24,fd8c:bc10:5021::192.168.143.254/48 Comma-separated list of IP addresses to assign to the VM.
allowed_ips 192.168.143.0/24,fd8c:bc10:5021::/48 Comma-separated list of netmasks.
private_key GLEiXhRwFuhw8aPy+HQfSMwwoLU0Sw8jE8MOxZ8GV3w= Private key of the VM.
preshared_key PWAfvVWCjiNV0Uh2DhmXhdRaT326qosSOcaDB3j9dwI= Preshared key assigned to the VM.

License

Distributed under the MIT License. See LICENSE.txt for details.

setup-wireguard's People

Contributors

egor-tensin avatar highjagger 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.