Add redis service for github workflow - will it work first try?
This commit is contained in:
parent
24bf3de5f9
commit
f8fd8fe39f
13
.github/workflows/elixir.yml
vendored
13
.github/workflows/elixir.yml
vendored
@ -13,6 +13,8 @@ on:
|
|||||||
env:
|
env:
|
||||||
MIX_ENV: test
|
MIX_ENV: test
|
||||||
NODE_ID: aUniqueString
|
NODE_ID: aUniqueString
|
||||||
|
REDIS_HOST: redis
|
||||||
|
REDIS_PORT: 6379
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
test:
|
test:
|
||||||
@ -20,6 +22,17 @@ jobs:
|
|||||||
# use Postgres. This creates a database for running tests.
|
# use Postgres. This creates a database for running tests.
|
||||||
# Additional services can be defined here if required.
|
# Additional services can be defined here if required.
|
||||||
services:
|
services:
|
||||||
|
# Label used to access the service container
|
||||||
|
redis:
|
||||||
|
# Docker Hub image
|
||||||
|
image: redis
|
||||||
|
# Set health checks to wait until redis has started
|
||||||
|
options: >-
|
||||||
|
--health-cmd "redis-cli ping"
|
||||||
|
--health-interval 10s
|
||||||
|
--health-timeout 5s
|
||||||
|
--health-retries 5
|
||||||
|
|
||||||
db:
|
db:
|
||||||
image: postgres:14
|
image: postgres:14
|
||||||
ports: ['5432:5432']
|
ports: ['5432:5432']
|
||||||
|
Loading…
Reference in New Issue
Block a user