refactor envs

This commit is contained in:
Matthias 2021-12-02 13:10:40 +01:00
parent b8a76429d1
commit a9aa55d76f
No known key found for this signature in database
GPG Key ID: F50EF5741D33E076
2 changed files with 23 additions and 21 deletions

View File

@ -8,6 +8,15 @@ on:
types:
- completed
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
INVENTREE_DB_NAME: './test_db.sqlite'
INVENTREE_DB_ENGINE: django.db.backends.sqlite3
INVENTREE_DEBUG: info
INVENTREE_MEDIA_ROOT: ./media
INVENTREE_STATIC_ROOT: ./static
jobs:
# Run tests on SQLite database
@ -16,14 +25,6 @@ jobs:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
INVENTREE_DB_NAME: './test_db.sqlite'
INVENTREE_DB_ENGINE: django.db.backends.sqlite3
INVENTREE_DEBUG: info
INVENTREE_MEDIA_ROOT: ./media
INVENTREE_STATIC_ROOT: ./static
steps:
- name: Checkout Code
uses: actions/checkout@v2

View File

@ -8,13 +8,7 @@ on:
types:
- completed
jobs:
test:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
env:
env:
# Database backend configuration
INVENTREE_DB_ENGINE: django.db.backends.postgresql
INVENTREE_DB_NAME: inventree
@ -27,6 +21,13 @@ jobs:
INVENTREE_STATIC_ROOT: ./static
INVENTREE_CACHE_HOST: localhost
jobs:
test:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
services:
postgres:
image: postgres