Giter Club home page Giter Club logo

debugger-action's Introduction

Debugger Action

Two types of proxies are supported:

  • ngrok
  • frp

How to use by Ngork

Prerequisites

Usage

  1. Set up your Ngrok Authtoken as secrets in your repository settings using NGROK_TOKEN .

  2. Add the following to your workflow

- uses: shaowenchen/debugger-action@v2
  name: debugger
  timeout-minutes: 30
  continue-on-error: true
  with:
    ngrok_token: ${{ secrets.NGROK_TOKEN }}
  1. Run your workflow and login the runner

In the log of GitHub Actions, find localhost:8000 and you can see that:

t=2021-01-19T03:57:10+0000 lvl=info msg="started tunnel" obj=tunnels name=command_line addr=//localhost:8000 url=tcp://2.tcp.ngrok.io:16400
ssh [email protected] -p 16400

Input RootPassword: root

  1. Debugger the runner
$ ls

factory
key.pem
perflog
runners
warmup
work

runners is the working directory of workflow

Parameters

ngrok_token

Required Authenticate to ngrok agent.

ngrok_proto_{x} and ngrok_proto_{x}

x in [1, 2, 3] , e.g:

- uses: shaowenchen/debugger-action@v2
  name: debugger
  timeout-minutes: 30
  continue-on-error: true
  with:
    ngrok_token: ${{ secrets.NGROK_TOKEN }}
    ngrok_addr_1: 30000
    ngrok_proto_1: tcp
    ngrok_addr_2: 30001
    ngrok_proto_2: tcp
    ngrok_addr_3: 30002
    ngrok_proto_3: tcp

It will expose these services to Ngrok. The maximum number of tunnels is 3, and http will take up 2 .

How to use by Frp Server

Prerequisites

Usage

  1. Set up your credentials as secrets in your repository settings using FRP_SERVER_ADDR, FRP_SERVER_PORT, FRP_TOKEN, SSH_PORT
Secrets Frp Server
FRP_SERVER_ADDR You Server IP
FRP_SERVER_PORT Bind port
FRP_TOKEN token

SSH_PORT is used to login the runner, a custom set , e.g 20090 .

  1. Add the following to your workflow
- uses: shaowenchen/debugger-action@v2
  name: debugger
  timeout-minutes: 30
  continue-on-error: true
  with:
    frp_server_addr: ${{ secrets.FRP_SERVER_ADDR }}
    frp_server_port: ${{ secrets.FRP_SERVER_PORT }}
    frp_token: ${{ secrets.FRP_TOKEN }}
    ssh_port: ${{ secrets.SSH_PORT }}
  1. Run your workflow and login the runner

Each runner needs a unique ssh_port value.

ssh root@frp_server_addr -p ssh_port 

Input RootPassword: root

  1. Debugger the runner
$ ls

factory
key.pem
perflog
runners
warmup
work

runners is the working directory of workflow

Parameters

timeout-minutes

The length of time you want to debug the action.

frp_server_addr

Required IP address of the remote frps server.

frp_server_port

Required Port of the remote frps server.

frp_token

Required Token of the remote frps server.

ssh_port

Required Port to login the runner

License

MIT license

debugger-action's People

Contributors

shaowenchen avatar dependabot[bot] avatar tiancang 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.