You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

40 lines
1.9 KiB

  1. <h1>Running with Docker</h1>
  2. <p>In the Healthchecks source code, <a href="https://github.com/healthchecks/healthchecks/tree/master/docker">/docker/ directory</a>,
  3. you can find a sample configuration for running the project with
  4. <a href="https://www.docker.com">Docker</a> and <a href="https://docs.docker.com/compose/">Docker Compose</a>.</p>
  5. <p><strong>Note: The Docker configuration is a recent addition, and, for the time being,
  6. should be considered as highly experimental</strong>.</p>
  7. <p>Note: For the sake of simplicity, the sample configuration starts a single database
  8. node and a single web server node, both on the same host. It also does not handle SSL
  9. termination. If you plan to expose it to the public internet, make sure you put a
  10. SSL-terminating load balancer or reverse proxy in front of it.</p>
  11. <h2>Getting Started</h2>
  12. <ul>
  13. <li>Grab the Healthchecks source code
  14. <a href="https://github.com/healthchecks/healthchecks">from the Github repository</a>.</li>
  15. <li>Add your <a href="../self_hosted_configuration/">configuration</a> in the <code>/docker/.env</code> file.
  16. As a minimum, set the following fields:<ul>
  17. <li><code>DEFAULT_FROM_EMAIL</code> – the "From:" address for outbound emails</li>
  18. <li><code>EMAIL_HOST</code> – the SMTP server</li>
  19. <li><code>EMAIL_HOST_PASSWORD</code> – the SMTP password</li>
  20. <li><code>EMAIL_HOST_USER</code> – the SMTP username</li>
  21. <li><code>SECRET_KEY</code> – secures HTTP sessions, set to a random value</li>
  22. </ul>
  23. </li>
  24. <li>
  25. <p>Create and start containers:</p>
  26. <div class="highlight"><pre><span></span><code>$ <span class="nb">cd</span> docker
  27. $ docker-compose up
  28. </code></pre></div>
  29. </li>
  30. <li>
  31. <p>Create a superuser:</p>
  32. <div class="highlight"><pre><span></span><code>$ docker-compose run web /opt/healthchecks/manage.py createsuperuser
  33. </code></pre></div>
  34. </li>
  35. <li>
  36. <p>Open <a href="http://localhost:8000">http://localhost:8000</a> in your browser and log in with
  37. the credentials from the previous step.</p>
  38. </li>
  39. </ul>