diff --git a/.travis.yml b/.travis.yml index c2bc717..ea656ce 100644 --- a/.travis.yml +++ b/.travis.yml @@ -14,8 +14,11 @@ install: script: - mypy --ignore-missing-imports . - flake8 activitypub.py - - cp -r tests/me.yml config/me.yml + - cp -r tests/fixtures/me.yml config/me.yml - docker-compose up -d - docker-compose ps - - sleep 2 + - WEB_PORT=5006 DATA_DIR=./tests/fixtures/instance1/data CONFIG_DIR=./tests/fixtures/instance1/config docker-compose -p instance1 up + - docker-compose -p instance1 ps + - WEB_PORT=5007 DATA_DIR=./tests/fixtures/instance2/data CONFIG_DIR=./tests/fixtures/instance2/config docker-compose -p instance2 up + - docker-compose -p instance2 ps - pytest -v --ignore data diff --git a/Dockerfile b/Dockerfile index 3fed815..ae59305 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,4 +3,4 @@ ADD . /app WORKDIR /app RUN pip install -r requirements.txt ENV FLASK_APP=app.py -CMD ["gunicorn", "-w", "4", "-b", "0.0.0.0:5005", "app:app"] +CMD ["gunicorn", "-w", "2", "-b", "0.0.0.0:5005", "app:app"] diff --git a/tests/fixtures/instance1/config/.gitignore b/tests/fixtures/instance1/config/.gitignore new file mode 100644 index 0000000..d6b7ef3 --- /dev/null +++ b/tests/fixtures/instance1/config/.gitignore @@ -0,0 +1,2 @@ +* +!.gitignore diff --git a/tests/fixtures/instance1/data/.gitignore b/tests/fixtures/instance1/data/.gitignore new file mode 100644 index 0000000..d6b7ef3 --- /dev/null +++ b/tests/fixtures/instance1/data/.gitignore @@ -0,0 +1,2 @@ +* +!.gitignore diff --git a/tests/fixtures/instance2/config/.gitignore b/tests/fixtures/instance2/config/.gitignore new file mode 100644 index 0000000..d6b7ef3 --- /dev/null +++ b/tests/fixtures/instance2/config/.gitignore @@ -0,0 +1,2 @@ +* +!.gitignore diff --git a/tests/fixtures/instance2/data/.gitignore b/tests/fixtures/instance2/data/.gitignore new file mode 100644 index 0000000..d6b7ef3 --- /dev/null +++ b/tests/fixtures/instance2/data/.gitignore @@ -0,0 +1,2 @@ +* +!.gitignore diff --git a/tests/me.yml b/tests/fixtures/me.yml similarity index 100% rename from tests/me.yml rename to tests/fixtures/me.yml