forked from kubenow/KubeNow
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Marco Capuccini
committed
Nov 10, 2016
1 parent
b85b07e
commit 4f66590
Showing
6 changed files
with
64 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
- name: "clean Cloudflare" | ||
command: ansible-playbook playbooks/clean-cloudflare.yml | ||
args: | ||
chdir: "{{playbook_dir}}/.." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
- name: "render cloudflare configuration" | ||
template: | ||
args: | ||
src: "{{playbook_dir}}/secrets-kubenow/cloudflare/conf.yml.j2" | ||
dest: "{{playbook_dir}}/../stacks/traefik-lb/roles/cloudflare/vars/conf.yml" | ||
notify: "clean Cloudflare" | ||
|
||
- name: "deploy stack/cheese-deployment" | ||
command: > | ||
ansible-playbook | ||
-e "domain_name={{test_timestamp}}.test.{{cf_zone}}" | ||
stacks/cheese-deployment/main.yml | ||
args: | ||
chdir: "{{playbook_dir}}/.." | ||
|
||
- name: "test stilton" | ||
include: > | ||
test-page.yml | ||
cheese=stilton | ||
search_for=Stilton | ||
- name: "test wensleydale" | ||
include: > | ||
test-page.yml | ||
cheese=wensleydale | ||
search_for=Wensleydale | ||
- name: "test cheddar" | ||
include: > | ||
test-page.yml | ||
cheese=cheddar | ||
search_for=Cheddar |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
- name: "test endpoint" | ||
command: > | ||
curl --silent --head | ||
-H "host: {{cheese}}.{{test_timestamp}}.test.{{cf_zone}}" | ||
http://{{cheese}}.{{test_timestamp}}.test.{{cf_zone}} | ||
register: head | ||
until: head.stdout.find("200 OK") != -1 | ||
retries: 5 | ||
delay: 30 | ||
|
||
- name: "test page" | ||
action: > | ||
uri | ||
url=http://{{cheese}}.{{test_timestamp}}.test.{{cf_zone}} | ||
return_content=yes | ||
register: body | ||
|
||
- name: "fail on missing '{{search_for}}' in page" | ||
fail: msg="missing '{{search_for}}' in page" | ||
when: "'{{search_for}}' not in body.content" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Submodule secrets-kubenow
updated
from b44306 to e29c7f