-
Notifications
You must be signed in to change notification settings - Fork 0
78 lines (63 loc) · 2.04 KB
/
nodejs.yml
File metadata and controls
78 lines (63 loc) · 2.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
name: Install and test
on: [push]
jobs:
build:
runs-on: ubuntu-latest
env:
ADMINAPI_CLIENTSECRET: dasgasesdave
DB_PASS: 4tskngvknldkf
DB_HOST: localhost
DB_USER: postgres
DB_NAME: postgres
DB_PORT: 5432
WSB_HOST: localhost
WSB_PORT: 5000
TAGTOKEN_CLIENTSECRET: lknaslenfaklefnlk
HASHIDS_SALT: salfkna04afksnl
CSRF_SESSION_KEY: elkafnleknf
SECRET_KEY: feanlksenlkas
DROP_ON_INIT: True
strategy:
matrix:
node-version: [12.x]
steps:
- uses: actions/checkout@v2
- name: Install postgres
uses: harmon758/postgresql-action@v1
with:
postgresql version: '11' # See https://hub.docker.com/_/postgres for available versions
postgresql db: ${{ env.DB_HOST }}
postgresql user: ${{ env.DB_USER }}
postgresql password: ${{ env.DB_PASS }}
- name: Set up Python
uses: actions/setup-python@v1
with:
python-version: '3.8'
- name: Install dependencies
run: sudo apt-get install python3-setuptools
- run: sudo apt-get install build-essential
- run: sudo apt-get install python3-dev
- run: sudo apt-get install libpq-dev
- name: Install Python 3 dependencies
uses: actions/cache@v1
with:
path: ~/.cache/pip # This path is specific to Ubuntu
# Look to see if there is a cache hit for the corresponding requirements file
key: ${{ runner.os }}-pip-${{ hashFiles('requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
${{ runner.os }}-
- name: Install dependencies
run: |
pip install psycopg2==2.8.6
pip install -r requirements.txt
pip install uwsgi
- name: Run uwsgi server and daemonize
run: uwsgi --protocol http --daemonize /tmp/uwsgi_daemonize.log -w -d --ini uwsgi.ini
- name: Start tests
run: PYTHONPATH=$PYTHONPATH:tests py.test tests/
env:
CI: true
- name: Output uWSGI log file
if: failure()
run: cat /tmp/uwsgi_daemonize.log