🐳 Adds a sample on how to run netbox tests
This commit is contained in:
parent
d58930ab67
commit
f9d60692f4
@ -51,3 +51,11 @@ You can configure the app at runtime using variables (see `docker-compose.yml`).
|
||||
* SHORT_TIME_FORMAT
|
||||
* DATETIME_FORMAT
|
||||
* SHORT_DATETIME_FORMAT
|
||||
|
||||
## Tests
|
||||
|
||||
To run the bundled test, use the `docker-compose.test.yml` file.
|
||||
|
||||
```
|
||||
# docker-compose -f docker-compose.test.yml run --rm app
|
||||
```
|
||||
|
25
docker-compose.test.yml
Normal file
25
docker-compose.test.yml
Normal file
@ -0,0 +1,25 @@
|
||||
version: '3'
|
||||
services:
|
||||
app:
|
||||
build:
|
||||
context: .
|
||||
args:
|
||||
- BRANCH=${BRANCH-master}
|
||||
image: ninech/netbox:${BRANCH-latest}
|
||||
depends_on:
|
||||
- postgres
|
||||
env_file: netbox.env
|
||||
command:
|
||||
- ./manage.py
|
||||
- test
|
||||
postgres:
|
||||
image: postgres:9.6-alpine
|
||||
environment:
|
||||
POSTGRES_USER: netbox
|
||||
POSTGRES_PASSWORD: J5brHrAXFLQSif0K
|
||||
POSTGRES_DB: netbox
|
||||
volumes:
|
||||
netbox-static-files:
|
||||
driver: local
|
||||
netbox-nginx-config:
|
||||
driver: local
|
Loading…
Reference in New Issue
Block a user