Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@ virtualenv-components
virtualenv-components-osx
.venv-st2devbox

# generated travis conf
conf/st2.travis.conf

# Installer logs
pip-log.txt

Expand Down
5 changes: 5 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ env:
# We only run tests with "--with-timer" flag on master and not for PRs since it adds 1-2
# # minutes of overhead to each build.
- NOSE_TIME=$([ "${TRAVIS_PULL_REQUEST}" = "false" ] && [ "${IS_NIGHTLY_BUILD}" = "no" ] && echo "yes" || echo "no")
# Travis-specific st2.conf (with travis user instead of stanley)
- ST2_CONF=conf/st2.travis.conf
matrix:
include:
# NOTE: We combine builds because Travis offers a maximum of 5 concurrent
Expand Down Expand Up @@ -100,6 +102,9 @@ before_install:

install:
- ./scripts/travis/install-requirements.sh
# prep a travis-specific dev conf file that uses travis instead of stanley
- cp conf/st2.dev.conf "${ST2_CONF}" ; sed -i -e "s/stanley/travis/" "${ST2_CONF}"
- sudo scripts/travis/add-itest-user-key.sh
- if [ "${TASK}" = 'ci-unit' ] || [ "${TASK}" = 'ci-integration' ] || [ "${TASK}" = 'ci-checks ci-packs-tests' ] || [ "${TASK}" = 'compilepy3 ci-py3-unit' ] || [ "${TASK}" = 'ci-py3-integration' ]; then sudo .circle/add-itest-user.sh; fi

# Let's enable rabbitmqadmin
Expand Down
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ check-python-packages:
@echo "================== CHECK PYTHON PACKAGES ===================="
@echo ""

test -f $(VIRTUALENV_COMPONENTS_DIR)/bin/activate || virtualenv --python=$(PYTHON_VERSION) --no-site-packages $(VIRTUALENV_COMPONENTS_DIR) --no-download
test -f $(VIRTUALENV_COMPONENTS_DIR)/bin/activate || virtualenv --python=$(PYTHON_VERSION) $(VIRTUALENV_COMPONENTS_DIR) --no-download
@for component in $(COMPONENTS_WITHOUT_ST2TESTS); do \
echo "==========================================================="; \
echo "Checking component:" $$component; \
Expand All @@ -192,7 +192,7 @@ check-python-packages-nightly:
@echo "================== CHECK PYTHON PACKAGES ===================="
@echo ""

test -f $(VIRTUALENV_COMPONENTS_DIR)/bin/activate || virtualenv --python=$(PYTHON_VERSION) --no-site-packages $(VIRTUALENV_COMPONENTS_DIR) --no-download
test -f $(VIRTUALENV_COMPONENTS_DIR)/bin/activate || virtualenv --python=$(PYTHON_VERSION) $(VIRTUALENV_COMPONENTS_DIR) --no-download
@for component in $(COMPONENTS_WITHOUT_ST2TESTS); do \
echo "==========================================================="; \
echo "Checking component:" $$component; \
Expand Down Expand Up @@ -314,7 +314,7 @@ flake8: requirements .flake8
@echo
@echo "==================== st2client install check ===================="
@echo
test -f $(VIRTUALENV_ST2CLIENT_DIR)/bin/activate || virtualenv --python=$(PYTHON_VERSION) --no-site-packages $(VIRTUALENV_ST2CLIENT_DIR) --no-download
test -f $(VIRTUALENV_ST2CLIENT_DIR)/bin/activate || virtualenv --python=$(PYTHON_VERSION) $(VIRTUALENV_ST2CLIENT_DIR) --no-download

# Setup PYTHONPATH in bash activate script...
# Delete existing entries (if any)
Expand Down Expand Up @@ -506,7 +506,7 @@ virtualenv:
@echo
# Note: We pass --no-download flag to make sure version of pip which we install (9.0.1) is used
# instead of latest version being downloaded from PyPi
test -f $(VIRTUALENV_DIR)/bin/activate || virtualenv --python=$(PYTHON_VERSION) --no-site-packages $(VIRTUALENV_DIR) --no-download
test -f $(VIRTUALENV_DIR)/bin/activate || virtualenv --python=$(PYTHON_VERSION) $(VIRTUALENV_DIR) --no-download

