<commit_before>version: "3.4"
services:
  db:
    image: mariadb
    environment:
      - MYSQL_ALLOW_EMPTY_PASSWORD=yes
      - MYSQL_DATABASE=basket

  redis:
    image: redis

  web:
    build:
      context: .
      args:
        GIT_SHA: ${GIT_COMMIT:-latest}
    image: mozmeao/basket:${GIT_COMMIT:-latest}
    volumes:
      - .:/app
    environment:
      - DATABASE_URL=mysql://root@db/basket
      - DEBUG=True
      - ALLOWED_HOSTS=localhost,127.0.0.1,
      - REDIS_URL=redis://redis:6379
      - CELERY_TASK_ALWAYS_EAGER=False
      - CELERY_LOG_LEVEL=debug
      - DJANGO_LOG_LEVEL=DEBUG
    env_file: .env
    ports:
      - "8000:8000"
    depends_on:
      - db
      - redis
    command:
      ./bin/run-dev.sh

  worker:
    image: mozmeao/basket:${GIT_COMMIT:-latest}
    volumes:
      - .:/app
    environment:
      - DATABASE_URL=mysql://root@db/basket
      - DEBUG=True
      - ALLOWED_HOSTS=localhost,127.0.0.1,
      - REDIS_URL=redis://redis:6379
      - CELERY_TASK_ALWAYS_EAGER=False
      - CELERY_LOG_LEVEL=debug
      - DJANGO_LOG_LEVEL=DEBUG
    env_file: .env
    depends_on:
      - db
      - redis
    command:
      ./bin/run-worker.sh

  donate-worker:
    image: mozmeao/basket:${GIT_COMMIT:-latest}
    volumes:
      - .:/app
    environment:
      - DATABASE_URL=mysql://root@db/basket
      - DEBUG=True
      - ALLOWED_HOSTS=localhost,127.0.0.1,
      - REDIS_URL=redis://redis:6379
      - CELERY_TASK_ALWAYS_EAGER=False
      - CELERY_LOG_LEVEL=debug
      - DJANGO_LOG_LEVEL=DEBUG
    env_file: .env
    depends_on:
      - db
      - redis
    command:
      ./bin/run-donate-worker.sh

  test:
    image: mozmeao/basket:${GIT_COMMIT:-latest}
    volumes:
      - .:/app
    environment:
      - DATABASE_URL=mysql://root@db/basket
      - DEBUG=True
      - ALLOWED_HOSTS=localhost,127.0.0.1,
      - REDIS_URL=redis://redis:6379
      - CELERY_TASK_ALWAYS_EAGER=False
      - CELERY_LOG_LEVEL=debug
      - DJANGO_LOG_LEVEL=DEBUG
    env_file: docker/envfiles/test.env
    depends_on:
      - db
      - redis
    command:
      ./bin/run-tests.sh

  test-image:
    image: mozmeao/basket:${GIT_COMMIT:-latest}
    environment:
      - DATABASE_URL=mysql://root@db/basket
      - DEBUG=True
      - ALLOWED_HOSTS=localhost,127.0.0.1,
      - REDIS_URL=redis://redis:6379
      - CELERY_TASK_ALWAYS_EAGER=False
      - CELERY_LOG_LEVEL=debug
      - DJANGO_LOG_LEVEL=DEBUG
    env_file: docker/envfiles/test.env
    depends_on:
      - db
      - redis
    command:
      ./bin/run-tests.sh

  builder:
    build:
      context: .
      target: builder
    image: mozmeao/basket:builder-${GIT_COMMIT:-latest}
<commit_msg>Set the timeout for urlwait to 30s<commit_after>version: "3.4"
services:
  db:
    image: mariadb
    environment:
      - MYSQL_ALLOW_EMPTY_PASSWORD=yes
      - MYSQL_DATABASE=basket

  redis:
    image: redis

  web:
    build:
      context: .
      args:
        GIT_SHA: ${GIT_COMMIT:-latest}
    image: mozmeao/basket:${GIT_COMMIT:-latest}
    volumes:
      - .:/app
    environment:
      - DATABASE_URL=mysql://root@db/basket
      - DEBUG=True
      - ALLOWED_HOSTS=localhost,127.0.0.1,
      - REDIS_URL=redis://redis:6379
      - CELERY_TASK_ALWAYS_EAGER=False
      - CELERY_LOG_LEVEL=debug
      - DJANGO_LOG_LEVEL=DEBUG
      - URLWAIT_TIMEOUT=30
    env_file: .env
    ports:
      - "8000:8000"
    depends_on:
      - db
      - redis
    command:
      ./bin/run-dev.sh

  worker:
    image: mozmeao/basket:${GIT_COMMIT:-latest}
    volumes:
      - .:/app
    environment:
      - DATABASE_URL=mysql://root@db/basket
      - DEBUG=True
      - ALLOWED_HOSTS=localhost,127.0.0.1,
      - REDIS_URL=redis://redis:6379
      - CELERY_TASK_ALWAYS_EAGER=False
      - CELERY_LOG_LEVEL=debug
      - DJANGO_LOG_LEVEL=DEBUG
      - URLWAIT_TIMEOUT=30
    env_file: .env
    depends_on:
      - db
      - redis
    command:
      ./bin/run-worker.sh

  donate-worker:
    image: mozmeao/basket:${GIT_COMMIT:-latest}
    volumes:
      - .:/app
    environment:
      - DATABASE_URL=mysql://root@db/basket
      - DEBUG=True
      - ALLOWED_HOSTS=localhost,127.0.0.1,
      - REDIS_URL=redis://redis:6379
      - CELERY_TASK_ALWAYS_EAGER=False
      - CELERY_LOG_LEVEL=debug
      - DJANGO_LOG_LEVEL=DEBUG
      - URLWAIT_TIMEOUT=30
    env_file: .env
    depends_on:
      - db
      - redis
    command:
      ./bin/run-donate-worker.sh

  test:
    image: mozmeao/basket:${GIT_COMMIT:-latest}
    volumes:
      - .:/app
    environment:
      - DATABASE_URL=mysql://root@db/basket
      - DEBUG=True
      - ALLOWED_HOSTS=localhost,127.0.0.1,
      - REDIS_URL=redis://redis:6379
      - CELERY_TASK_ALWAYS_EAGER=False
      - CELERY_LOG_LEVEL=debug
      - DJANGO_LOG_LEVEL=DEBUG
      - URLWAIT_TIMEOUT=30
    env_file: docker/envfiles/test.env
    depends_on:
      - db
      - redis
    command:
      ./bin/run-tests.sh

  test-image:
    image: mozmeao/basket:${GIT_COMMIT:-latest}
    environment:
      - DATABASE_URL=mysql://root@db/basket
      - DEBUG=True
      - ALLOWED_HOSTS=localhost,127.0.0.1,
      - REDIS_URL=redis://redis:6379
      - CELERY_TASK_ALWAYS_EAGER=False
      - CELERY_LOG_LEVEL=debug
      - DJANGO_LOG_LEVEL=DEBUG
      - URLWAIT_TIMEOUT=30
    env_file: docker/envfiles/test.env
    depends_on:
      - db
      - redis
    command:
      ./bin/run-tests.sh

  builder:
    build:
      context: .
      target: builder
    image: mozmeao/basket:builder-${GIT_COMMIT:-latest}

{'fraction_non_alphanumeric': 0.11741185023627772, 'fraction_numerical': 0.023991275899672846, 'mean_word_length': 2.060622914349277, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 10, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7085513', 'n_tokens_mistral': 2267, 'n_tokens_neox': 2182, 'n_words': 259}