stack.yml 1.0 KB

1234567891011121314151617181920212223242526272829
  1. # by default, the Ghost image will use SQLite (and thus requires no separate database container)
  2. # we have used MySQL here merely for demonstration purposes (especially environment-variable-based configuration)
  3. version: '3.1'
  4. services:
  5. ghost:
  6. image: ghost:4-alpine
  7. restart: always
  8. ports:
  9. - 8080:2368
  10. environment:
  11. # see https://ghost.org/docs/config/#configuration-options
  12. database__client: mysql
  13. database__connection__host: db
  14. database__connection__user: root
  15. database__connection__password: example
  16. database__connection__database: ghost
  17. # this url value is just an example, and is likely wrong for your environment!
  18. url: http://localhost:8080
  19. # contrary to the default mentioned in the linked documentation, this image defaults to NODE_ENV=production (so development mode needs to be explicitly specified if desired)
  20. #NODE_ENV: development
  21. db:
  22. image: mysql:8.0
  23. restart: always
  24. environment:
  25. MYSQL_ROOT_PASSWORD: example