Based on rgarrigue.docker-ghost-blog.
This role installs the dockerised ghost blog on an Ubuntu server.
We presume the use of Traefik as our reverse proxy, and use git to back our blog content up to a repository.
We assume that we've probably run:
The above all chain as dependencies of our main dependency:
It will be available at https://blog.domain.tld, and administration interface is at https://blog.domain.tld/admin
Blog content is under /etc/ghost
Developed and tested on Ubuntu Server 16.10 Yakkety, but should work on other OSes.
It's running on Docker.
For let's encrypt certificate, and automatic reverse proxy
ghost.owner
defaults to adminghost.owner_password
defaults to WHATEVERghost.domain
defaults to domain.tldghost.source
: defaults to domain.tldghost.install_dir
defaults to /etc/ghostghost.remote
defaults to git@bitbucket.org:whever/blog.gitghost.mail.transport
defaults to SMTPghost.mail.smtp_service
defaults to Mailgunghost.mail.user
defaults to postmaster@blog.domain.tldghost.mail.pass
defaults to password
mebooks.ansible-role-docker-traefik
- hosts: remote
remote_user: deploy
become: true
become_user: root
become_method: sudo
vars:
traefik_testing: true
owner: administrator
domain: mebooks.co.nz
email: mebooks.support@gmail.com
users:
# owner_password / owner_password_encrypted are defined in the unversioned group_vars/remote
- username: "{{ ghost.owner }}"
password: "{{ ghost.owner_password }}"
acl:
- traefik
ghost:
domain: blog.mebooks.co.nz
install_dir: /etc/ghost
remote: git@bitbucket.org:jcdarwin/blog.git
# theme_url: https://jcdarwin@bitbucket.org/jcdarwin/ghost-theme-goblin.git
# theme_name: goblin
mail:
transport: SMTP # or SES
smtp_service: Mailgun # or ~
user: postmaster@blog.mebooks.co.nz
# pass is defined in the unversioned group_vars/remote
# pass: WHATEVER
roles:
# We presume we've already run ansible-role-users and ansible-role-common
# The following role is listed as dependencies in ansible-role-docker-traefik/meta/main.yml:
# - role: ansible-role-docker
# The following role is listed as dependencies in ansible-role-docker-ghost/meta/main.yml:
# - role: ansible-role-docker-traefik
- role: ansible-role-docker-ghost
GPLv3
Jason Darwin