-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
35 lines (31 loc) · 965 Bytes
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
language: generic
sudo: true
services:
- docker
env:
HUGO_IMAGE: 'ncatelli/hugo_builder:v0.29'
before_install:
- docker pull $HUGO_IMAGE
- sudo apt-get install -y curl
stages:
- name: 'Build and Deploy'
- name: 'Clear Cache'
if: branch = master
jobs:
include:
- stage: "Build and Deploy"
script: docker run --rm -v $PWD:/work -w /work $HUGO_IMAGE /usr/local/bin/hugo
deploy:
provider: s3
access_key_id: $AWS_ACCESS_KEY_ID
secret_access_key: $AWS_SECRET_KEY
bucket: rootwire-spaces
region: us-east-1
local_dir: public
skip_cleanup: true
acl: public_read
on:
branch: master
- stage: "Clear Cache"
name: "Clear beluga cache."
script: 'curl -kH "Content-type: application/json" -H "Accept: application/json" -d "{\"urls\": [{\"url\": \"http://www.rootwire.spaces/*\"}]}" "$WEBHOOK_URLS" -u "$WEBHOOK_USERNAME:$WEBHOOK_PASSWORD" -s'