2019-12-30 21:32:07 +00:00
|
|
|
trigger:
|
2019-12-30 22:17:37 +00:00
|
|
|
- master
|
2019-12-30 21:32:07 +00:00
|
|
|
- develop
|
|
|
|
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
- job: setup_env
|
|
|
|
displayName: 'Setup Environment'
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
Ubuntu18:
|
|
|
|
AGENT_NAME: 'rmm-ubuntu18'
|
|
|
|
|
|
|
|
pool:
|
|
|
|
name: linux-vms
|
|
|
|
demands:
|
|
|
|
- agent.name -equals $(AGENT_NAME)
|
|
|
|
|
|
|
|
steps:
|
|
|
|
|
|
|
|
- script: |
|
2019-12-30 21:59:45 +00:00
|
|
|
psql -c 'DROP DATABASE IF EXISTS pipeline;' -U postgres
|
|
|
|
psql -c 'CREATE DATABASE pipeline;' -U postgres
|
|
|
|
|
|
|
|
rm -rf /home/steam/myagent/_work/1/s/api/env
|
2019-12-30 21:42:29 +00:00
|
|
|
cd /home/steam/myagent/_work/1/s/api
|
|
|
|
python3.7 -m venv env
|
|
|
|
source env/bin/activate
|
2019-12-30 21:59:45 +00:00
|
|
|
cd /home/steam/myagent/_work/1/s/api/tacticalrmm
|
|
|
|
pip install --upgrade pip
|
2020-01-17 07:15:13 +00:00
|
|
|
pip install -r requirements.txt -r requirements-test.txt
|
2020-04-13 01:23:06 +00:00
|
|
|
displayName: 'Install Dependencies'
|
|
|
|
|
|
|
|
- script: |
|
|
|
|
cd /home/steam/myagent/_work/1/s/api
|
|
|
|
source env/bin/activate
|
|
|
|
cd /home/steam/myagent/_work/1/s/api/tacticalrmm
|
2019-12-30 21:59:45 +00:00
|
|
|
python manage.py test -v 2
|
2020-04-13 01:23:06 +00:00
|
|
|
displayName: 'Run tests'
|