Quellcode durchsuchen

Add encrypted credentials for Travis

Enis Afgan vor 7 Jahren
Ursprung
Commit
9e59c4750b
3 geänderte Dateien mit 82 neuen und 80 gelöschten Zeilen
  1. 2 0
      .gitignore
  2. 80 80
      .travis.yml
  3. BIN
      credentials.tar.gz.enc

+ 2 - 0
.gitignore

@@ -58,3 +58,5 @@ target/
 
 
 *.DS_Store
 *.DS_Store
 /venv/
 /venv/
+
+credentials.tar.gz

+ 80 - 80
.travis.yml

@@ -2,92 +2,92 @@ dist: trusty
 language: python
 language: python
 cache:
 cache:
   directories:
   directories:
-    - $HOME/.cache/pip
-    - $TRAVIS_BUILD_DIR/.tox
+  - "$HOME/.cache/pip"
+  - "$TRAVIS_BUILD_DIR/.tox"
 os:
 os:
-  - linux
-#  - osx
+- linux
 matrix:
 matrix:
   fast_finish: true
   fast_finish: true
   allow_failures:
   allow_failures:
-    - os: osx
+  - os: osx
   include:
   include:
-    - python: 2.7
-      env: TOX_ENV=py27-aws
-    - python: 2.7
-      env: TOX_ENV=py27-azure
-    - python: 2.7
-      env: TOX_ENV=py27-gce
-    - python: 2.7
-      env: TOX_ENV=py27-openstack
-    - python: 3.6
-      env: TOX_ENV=py36-aws
-    - python: 3.6
-      env: TOX_ENV=py36-azure
-    - python: 3.6
-      env: TOX_ENV=py36-gce
-    - python: 3.6
-      env: TOX_ENV=py36-openstack
-    - python: pypy-5.3.1
-      env: TOX_ENV=pypy-aws
-    - python: pypy-5.3.1
-      env: TOX_ENV=pypy-azure
-    - python: pypy-5.3.1
-      env: TOX_ENV=pypy-gce
-    - python: pypy-5.3.1
-      env: TOX_ENV=pypy-openstack
+  - python: 2.7
+    env: TOX_ENV=py27-aws
+  - python: 2.7
+    env: TOX_ENV=py27-azure
+  - python: 2.7
+    env: TOX_ENV=py27-gce
+  - python: 2.7
+    env: TOX_ENV=py27-openstack
+  - python: 3.6
+    env: TOX_ENV=py36-aws
+  - python: 3.6
+    env: TOX_ENV=py36-azure
+  - python: 3.6
+    env: TOX_ENV=py36-gce
+  - python: 3.6
+    env: TOX_ENV=py36-openstack
+  - python: pypy-5.3.1
+    env: TOX_ENV=pypy-aws
+  - python: pypy-5.3.1
+    env: TOX_ENV=pypy-azure
+  - python: pypy-5.3.1
+    env: TOX_ENV=pypy-gce
+  - python: pypy-5.3.1
+    env: TOX_ENV=pypy-openstack
 before_install:
 before_install:
-    - |
-      case "$TRAVIS_EVENT_TYPE" in
-        push|pull_request)
-           # Check whether we need to run a test for this provider
-           DOCS_REGEX='(\.rst$)|(^(docs))/'
-           FILES_IN_CHANGESET="`git diff --name-only $TRAVIS_COMMIT_RANGE`"
-           echo "$FILES_IN_CHANGESET" | grep -qvE "$DOCS_REGEX" || {
-              echo "Only docs were updated. Stopping build process."
-              exit
-           }
-           echo "$FILES_IN_CHANGESET" | grep -qvE "$DOCS_REGEX|(^(cloudbridge/cloud/providers))" || {
-              echo "Only docs and providers were updated. Checking whether this provider was changed."
-              # Extract env and provider from $TOXENV into $PYENV and $PROVIDER respectively
-              IFS=- read PYENV PROVIDER <<< "$TOX_ENV"
-              echo "$FILES_IN_CHANGESET" | grep -qE "^(cloudbridge/cloud/providers/$PROVIDER)" && {
-                 echo "This provider was affected by this changeset. Running tests."
-              } || {
-                 echo "This provider was not affected by this changeset. Stopping build process."
-                 exit
-              }
-           }
-           ;;
-        *)
-           echo "Build triggered through API or CRON job. Running regardless of changes"
-           ;;
-      esac
+- openssl aes-256-cbc -K $encrypted_b3fcf6d0737c_key -iv $encrypted_b3fcf6d0737c_iv
+  -in credentials.tar.gz.enc -out credentials.tar.gz -d
+- |
+  case "$TRAVIS_EVENT_TYPE" in
+    push|pull_request)
+       # Check whether we need to run a test for this provider
+       DOCS_REGEX='(\.rst$)|(^(docs))/'
+       FILES_IN_CHANGESET="`git diff --name-only $TRAVIS_COMMIT_RANGE`"
+       echo "$FILES_IN_CHANGESET" | grep -qvE "$DOCS_REGEX" || {
+          echo "Only docs were updated. Stopping build process."
+          exit
+       }
+       echo "$FILES_IN_CHANGESET" | grep -qvE "$DOCS_REGEX|(^(cloudbridge/cloud/providers))" || {
+          echo "Only docs and providers were updated. Checking whether this provider was changed."
+          # Extract env and provider from $TOXENV into $PYENV and $PROVIDER respectively
+          IFS=- read PYENV PROVIDER <<< "$TOX_ENV"
+          echo "$FILES_IN_CHANGESET" | grep -qE "^(cloudbridge/cloud/providers/$PROVIDER)" && {
+             echo "This provider was affected by this changeset. Running tests."
+          } || {
+             echo "This provider was not affected by this changeset. Stopping build process."
+             exit
+          }
+       }
+       ;;
+    *)
+       echo "Build triggered through API or CRON job. Running regardless of changes"
+       ;;
+  esac
 install:
 install:
-    - pip install -U setuptools
-    - pip install tox
-    - pip install coveralls
-    - pip install codecov
+- pip install -U setuptools
+- pip install tox
+- pip install coveralls
+- pip install codecov
 script:
 script:
-    - tox -e $TOX_ENV
+- tox -e $TOX_ENV
 after_script:
 after_script:
-    - |
-      case "$TRAVIS_EVENT_TYPE" in
-        push|pull_request)
-           # Don't run coverage if tests or cloudbridge interface was not affected
-           DOCS_REGEX='(\.rst$)|(^(docs))/'
-           FILES_IN_CHANGESET="`git diff --name-only $TRAVIS_COMMIT_RANGE`"
-           echo "$FILES_IN_CHANGESET" | grep -qvE "$DOCS_REGEX|(^(cloudbridge/cloud/providers))" && {
-              coveralls &
-              codecov &
-              wait
-           } || {
-              echo "Only docs and providers were updated. Not running coverage."
-           }
-           ;;
-        *)
-           echo "Build triggered through API or CRON job. Running regardless of changes"
-           coveralls & codecov & wait
-           ;;
-      esac
-
+- |
+  case "$TRAVIS_EVENT_TYPE" in
+    push|pull_request)
+       # Don't run coverage if tests or cloudbridge interface was not affected
+       DOCS_REGEX='(\.rst$)|(^(docs))/'
+       FILES_IN_CHANGESET="`git diff --name-only $TRAVIS_COMMIT_RANGE`"
+       echo "$FILES_IN_CHANGESET" | grep -qvE "$DOCS_REGEX|(^(cloudbridge/cloud/providers))" && {
+          coveralls &
+          codecov &
+          wait
+       } || {
+          echo "Only docs and providers were updated. Not running coverage."
+       }
+       ;;
+    *)
+       echo "Build triggered through API or CRON job. Running regardless of changes"
+       coveralls & codecov & wait
+       ;;
+  esac

BIN
credentials.tar.gz.enc