Skip to content

Update MANIFESTS_REPOSITORY weni-ai #117

Update MANIFESTS_REPOSITORY weni-ai

Update MANIFESTS_REPOSITORY weni-ai #117

Workflow file for this run

name: CI
# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the main branch
push:
branches:
- '**'
pull_request:
branches:
- '**'
env:
DEFAULT_DATABASE: "postgresql://postgres:docker@postgres:5432"
POSTGRES_USER: postgres
POSTGRES_PASSWORD: docker
POSTGRES_HOST: postgres
POSTGRES_PORT: 5432
POSTGRES_ADAPTER: postgresql
jobs:
# Label of the container job
container-job:
# Containers must run in Linux based operating systems
runs-on: ubuntu-latest
# Docker Hub image that `container-job` executes in
container: python:3.8.14-bullseye
# Service containers to run with `container-job`
services:
# Label used to access the service container
postgres:
# Docker Hub image
image: postgres:11
# Provide the password for postgres
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: docker
POSTGRES_HOST: postgres
POSTGRES_PORT: 5432
POSTGRES_ADAPTER: postgresql
# Set health checks to wait until postgres has started
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
# Downloads a copy of the code in your repository before running CI tests
- name: Check out repository code
uses: actions/checkout@v2
- name: Setup Python
run: |
pip install -r requirements.txt
- name: Create database
run: python Chatguy/create_db.py
- name: Run Tests
run: |
python -m pytest -v