diff --git a/.travis.yml b/.travis.yml index 8316e46..2a67136 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,12 +1,11 @@ lang: python -# blocklist branches: except: - leanpub-preview - leanpub-publish script: - - scripts/markdown-to-markua.sh +- scripts/markdown-to-markua.sh after_success: - - scripts/push-markua-to-branch.sh +- scripts/push-markua-to-branch.sh env: - secure: "X0ruiXtzArHPaOAd5cQS0axHGwMM5HwqSHASr/KnzV1yZUPzJIrzJQYSCJmFPzk6zuboA2Tsa96zu+DftgA9N9WgzTYmjp8M10y9vcK4cpkfi5frs7GVorVLPQ5kcWwYPf/j+YzpP5OwrRSxDDG853GJ4OhoALcjmmBJk8NwIKZOkA6x2RvvcDRx6dc216QdhmouD5Hz0tImkE2rYdQNm44IN7OF6wekbEhOzN2Chz6yGit3duRvxBrNOPqmGqkFwtg0sxyQO0iBa4qvg88qrKQOIHwUG5y4rp8QcdqfRMv/lSNGEg1Mh7iDUHbZpvcAoXREXp9FMEY/SJ1uYkcEMn+GvLDQ/BOFwKjC/duWM3oMPgzjqI+gwpIdlTZt5+Qu9v4Z6+XJ5P+JIWZYtzudDVuOzVMSIzwk9y2a/ufYXGQdvGktf6H51WCcA8CO2muxLtDwDtV1okAVm+HXkgQ/pcwjqqq3n3RojN6Xxm+TJggn3HgU21qug/K1lukycwCjQbI8s0ey3soT1+oPc8Fl95n35eXTUY3DOd0u14e0Y3XKIbG9Rvyp9U8gJC2Ij6+EXSdHlFhvr5tJJLNwXkXjV3yMnLgtlSnuGBGHUpv0+XZuSsGqOropl/KDUurb2TGkIH7PjpBpFm6PhSbLViGXrupuxTvKLdsXBXospzODuEQ=" + secure: X0ruiXtzArHPaOAd5cQS0axHGwMM5HwqSHASr/KnzV1yZUPzJIrzJQYSCJmFPzk6zuboA2Tsa96zu+DftgA9N9WgzTYmjp8M10y9vcK4cpkfi5frs7GVorVLPQ5kcWwYPf/j+YzpP5OwrRSxDDG853GJ4OhoALcjmmBJk8NwIKZOkA6x2RvvcDRx6dc216QdhmouD5Hz0tImkE2rYdQNm44IN7OF6wekbEhOzN2Chz6yGit3duRvxBrNOPqmGqkFwtg0sxyQO0iBa4qvg88qrKQOIHwUG5y4rp8QcdqfRMv/lSNGEg1Mh7iDUHbZpvcAoXREXp9FMEY/SJ1uYkcEMn+GvLDQ/BOFwKjC/duWM3oMPgzjqI+gwpIdlTZt5+Qu9v4Z6+XJ5P+JIWZYtzudDVuOzVMSIzwk9y2a/ufYXGQdvGktf6H51WCcA8CO2muxLtDwDtV1okAVm+HXkgQ/pcwjqqq3n3RojN6Xxm+TJggn3HgU21qug/K1lukycwCjQbI8s0ey3soT1+oPc8Fl95n35eXTUY3DOd0u14e0Y3XKIbG9Rvyp9U8gJC2Ij6+EXSdHlFhvr5tJJLNwXkXjV3yMnLgtlSnuGBGHUpv0+XZuSsGqOropl/KDUurb2TGkIH7PjpBpFm6PhSbLViGXrupuxTvKLdsXBXospzODuEQ= diff --git a/manuscript/book.txt b/manuscript/book.txt index 536920d..ec5eb43 100644 --- a/manuscript/book.txt +++ b/manuscript/book.txt @@ -14,6 +14,7 @@ ha-docker-swarm/traefik.md ha-docker-swarm/docker-swarm-mode.md ha-docker-swarm/duplicity.md +<<<<<<< HEAD sections/recipes.md recipes/autopirate.md recipes/elkarbackup.md @@ -38,6 +39,23 @@ recipes/privatebin.md recipes/swarmprom.md recipes/wekan.md +======= +sections/recipies.md +recipies/mail.md +recipies/gitlab.md +recipies/gitlab-runner.md +recipies/wekan.md +recipies/huginn.md +recipies/kanboard.md +recipies/miniflux.md +recipies/ghost.md +recipies/piwik.md +recipies/autopirate.md +recipies/nextcloud.md +recipies/portainer.md +recipies/turtle-pool.md +recipies/tiny-tiny-rss.md +>>>>>>> markdown-to-markua sections/reference.md reference/oauth_proxy.md @@ -45,3 +63,4 @@ reference/data_layout.md reference/networks.md reference/git-docker.md reference/openvpn.md +reference/troubleshooting.md diff --git a/manuscript/ha-docker-swarm/design.md b/manuscript/ha-docker-swarm/design.md index db3c61e..9b718f3 100644 --- a/manuscript/ha-docker-swarm/design.md +++ b/manuscript/ha-docker-swarm/design.md @@ -51,7 +51,7 @@ Assuming 3 nodes, under normal circumstances the following is illustrated: * The **traefik** service (in swarm mode) receives incoming requests (on http and https), and forwards them to individual containers. Traefik knows the containers names because it's able to access the docker socket. * All 3 nodes run keepalived, at different priorities. Since traefik is running as a swarm service and listening on TCP 80/443, requests made to the keepalived VIP and arriving at **any** of the swarm nodes will be forwarded to the traefik container (no matter which node it's on), and then onto the target backend. -![HA function](images/docker-swarm-ha-function.png) +![HA function](../images/docker-swarm-ha-function.png) ### Node failure @@ -63,7 +63,7 @@ In the case of a failure (or scheduled maintenance) of one of the nodes, the fol * The **traefik** service is either restarted or unaffected, and as the backend containers stop/start and change IP, traefik is aware and updates accordingly. * The keepalived VIP continues to function on the remaining nodes, and docker swarm continues to forward any traffic received on TCP 80/443 to the appropriate node. -![HA function](images/docker-swarm-node-failure.png) +![HA function](../images/docker-swarm-node-failure.png) ### Node restore @@ -75,7 +75,7 @@ When the failed (or upgraded) host is restored to service, the following is illu * Keepalived VIP regains full redundancy -![HA function](images/docker-swarm-node-restore.png) +![HA function](../images/docker-swarm-node-restore.png) ### Total cluster failure diff --git a/manuscript/ha-docker-swarm/images/shared-storage-replicated-gluster-volume.png b/manuscript/ha-docker-swarm/images/shared-storage-replicated-gluster-volume.png deleted file mode 100644 index 135a63f..0000000 Binary files a/manuscript/ha-docker-swarm/images/shared-storage-replicated-gluster-volume.png and /dev/null differ diff --git a/manuscript/ha-docker-swarm/images/docker-swarm-ha-function.png b/manuscript/images/docker-swarm-ha-function.png similarity index 100% rename from manuscript/ha-docker-swarm/images/docker-swarm-ha-function.png rename to manuscript/images/docker-swarm-ha-function.png diff --git a/manuscript/ha-docker-swarm/images/docker-swarm-node-failure.png b/manuscript/images/docker-swarm-node-failure.png similarity index 100% rename from manuscript/ha-docker-swarm/images/docker-swarm-node-failure.png rename to manuscript/images/docker-swarm-node-failure.png diff --git a/manuscript/ha-docker-swarm/images/docker-swarm-node-restore.png b/manuscript/images/docker-swarm-node-restore.png similarity index 100% rename from manuscript/ha-docker-swarm/images/docker-swarm-node-restore.png rename to manuscript/images/docker-swarm-node-restore.png diff --git a/scripts/markdown-to-markua.sh b/scripts/markdown-to-markua.sh index 3abed57..a9c1718 100755 --- a/scripts/markdown-to-markua.sh +++ b/scripts/markdown-to-markua.sh @@ -1,3 +1,30 @@ #!/bin/bash -echo "Nananana... Batman!" > manuscript/test.md + +# Markua doesn't know what to do with 4 backticks (````), so convert to 3: +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/\`\`\`\`/\`\`\`/g" + +# Markua doesn't like emojis, so remove them: +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/👏//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/💬//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/👍//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/💰//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/🍷//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/🏢//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/❤️//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/🐢//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/👋//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/🐦//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/📖//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/✉️//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/📺//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/🎥//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/🎵//g" +find manuscript -type f -name "*.md" -print0 | xargs -0 sed -i "s/😁//g" + + + + + + + # Do nothing, yet. This is where the sed magic will go diff --git a/scripts/push-markua-to-branch.sh b/scripts/push-markua-to-branch.sh index 1c70a66..7d75f9f 100755 --- a/scripts/push-markua-to-branch.sh +++ b/scripts/push-markua-to-branch.sh @@ -19,6 +19,13 @@ upload_files() { git push --quiet --set-upstream origin-leanpub-preview leanpub-preview } +# Not needed at this stage, since github integration still works. It's noted as being deprecated however, +# so might need this in future +#trigger_preview() { +# curl -d "api_key=${LEANPUB-API-KEY}" https://leanpub.com/geek-cookbook/preview.json +#} + setup_git commit_website_files upload_files +#trigger_preview