Continuous Drupal questions

Hello,

The post https://circleci.com/blog/continuous-drupal-p1-maintaining-with-docker-git-composer/ is the best I have found about drupal, drush and composer.

My question is how we can add php myadmin to this and if there is a caching problem with mac since if I make a change to simple php file with one line echo it only appears by running docker-compose up again.

Here is my docker-compose.yml

version: '3'
services:
  db:
    image: mariadb:10.2
    container_name: "${PROJECT_NAME}_db"
    environment:
      MYSQL_ROOT_PASSWORD: $DB_ROOT_PASSWORD
      MYSQL_DATABASE: $DB_NAME
      MYSQL_USER: $DB_USER
      MYSQL_PASSWORD: $DB_PASSWORD
    volumes:
      - db_data:/var/lib/mysql
    restart: always
  drupal:
    container_name: "${PROJECT_NAME}_app"
    depends_on:
      - db
    build: .
    volumes:
      - ./app:/app
    restart: always
    labels:
      - 'traefik.backend=drupal'
      - 'traefik.port=80'
      - 'traefik.frontend.rule=Host:${PROJECT_BASE_URL}'
  pma:
    image: phpmyadmin/phpmyadmin
    container_name: "${PROJECT_NAME}_pma"
    environment:
      PMA_USER: $DB_USER
      PMA_PASSWORD: $DB_PASSWORD
      PHP_UPLOAD_MAX_FILESIZE: 1G
      PHP_MAX_INPUT_VARS: 1G
    labels:
      - 'traefik.backend=pma'
      - 'traefik.port=80'
      - 'traefik.frontend.rule=Host:pma.${PROJECT_BASE_URL}'
  traefik:
    image: traefik
    container_name: "${PROJECT_NAME}_traefik"
    command: -c /dev/null --web --docker --logLevel=INFO
    ports:
      - '${PROJECT_PORT}:80'
    volumes:
      - /var/run/docker.sock:/var/run/docker.sock
volumes:
  db_data:

Don’t mind the variables they are added from an .env file. I can’t connect to php myadmin. Thank you again.

I found it. It had to someting with docker caching. If you don’t remove the folder and recreate it, username and password changes can’t happen according here https://github.com/docker-library/mysql/issues/51

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.