# Setup PYTHONPATH in bash activate script...
# Delete existing entries (if any)
Expand Down
4 changes: 2 additions & 2 deletions fixed-requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ oslo.config>=1.12.1,<1.13
oslo.utils>=3.36.2,<=3.37.0
six==1.13.0
pyyaml==5.1.2
requests[security]==2.22.0
requests[security]==2.23.0
apscheduler==3.6.3
gitpython==2.1.11
gitpython==2.1.15
jsonschema==2.6.0
pymongo==3.10.0
mongoengine==0.18.2
Expand Down
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ git+https://github.com/StackStorm/logshipper.git@stackstorm_patched#egg=logshipp
git+https://github.com/StackStorm/orquesta.git@6e2fa8052cd62b07e96e540f68e7290b324d0f01#egg=orquesta
git+https://github.com/StackStorm/python-mistralclient.git#egg=python-mistralclient
git+https://github.com/StackStorm/st2-auth-backend-flat-file.git@master#egg=st2-auth-backend-flat-file
gitpython==2.1.11
gitpython==2.1.15
greenlet==0.4.15
gunicorn==19.9.0
ipaddr
Expand Down Expand Up @@ -52,7 +52,7 @@ pytz==2019.1
pywinrm==0.3.0
pyyaml==5.1.2
rednose
requests[security]==2.22.0
requests[security]==2.23.0
retrying==1.3.3
routes==2.4.1
semver==2.9.0
Expand Down
18 changes: 18 additions & 0 deletions scripts/travis/add-itest-user-key.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/usr/bin/env bash

set -e

if [ "$(whoami)" != 'root' ]; then
echo 'Please run with sudo'
exit 2
fi

mkdir -p /home/travis/.ssh

# Generate ssh keys on StackStorm box and copy over public key into remote box.
ssh-keygen -f /home/travis/.ssh/travis_rsa -P ""

# Authorize key-base acces
sh -c 'cat /home/travis/.ssh/travis_rsa.pub >> /home/travis/.ssh/authorized_keys'
chmod 0600 /home/travis/.ssh/authorized_keys
chmod 0700 /home/travis/.ssh
13 changes: 3 additions & 10 deletions scripts/travis/prepare-integration.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ if [ "$(whoami)" != 'root' ]; then
exit 2
fi

UBUNTU_VERSION=`lsb_release -a 2>&1 | grep Codename | grep -v "LSB" | awk '{print $2}'`

# Activate the virtualenv created during make requirements phase
source ./virtualenv/bin/activate

Expand Down Expand Up @@ -35,11 +33,6 @@ echo " === END: Catting screen process log files. ==="
chmod 777 logs/
chmod 777 logs/*

# Workaround for Travis on Ubuntu Xenial so local runner integration tests work
# when executing them under user "stanley" (by default Travis checks out the
# code and runs tests under a different system user).
# NOTE: We need to pass "--exe" flag to nosetests when using this workaround.
if [ "${UBUNTU_VERSION}" == "xenial" ]; then
echo "Applying workaround for stanley user permissions issue to /home/travis on Xenial"
chmod 777 -R /home/travis
fi
# root needs to access write some lock files when creating virtualenvs
# o=other; X=only set execute bit if user execute bit is set (eg on dirs)
chmod -R o+rwX ${HOME}/.local/share/virtualenv
2 changes: 1 addition & 1 deletion scripts/travis/setup-mistral.sh
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ setup_mistral() {

# Setup virtualenv for running mistral.
cd /opt/openstack/mistral
virtualenv --no-site-packages .venv
virtualenv .venv
. /opt/openstack/mistral/.venv/bin/activate
pip install -q -r requirements.txt
pip install -q psycopg2
Expand Down
4 changes: 2 additions & 2 deletions st2actions/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ apscheduler==3.6.3
eventlet==0.25.1
git+https://github.com/StackStorm/logshipper.git@stackstorm_patched#egg=logshipper
git+https://github.com/StackStorm/python-mistralclient.git#egg=python-mistralclient
gitpython==2.1.11
gitpython==2.1.15
jinja2==2.10.3
kombu==4.6.6
lockfile==0.12.2
Expand All @@ -19,5 +19,5 @@ pyinotify==0.9.6
python-dateutil==2.8.0
python-json-logger
pyyaml==5.1.2
requests[security]==2.22.0
requests[security]==2.23.0
six==1.13.0
2 changes: 1 addition & 1 deletion st2client/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ python-dateutil==2.8.0
python-editor==1.0.4
pytz==2019.1
pyyaml==5.1.2
requests[security]==2.22.0
requests[security]==2.23.0
six==1.13.0
sseclient-py==1.7
zipp<=1.0.0,>=0.5
4 changes: 2 additions & 2 deletions st2common/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ cryptography==2.8
eventlet==0.25.1
flex==6.14.0
git+https://github.com/StackStorm/orquesta.git@6e2fa8052cd62b07e96e540f68e7290b324d0f01#egg=orquesta
gitpython==2.1.11
gitpython==2.1.15
greenlet==0.4.15
ipaddr
jinja2==2.10.3
Expand All @@ -27,7 +27,7 @@ pymongo==3.10.0
python-dateutil==2.8.0
python-statsd==2.1.0
pyyaml==5.1.2
requests[security]==2.22.0
requests[security]==2.23.0
retrying==1.3.3
routes==2.4.1
semver==2.9.0
Expand Down
2 changes: 1 addition & 1 deletion st2debug/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@
eventlet==0.25.1
python-gnupg==0.4.5
pyyaml==5.1.2
requests[security]==2.22.0
requests[security]==2.23.0
six==1.13.0