https://github.com/devilbox/docker-ngrok
https://github.com/devilbox/docker-ngrok
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/devilbox/docker-ngrok
- Owner: devilbox
- License: mit
- Created: 2019-03-05T16:10:04.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2023-09-05T11:58:03.000Z (almost 2 years ago)
- Last Synced: 2025-04-20T19:38:46.954Z (2 months ago)
- Language: Shell
- Size: 56.6 KB
- Stars: 9
- Watchers: 3
- Forks: 9
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Ngrok
[](https://github.com/devilbox/docker-ngrok/actions?query=workflow%3Alint)
[](https://github.com/devilbox/docker-ngrok/actions?query=workflow%3Abuild)
[](https://github.com/devilbox/docker-ngrok/actions?query=workflow%3Anightly)[](https://github.com/devilbox/docker-ngrok/releases)
[](https://gitter.im/devilbox/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[](https://devilbox.discourse.group)
[](https://microbadger.com/images/devilbox/ngrok "ngrok")
[](https://microbadger.com/images/devilbox/ngrok "ngrok")
[](https://opensource.org/licenses/MIT)**Available Architectures:** `amd64`, `i386`, `arm64`, `arm/v7`, `arm/v6`, `ppc64le`, `s390x`, `mips64le`
| Docker Hub | Upstream Project |
|------------|------------------|
||
|
## Available Docker tags
| Docker Tag | Description |
|----------------------------------|---------------------------------------------------------------|
| `latest` | Latest Alpine image (default) |
| `alpine` | Latest Alpine image |
| `bookworm` | Latest Debian Bookworm image |
| `bullseye` | Latest Debian Bullseye image |
| `buster` | Latest Debian Buster image |
| `stretch` | Latest Debian Stretch image |
| | |
| `[0-9]\.[0-9]+` | Git tagged Alpine image. E.g: `0.53` |
| `alpine-[0-9]\.[0-9]+` | Git tagged Alpine image. E.g: `alpine-0.53` |
| `bookworm-[0-9]\.[0-9]+` | Git tagged Debian Stretch image. E.g: `bookworm-0.53` |
| `bullseye-[0-9]\.[0-9]+` | Git tagged Debian Stretch image. E.g: `bullseye-0.53` |
| `buster-[0-9]\.[0-9]+` | Git tagged Debian Stretch image. E.g: `buster-0.53` |
| `stretch-[0-9]\.[0-9]+` | Git tagged Debian Stretch image. E.g: `stretch-0.53` |
| | |
| `release-[0-9]\.[0-9]+` | Git branch Alpine image. E.g: `release-0.53` |
| `alpine-release-[0-9]\.[0-9]+` | Git branch Alpine image. E.g: `alpine-release-0.53` |
| `bookworm-release-[0-9]\.[0-9]+` | Git branch Debian Stretch image. E.g: `bookworm-release-0.53` |
| `bullseye-release-[0-9]\.[0-9]+` | Git branch Debian Stretch image. E.g: `bullseye-release-0.53` |
| `buster-release-[0-9]\.[0-9]+` | Git branch Debian Stretch image. E.g: `buster-release-0.53` |
| `stretch-release-[0-9]\.[0-9]+` | Git branch Debian Stretch image. E.g: `stretch-release-0.53` |## Documentation
In case you seek help, go and visit the community pages.
Documentation
Chat
Forum
![]()
![]()
![]()
devilbox.readthedocs.io
gitter.im/devilbox
devilbox.discourse.group
## Build
```bash
# Build the Docker image locally
make build# Rebuild the Docker image locally without cache
make rebuild# Test the Docker image after building
make test
```## Environment variables
| Variable | Default value | Description |
|--------------|---------------|-------------|
| HTTP_TUNNELS | `` | HTTP tunnel definition in the form of:<domain.tld>:<addr>:<port>
or<domain1.tld>:<addr>:<port>,<domain2.tld>:<addr>:<port>
Note: If you don't use a license you can only specify a single tunnel. If your license is pro enough, you can have multiple comma separated tunnels |
| REGION | `` | Choose the region where the ngrok client will connect to host its tunnels. (Defaults to `us`) |.
| AUTHTOKEN | `` | Your Ngrok license authtoken. You don't need to have a license for a single tunnel and can ommit this variable. Nevertheless they also have a free license that might be worth checking out |.### HTTP_TUNNELS
* `` is the virtual hostname that you want to serve via Ngrok
* `` is the hostname or IP address of the web server
* `` is the port on which the web server is reachable via HTTP```bash
# Make vhost "project1.loc" which runs on localhost:8080 available
HTTP_TUNNELS=project1.loc:localhost:8080# Make two vhosts available which run on host apache:80
HTTP_TUNNELS=project1.loc:apache:80,project2.loc:apache:80# Make two vhosts from two different web server addresses available
HTTP_TUNNELS=project1.loc:localhost:8080,project2.loc:apache:80
```### AUTHTOKEN
This token is provided to you after registering https://ngrok.com
## Exposed ports
| Container Port | Description |
|----------------|-------------|
| 4040 | Ngrok management console. Use it to obtain created outside DNS names after startup |## Example
Forward webserver running on host os on ip `192.168.0.2` on port `8080` to the internet via Ngrok.
```bash
docker run -d --rm --name devilbox-ngrok \
-e HTTP_TUNNELS="project1.loc:192.168.0.2:8080" \
-p "4040:4040" \
devilbox/ngrok
```Open up your browser at http://127.0.0.1:4040 to see your DNS names.
## License
**[MIT License](LICENSE)**
Copyright (c) 2019 [cytopia](https://github.com/cytopia)