Skip to content
This repository was archived by the owner on Feb 26, 2025. It is now read-only.

Commit 4047d51

Browse files
luzfcbsergiomario
authored andcommitted
autodeploy via travis-ci (#27)
* autodeploy * melhorias * corrigido branch de deploy e comando de de deploy
1 parent 7729677 commit 4047d51

File tree

2 files changed

+25
-10
lines changed

2 files changed

+25
-10
lines changed

Diff for: .travis.yml

+21-10
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,29 @@
11
sudo: false
2-
branches:
3-
only:
4-
- master
52
language: python
63
before_install:
74
- openssl aes-256-cbc -K $encrypted_efc81948d3a6_key -iv $encrypted_efc81948d3a6_iv -in publish-key.enc -out ~/.ssh/publish-key -d
85
- chmod u=rw,og= ~/.ssh/publish-key
96
- echo "Host github.com" >> ~/.ssh/config
107
- echo " IdentityFile ~/.ssh/publish-key" >> ~/.ssh/config
118
- git remote set-url origin [email protected]:pythonbrasil/pythonbrasil12-site.git
12-
- git fetch origin -f master:master
13-
#install:
14-
#- pip install --upgrade pip
15-
#- pip install -r requirements.txt
16-
#add the rest of setup here
17-
#script:
18-
#- make github
9+
- git fetch origin -f gh-pages:gh-pages
10+
11+
install:
12+
- gem install sass
13+
- cd theme
14+
- npm install -g
15+
- cd ..
16+
- pip install --upgrade pip
17+
- pip install -r requirements.txt
18+
19+
script:
20+
# tenta construir o site, vai falhar caso haja algum erro
21+
- make publish
22+
23+
deploy:
24+
provider: script
25+
script: make github ping
26+
on:
27+
branch: master
28+
condition: $TRAVIS_PULL_REQUEST = false
29+

Diff for: Makefile

+4
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,10 @@ github: publish
8989
ghp-import -m "Generate Pelican site" -b $(GITHUB_PAGES_BRANCH) $(OUTPUTDIR)
9090
git push origin $(GITHUB_PAGES_BRANCH)
9191

92+
ping:
93+
curl -Is http://www.google.com/webmasters/tools/ping?sitemap=http://2016.pythonbrasil.org.br/sitemap.xml | grep "200 OK" || echo "Erro pinging Google"
94+
curl -Is http://www.bing.com/webmaster/ping.aspx?siteMap=http://2016.pythonbrasil.org.br/sitemap.xml | grep "200 OK" || echo "Erro pinging Bing"
95+
9296
ansible-setup:
9397
ansible-playbook ansible/setup.yml -K
9498

0 commit comments

Comments
 (0)