Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .devilbox/www/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@


$DEVILBOX_VERSION = 'v0.15';
$DEVILBOX_DATE = '2019-03-04';
$DEVILBOX_DATE = '2019-03-06';
$DEVILBOX_API_PAGE = 'devilbox-api/status.json';

//
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ major versions.
- Blackfire
- ELK (Elastic Search, Logstash and Kibana)
- MailHog
- Ngrok
- RabbitMQ
- Solr
- Varnish
Expand Down
9 changes: 7 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ Each of them is also available in multiple different versions in order to reflec
| HAProxy | Apache | MariaDB | Memcached | RabbitMQ | Solr | ElasticSearch | Bind |
| Varnish | Nginx | MySQL | MongoDB | | | Logstash | Blackfire |
| | PHP | PerconaDB | Redis | | | Kibana | MailHog |
| | | PostgreSQL | | | | | |
| | | PostgreSQL | | | | | Ngrok |

> **Documentation:**
> [Available Container](https://devilbox.readthedocs.io/en/latest/readings/available-container.html)
Expand Down Expand Up @@ -363,6 +363,7 @@ Additionally to the default stack, there are a variety of other services that ca
<th>Blackfire</th>
<th>ELK</th>
<th>MailHog</th>
<th>Ngrok</th>
<th>RabbitMQ</th>
<th>Solr</th>
<th>HAProxy</th>
Expand All @@ -374,15 +375,17 @@ Additionally to the default stack, there are a variety of other services that ca
<td><a target="_blank" title="Blackfire 1.8" href="https://github.com/blackfireio/docker">1.8</a></td>
<td><a target="_blank" title="ELK stack" href="https://www.docker.elastic.co">5.x.y</a></td>
<td><a target="_blank" title="MailHog v1.0.0" href="https://github.com/mailhog/MailHog">v1.0.0</a></td>
<td><a target="_blank" title="Ngrok 2.x" href="https://github.com/devilbox/docker-ngrok">2.x</a></td>
<td><a target="_blank" title="RabbitMQ 3.6" href="https://github.com/rabbitmq/rabbitmq-server">3.6</a></td>
<td><a target="_blank" title="Solr 5" href="https://github.com/apache/lucene-solr">5</a></td>
<td><a target="_blank" title="HAProxy 1.X" href="https://github.com/devilbox/docker-haproxy">1.X</a></td>
<td><a target="_blank" title="HAProxy 1.x" href="https://github.com/devilbox/docker-haproxy">1.x</a></td>
<td><a target="_blank" title="Varnish 4" href="https://github.com/devilbox/docker-varnish">4</a></td>
</tr>
<tr>
<td>...</td>
<td><a target="_blank" title="ELK stack" href="https://www.docker.elastic.co">6.x.y</a></td>
<td><a target="_blank" title="MailHog latest" href="https://github.com/mailhog/MailHog">latest</a></td>
<td></td>
<td><a target="_blank" title="RabbitMQ 3.7" href="https://github.com/rabbitmq/rabbitmq-server">3.7</a></td>
<td><a target="_blank" title="Solr 6" href="https://github.com/apache/lucene-solr">6</a></td>
<td></td>
Expand All @@ -392,6 +395,7 @@ Additionally to the default stack, there are a variety of other services that ca
<td><a target="_blank" title="Blackfire 1.18.0" href="https://github.com/blackfireio/docker">1.18.0</a></td>
<td><a target="_blank" title="ELK stack" href="https://www.docker.elastic.co">7.x.y</a></td>
<td></td>
<td></td>
<td><a target="_blank" title="RabbitMQ latest" href="https://github.com/rabbitmq/rabbitmq-server">latest</a></td>
<td><a target="_blank" title="Solr 7" href="https://github.com/apache/lucene-solr">7</a></td>
<td></td>
Expand All @@ -402,6 +406,7 @@ Additionally to the default stack, there are a variety of other services that ca
<td></td>
<td></td>
<td></td>
<td></td>
<td><a target="_blank" title="Solr latest" href="https://github.com/apache/lucene-solr">latest</a></td>
<td></td>
<td><a target="_blank" title="Varnish latest" href="https://github.com/devilbox/docker-varnish">latest</a></td>
Expand Down
19 changes: 19 additions & 0 deletions compose/docker-compose.override.yml-all
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,25 @@ services:
- php
- httpd

# -----------------------------------------------------------------------------------------------
# Ngrok
# -----------------------------------------------------------------------------------------------
ngrok:
image: devilbox/ngrok:0.2
hostname: ngrok
environment:
- HTTP_TUNNELS=${NGROK_HTTP_TUNNELS:-httpd:httpd:80}
- AUTHTOKEN=${NGROK_AUTHTOKEN:-}
ports:
- "${LOCAL_LISTEN_ADDR}${HOST_PORT_NGROK:-4040}:4040"
networks:
app_net:
ipv4_address: 172.16.238.202
depends_on:
- bind
- php
- httpd

# -----------------------------------------------------------------------------------------------
# RabbitMQ
# -----------------------------------------------------------------------------------------------
Expand Down
23 changes: 23 additions & 0 deletions compose/docker-compose.override.yml-ngrok
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# vim: set ft=yaml:
version: '2.1'

services:

# -----------------------------------------------------------------------------------------------
# Ngrok
# -----------------------------------------------------------------------------------------------
ngrok:
image: devilbox/ngrok:0.2
hostname: ngrok
environment:
- HTTP_TUNNELS=${NGROK_HTTP_TUNNELS:-httpd:httpd:80}
- AUTHTOKEN=${NGROK_AUTHTOKEN:-}
ports:
- "${LOCAL_LISTEN_ADDR}${HOST_PORT_NGROK:-4040}:4040"
networks:
app_net:
ipv4_address: 172.16.238.202
depends_on:
- bind
- php
- httpd
12 changes: 12 additions & 0 deletions docs/_includes/links/documentation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,18 @@
Dockerhub: MailHog <img src="https://raw.githubusercontent.com/cytopia/icons/master/11x11/ext-link.png" />
</a>

.. |ext_lnk_ngrok_github| raw:: html

<a target="_blank" href="https://github.com/devilbox/docker-ngrok">
Github: ngrok <img src="https://raw.githubusercontent.com/cytopia/icons/master/11x11/ext-link.png" />
</a>

.. |ext_lnk_ngrok_dockerhub| raw:: html

<a target="_blank" href="https://hub.docker.com/r/devilbox/ngrok/">
Dockerhub: ngrok <img src="https://raw.githubusercontent.com/cytopia/icons/master/11x11/ext-link.png" />
</a>

.. |ext_lnk_blackfire_github| raw:: html

<a target="_blank" href="https://github.com/blackfireio/docker">
Expand Down
2 changes: 2 additions & 0 deletions docs/_includes/snippets/additional-container.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
+-------------------------------------+-----------+-----------+----------------+
| MailHog | mailhog | mailhog | 172.16.238.201 |
+-------------------------------------+-----------+-----------+----------------+
| Ngrok | ngrok | ngrok | 172.16.238.202 |
+-------------------------------------+-----------+-----------+----------------+
| RabbitMQ | rabbit | rabbit | 172.16.238.210 |
+-------------------------------------+-----------+-----------+----------------+
| Solr | solr | solr | 172.16.238.220 |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ However, each example also exists in its standalone file as shown below:
├── docker-compose.override.yml-blackfire
├── docker-compose.override.yml-elk
├── docker-compose.override.yml-mailhog
├── docker-compose.override.yml-ngrok
├── docker-compose.override.yml-rabbitmq
├── docker-compose.override.yml-solr
├── docker-compose.override.yml-varnish
Expand Down
133 changes: 133 additions & 0 deletions docs/corporate-usage/showcase-over-the-internet.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,133 @@
.. include:: /_includes/all.rst

.. _showcase_over_the_internet:

**************************
Showcase over the internet
**************************

**Table of Contents**

.. contents:: :local:


Why
===

Sometimes it is just convinient to make your local project available over the internet to quickly
showcase your current work to a customer. Instead of having to deploy it somewhere and even be able
to live code during the showcase the Devilbox provides an easy way to accomplish exactly this via
Ngrok.


How
===

First you want to add Ngrok to the Devilbox stack via its pre-defined Docker Compose override file.

.. seealso:: * :ref:`custom_container_enable_ngrok`

Once you have followed the above documentation everything works with default settings. To actually
customize and choose the virtual host to expose you will need to alter the ``NGROK_HTTP_TUNNELS``
.env variable.

How this can be done exactly will be shown in a couple of examples below.

Examples
--------

Recall the following formats for the variable:

* ``<domain.tld>:<addr>:<port>``
* ``<domain1.tld>:<addr>:<port>,<domain2.tld>:<addr>:<port>``

.. note:: Even more than two tunnels are supported, but this will again depend on your Ngrok license.

Where each individual part consists of:

* ``<domain.tld>`` is the virtual hostname that you want to serve via Ngrok
* ``<addr>`` is the hostname or IP address of the web server
* ``<port>`` is the port on which the web server is reachable via HTTP

Expose ``my-project.loc`` via web server
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

* ``<domain.tld>``: my-project.loc
* ``<addr>``: httpd
* ``<port>``: httpd80

So the resulting ``.env`` value will be:

.. code-block:: bash

NGROK_HTTP_TUNNELS=my-project.loc:httpd:80

Expose ``my-project.loc`` via Varnish
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

* ``<domain.tld>``: my-project.loc
* ``<addr>``: varnish
* ``<port>``: 6081

So the resulting ``.env`` value will be:

.. code-block:: bash

NGROK_HTTP_TUNNELS=my-project.loc:varnish:6081

Expose ``my-project.loc`` via HAProxy
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
* ``<domain.tld>``: my-project.loc
* ``<addr>``: haproxy
* ``<port>``: 80

So the resulting ``.env`` value will be:

.. code-block:: bash

NGROK_HTTP_TUNNELS=my-project.loc:haproxy:80


Expose ``my-project.loc`` and ``website1.loc`` via web server
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. note:: Exposing more than one vhost will require a pro enough license from Ngrok.

* ``<domain.tld>``: my-project.loc
* ``<addr>``: httpd
* ``<port>``: 80

and

* ``<domain.tld>``: website1.loc
* ``<addr>``: httpd
* ``<port>``: 80


So the resulting ``.env`` value will be:

.. code-block:: bash

NGROK_HTTP_TUNNELS=my-project.loc:httpd:80,website1.loc:httpd:80

Expose ``my-project.loc`` via web server and varnish
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

.. note:: Exposing more than one vhost will require a pro enough license from Ngrok.

* ``<domain.tld>``: my-project.loc
* ``<addr>``: httpd
* ``<port>``: 80

and


* ``<domain.tld>``: my-project.loc
* ``<addr>``: varnish
* ``<port>``: 6081

So the resulting ``.env`` value will be:

.. code-block:: bash

NGROK_HTTP_TUNNELS=my-project.loc:httpd:80,my-project.loc:varnish:6081
1 change: 1 addition & 0 deletions docs/custom-container/enable-all-container.rst
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ In order to fully customize each container, refer to their own documentation sec
* :ref:`custom_container_enable_blackfire`
* :ref:`custom_container_enable_elk_stack`
* :ref:`custom_container_enable_mailhog`
* :ref:`custom_container_enable_ngrok`
* :ref:`custom_container_enable_rabbitmq`
* :ref:`custom_container_enable_solr`
* :ref:`custom_container_enable_varnish`
Loading