Skip to content

Commit 35a1888

Browse files
authored
Avoid secrets.tar exposure (python#5)
* Avoid to add the credential file * Renew secrets.tar.enc with invalid credentials for testing
1 parent 4c14aaf commit 35a1888

File tree

4 files changed

+7
-3
lines changed

4 files changed

+7
-3
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
secrets.tar

.travis.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,14 @@ env:
1818
before_install:
1919
- export TZ=Asia/Tokyo
2020
- git checkout ${DOCS_BRANCH}
21-
- openssl aes-256-cbc -K $encrypted_9796e8faf501_key -iv $encrypted_9796e8faf501_iv -in secrets.tar.enc -out secrets.tar -d
21+
- openssl aes-256-cbc -K $encrypted_9796e8faf501_key -iv $encrypted_9796e8faf501_iv -in secrets.tar.enc -out ~/secrets.tar -d
2222
- cd ..
2323
- pwd
2424
- ls -la
2525
- BASEDIR="$(pwd)"
2626
- cd ~
27-
- tar xvf "${BASEDIR}"/python-docs-ja/secrets.tar
27+
- tar xvf ~/secrets.tar
28+
- rm ~/secrets.tar
2829
- chmod 600 ~/.ssh/python-docs-ja
2930
- chmod 600 ~/.ssh/cpython-doc-catalog
3031
# Hack from: https://gist.github.com/jamesmcfadden/d379e04e7ae2861414886af189ec59e5
@@ -49,7 +50,9 @@ script:
4950
- cd "${BASEDIR}"/cpython-doc-catalog/Doc/locales
5051
- tx pull --force --language ja
5152
- cd ja/LC_MESSAGES
52-
- git add .
53+
- git add *.po **/*.po
54+
- git status
55+
- exit 1
5356
- if [ $(git status --short | wc -l) -eq 0 ]; then echo "no .po file to upload"; else echo "I have .po file(s) to upload"; git commit --message="[skip ci] Update .po files"; git push --quiet "git@python-docs-ja.github.com:python/python-docs-ja.git" ${DOCS_BRANCH}:${DOCS_BRANCH}; fi
5457
- rm -rf "${BASEDIR}"/cpython-doc-catalog/Doc/locales/ja
5558
# renew-catalog-template

secrets.tar

-7 KB
Binary file not shown.

secrets.tar.enc

0 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)