mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-02-03 05:04:25 +03:00
Add necessary services for GH actions without Docker
This commit is contained in:
parent
9793511266
commit
c1ec7e3cd1
|
@ -37,6 +37,30 @@ jobs:
|
|||
# With no caching at all the entire ci process takes 4m 30s to complete!
|
||||
pytest:
|
||||
runs-on: ubuntu-latest
|
||||
{%- if cookiecutter.use_docker == 'n' %}
|
||||
|
||||
services:
|
||||
{%- if cookiecutter.use_celery == 'y' %}
|
||||
redis:
|
||||
image: redis:5.0
|
||||
ports:
|
||||
- 6379:6379
|
||||
{%- endif %}
|
||||
postgres:
|
||||
image: postgres:12
|
||||
ports:
|
||||
- 5432:5432
|
||||
env:
|
||||
POSTGRES_PASSWORD: postgres
|
||||
|
||||
env:
|
||||
{%- if cookiecutter.use_celery == 'y' %}
|
||||
CELERY_BROKER_URL: "redis://localhost:6379/0"
|
||||
{%- endif %}
|
||||
# postgres://user:password@host:port/database
|
||||
DATABASE_URL: "postgres://postgres:postgres@localhost:5432/postgres"
|
||||
{%- endif %}
|
||||
|
||||
steps:
|
||||
|
||||
- name: Checkout Code Repository
|
||||
|
|
Loading…
Reference in New Issue
Block a user