Skip to content
This repository has been archived by the owner on Jun 14, 2018. It is now read-only.

Getting started

Christoffer Jansson edited this page May 27, 2016 · 2 revisions

Your admin or colleague gave you a hostname told you to use mole? Do this:

  1. If you don't have it, get a mole binary for your platform from the Releases page.

  2. Register with the server.

    $ mole register <hostname>
    
  3. Check what tunnel definitions are available. This will require you to log in, which will grant you a ticket. The ticket is valid for requests from the same IP for a configurable time period (a week, by default).

    $ mole ls
    
  4. Connect to a tunnel:

    $ sudo mole dig <tunnelname>
    

Write a New Tunnel Definition

  1. Read through the Configuration Reference.

  2. Create a tunnel definition file with an .ini extension in your home directory.

  3. Test the tunnel definition:

    $ mole dig -l whateverfile.ini
    
  4. When you're happy, push it to the server:

    $ mole push whateverfile.ini
    

Edit an Existing Tunnel Definition

  1. Export the existing tunnel config to a local file:

    $ mole show -r whatever > whatever.ini
    
  2. Edit the file whatever.ini to taste.

  3. Test the tunnel definition:

    $ mole dig -l whateverfile.ini
    
  4. When you're happy, push it to the server:

    $ mole push whateverfile.ini
    
Clone this wiki locally