diff options
-rw-r--r-- | .travis.yml | 13 | ||||
-rw-r--r-- | GNUmakefile | 2 | ||||
-rwxr-xr-x | scripts/launch-website.sh | 11 |
3 files changed, 24 insertions, 2 deletions
diff --git a/.travis.yml b/.travis.yml index a20fc58..cc6e6c7 100644 --- a/.travis.yml +++ b/.travis.yml | |||
@@ -19,7 +19,18 @@ script: | |||
19 | - make vet | 19 | - make vet |
20 | - make website-test | 20 | - make website-test |
21 | - make shellcheck | 21 | - make shellcheck |
22 | - make website-githubpages | ||
22 | 23 | ||
24 | deploy: | ||
25 | provider: pages | ||
26 | skip_cleanup: true | ||
27 | github_token: $GITHUB_TOKEN | ||
28 | target_branch: gh-pages | ||
29 | keep_history: true | ||
30 | local_dir: terraform-provider-website | ||
31 | on: | ||
32 | all_branches: true | ||
33 | |||
23 | matrix: | 34 | matrix: |
24 | fast_finish: true | 35 | fast_finish: true |
25 | allow_failures: | 36 | allow_failures: |
@@ -33,5 +44,3 @@ cache: | |||
33 | env: | 44 | env: |
34 | matrix: | 45 | matrix: |
35 | - GO111MODULE=on | 46 | - GO111MODULE=on |
36 | global: | ||
37 | - secure: rWjnWJgGEk2ncl6TXnpahUmriGSEaHGy+ZfmKKGpvrZxnlNY6sy63+qrnJNwaiV6uRG+kPfEChYD+dYfhjZRb3JWivo/ILCM9E0M9Ike6YAAsJKrcl0rUwFgqhBVXRdpBCSieYGiY8xNH/4Wu6i4bD9F1vSmpkvxYwae+7vGvyhEhyGMqWU92Svlus//K0Y27Qvlcw+Mx35nhdZsaeKN1Tb7uCHed9+vpCHud9NpSJLqxBjQl+1ibJ0Fqefyqbqy5dO0X3xE70eUMwM70ew+sgwzyq45VDBRPtVAN+8mtLOp2BVZE7SXFydfqnAm+1cbgzYBE5t+HlXwZzpRrtSwj+NRUt+7UtlrdfhMRmUVW76qWyMbF8CY6i06a73XWMYffKg3Ux2h0AHimvPJl8y+luMYmrl0RdgyLDcR0t9La0PNhOrKsauzkNX7KGPZwjTWv3+2RrsXDdT0Pi3JL15myyEuxiSAdDLIyiFB0sz9mCzYiu02SKKyURfo3bhMUrrBRbF47CpLTiCJrNBI36rk/cO4QJXyd9axEhy7vXiQObvaWZKbBqMTsL9EOZijJt5I1UxjwbCGM/GyYSrDK/+7d7PF0bvjo+8ps/o2WIW5B63IZiadzIt6nUOlEpFoOUsn0x4mufzIzMd+CSXdTxdXqRIXHxf5pKAUQZ8u7uRwERY= | ||
diff --git a/GNUmakefile b/GNUmakefile index 7750632..fe6e28c 100644 --- a/GNUmakefile +++ b/GNUmakefile | |||
@@ -46,6 +46,8 @@ test-compile: | |||
46 | fi | 46 | fi |
47 | go test -c $(TEST) $(TESTARGS) | 47 | go test -c $(TEST) $(TESTARGS) |
48 | 48 | ||
49 | website-githubpages: | ||
50 | bash scripts/launch-website.sh | ||
49 | website: | 51 | website: |
50 | ifeq (,$(wildcard $(GOPATH)/src/$(WEBSITE_REPO))) | 52 | ifeq (,$(wildcard $(GOPATH)/src/$(WEBSITE_REPO))) |
51 | echo "$(WEBSITE_REPO) not found in your GOPATH (necessary for layouts and assets), get-ting..." | 53 | echo "$(WEBSITE_REPO) not found in your GOPATH (necessary for layouts and assets), get-ting..." |
diff --git a/scripts/launch-website.sh b/scripts/launch-website.sh new file mode 100755 index 0000000..f146e75 --- /dev/null +++ b/scripts/launch-website.sh | |||
@@ -0,0 +1,11 @@ | |||
1 | #!/usr/bin/env bash | ||
2 | |||
3 | (sleep 10; | ||
4 | wget --recursive --no-parent --domains localhost --page-requisites --html-extension --convert-links --no-clobber http://localhost:4567/docs/providers/mailgun/; | ||
5 | |||
6 | rm -rf terraform-provider-website; | ||
7 | mv localhost:4567/ terraform-provider-website; | ||
8 | |||
9 | docker stop "$(docker ps -q)") & | ||
10 | |||
11 | make website | ||