Code Monkey home page Code Monkey logo

ngrok-file-server's Introduction

ngrok-file-server

Test, Build and Save

codecov

Go Reference

ngrok-file-server is a tiny secured file server :bowtie:

You can quickly share any content running a simple docker image !!!

It's fast ๐Ÿš€, secured ๐Ÿ”’ and pretty lite ๐Ÿ

๐Ÿ‘‰ Requirements

What do you really need ?

ngrok token

https tunneling (port-forwarding) is provided by ngork go implementation. So, you need a ngrok token ๐Ÿ”‘

... if don't have a ngrok account, don't worry, it's free ๐Ÿ˜ฌ

docker

If you're familiar with golang, you can build your own server but we recommand to use our docker image ๐Ÿณ

You can download docker desktop and use default settings.

โ–ถ๏ธ Run

Ok, so now, you may have a ngrok token and run docker on your machine.

1๏ธโƒฃ Let's start the server.

Run the following docker command in order to share the content of your local path.

docker run -it --rm -e NGROK_AUTHTOKEN="YOUR_TOKEN" -v $(pwd):/shared ghcr.io/trendev/ngrok-file-server

this example is based on Linux/MacOS usage. If you run ngrok-file-server on Windows, you may change local path command $(pwd) by something like %cd% or direcly set the path...

do not forget to replace "YOUR_TOKEN" by your ngrok token...

It will pull our docker image and then, build and start a new container ๐Ÿ‘

You may see an output like this :

ngrok ingress url: https://2927-90-22-212-26.eu.ngrok.io

Copy the URL ๐Ÿ“

2๏ธโƒฃ Visit the file server from anywhere

Paste the previous URL in your favorite web browser.

if you use a free ngrok account, please, just accept the disclaimer ๐Ÿ˜ฝ

And here we are โœ…

You can browse your content and share the URL with anyone and access to your file server from anywhere ๐Ÿ˜Ž

๐Ÿ‘ฎ OAuth2 Protection

You can also control access using an oauth2 provider (like Google, Facebook, Github, Linkedin, etc) and setting an authorized domain (for eg, only trendev.fr users).

you can find the supported list here

Enable oauth2 authentication

docker run -it --rm -e NGROK_AUTHTOKEN=$NGROK_AUTHTOKEN -v $(pwd):/shared ghcr.io/trendev/ngrok-file-server --provider=google

Enable oauth2 authentication + domain control

docker run -it --rm -e NGROK_AUTHTOKEN=$NGROK_AUTHTOKEN -v $(pwd):/shared ghcr.io/trendev/ngrok-file-server --provider=google --domain=trendev.fr

โœ‹ Something else ?

If you need more, you can open an issue and describe your requirement... and BTW, you can also star the repo ๐Ÿ˜‰

ngrok-file-server's People

Contributors

whyvrafvr avatar

Watchers

 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.