Skip to content

Commit a2bda47

Browse files
1 parent 6fe6aed commit a2bda47

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

docs/installation.rst

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,3 +102,15 @@ settings module::
102102
You can change the logic of determining whether or not the Debug Toolbar
103103
should be shown with the :ref:`SHOW_TOOLBAR_CALLBACK <SHOW_TOOLBAR_CALLBACK>`
104104
option. This option allows you to specify a custom function for this purpose.
105+
106+
.. warning::
107+
108+
If using Docker the following will set your internal ips correctly only if you are in Debug mode.::
109+
110+
if DEBUG:
111+
import os # only if you haven't already imported this
112+
import socket # only if you haven't already imported this
113+
hostname, _, ips = socker.gethostbyname_ex(socket.gethostname())
114+
INTERNAL_IPS = [ip[:-1] + '1' for ip in ips] + ['127.0.0.1', '10.0.2.2']
115+
116+

0 commit comments

Comments
 (0)