diff --git a/dev.yml b/dev.yml new file mode 100644 index 0000000000000000000000000000000000000000..7be203a49c3b7440201f94c851c7708058f06716 --- /dev/null +++ b/dev.yml @@ -0,0 +1,55 @@ +version: '2' + +services: + postgres: + env_file: .env + image: postgres + volumes: + # If you are using boot2docker, postgres data has to live in the VM for now until #581 is fixed + # for more info see here: https://github.com/boot2docker/boot2docker/issues/581 + - /data/dev/funkwhale_api/postgres:/var/lib/postgresql/data + + redis: + env_file: .env + image: redis:3.0 + + celeryworker: + env_file: .env + build: + context: . + dockerfile: docker/Dockerfile.local + links: + - postgres + - redis + command: python manage.py celery worker + environment: + - C_FORCE_ROOT=true + volumes: + - .:/app + + django: + env_file: .env + build: + context: . + dockerfile: docker/Dockerfile.local + command: python /app/manage.py runserver 0.0.0.0:12081 + volumes: + - .:/app + ports: + - "12081" + environment: + - USE_SAMPLE_TRACK=true + links: + - postgres + - redis + - celeryworker + + nginx: + env_file: .env + build: ./compose/nginx + links: + - django + volumes: + - ./funkwhale_api/media:/staticfiles/media + ports: + - "0.0.0.0:6001:80" diff --git a/docker-compose.yml b/docker-compose.yml deleted file mode 100644 index 1012bdd28880fbf4f12a08e48d24982adb3edd11..0000000000000000000000000000000000000000 --- a/docker-compose.yml +++ /dev/null @@ -1,45 +0,0 @@ -postgres: - image: postgres - volumes: - # If you are using boot2docker, postgres data has to live in the VM for now until #581 is fixed - # for more info see here: https://github.com/boot2docker/boot2docker/issues/581 - - /data/dev/funkwhale_api/postgres:/var/lib/postgresql/data - -redis: - image: redis:3.0 - -celeryworker: - dockerfile: docker/Dockerfile.local - build: . - links: - - postgres - - redis - command: python manage.py celery worker - environment: - - C_FORCE_ROOT=true - volumes: - - .:/app - -django: - dockerfile: docker/Dockerfile.local - build: . - command: python /app/manage.py runserver 0.0.0.0:12081 - volumes: - - .:/app - ports: - - "12081" - environment: - - USE_SAMPLE_TRACK=true - links: - - postgres - - redis - - celeryworker - -nginx: - build: ./compose/nginx - links: - - django - volumes: - - ./funkwhale_api/media:/staticfiles/media - ports: - - "0.0.0.0:6001:80" diff --git a/env.example b/env.example index f0b45bde91a6343b139ae99727a8158ce90f561b..517a507d700a480a91889ea67ec4349f35de33ac 100644 --- a/env.example +++ b/env.example @@ -1,2 +1,3 @@ YOUTUBE_API_KEY= API_AUTHENTICATION_REQUIRED=False +USE_SAMPLE_TRACK=false