title: Composer not installing wordpress plugins through dockerfile
body: <p>I am using docker-compose to build a wordpress environment. My plan is to use composer to install plugins and themes I need. When I run docker-compose build everything builds fine and no issues. When I run docker-compose up I see all my containers running, composer included. When I navigate to the wordpress build only the default themes and plugins are installed. My question is why aren't my plugins and themes being installed. What am I missing?</p>
  
  <p>I tried to include files I thought were relevant</p>
  
  <p><strong>fileStructure</strong></p>
  
  <pre><code>/
   config/
     /composer/
        Dockerfile
        composer.json
     /wordpress/Dockerfile
     /database/Dockerfile
     /phpmyadmin/Dockerfile
  
   dist/
     /wp-content/
        /themes/
        /plugins/
        /uploads/
  
  docker-composer.yml
  </code></pre>
  
  <p><strong>composer.json</strong></p>
  
  <pre><code>{
    "repositories":[
      {
          "type":"composer",
          "url":"https://wpackagist.org"
      }
    ],
    "require": {
      "wpackagist-plugin/akismet":"dev-trunk",
      "wpackagist-plugin/wordpress-seo":"&gt;=7.0.2",
      "wpackagist-theme/hueman":"*"
    }
  }
  </code></pre>
  
  <p><strong>Dockerfile Composer</strong></p>
  
  <pre><code>FROM composer/composer:php7
  
  # Install composer
  WORKDIR /var/www/html/wp-content
  
  RUN curl -sS https://getcomposer.org/installer | \
      php -- --install-dir=/usr/bin/ --filename=composer
  
  COPY composer.json /var/www/html/wp-content
  # COPY composer.lock ./
  RUN composer install --no-scripts --no-autoloader
  # COPY ./ /var/www/
  RUN composer dump-autoload --optimize
  </code></pre>
  
  <p><strong>Dockerfile Wodrpess</strong></p>
  
  <pre><code># start with the latest wordpress and php image
  FROM wordpress:5.1.1-php7.3-apache
  
  # Set our environment variables for logging into wordpress
  ENV WORDPRESS_DB_HOST database:3306
  ENV WORDPRESS_DB_USER username
  ENV WORDPRESS_DB_PASSWORD password
  
  # Expose a port to run on
  EXPOSE 80
  </code></pre>
  
  <p><strong>Dockerfile Database</strong></p>
  
  <pre><code># start with the mysql image
  FROM mysql:5.7
  
  # Set our environment varibales for logging into the DB
  ENV MYSQL_ROOT_PASSWORD UKoBMndyEY
  ENV MYSQL_DATABASE wordpress
  ENV MYSQL_USER username
  ENV MYSQL_PASSWORD password
  
  # Copy the database table dependencies into our image DB
  COPY  ./includes /docker-entrypoint-initdb.d
  
  # Expose a port to run on
  EXPOSE 3306:3306
  </code></pre>
  
  <p><strong>docker-compose.yml</strong></p>
  
  <pre><code>version: "3.3"
  services:
    wordpress:
      build:
        context: ./config/docker/wordpress
      volumes:
        - ./dist/wp-content:/var/www/html/wp-content
      ports:
        - "8080:80"
      restart: always
      working_dir: /var/www/html
      depends_on:
        - database
    database:
      build:
        context: ./config/docker/database
      volumes:
        - datab:/var/lib/mysql
      restart: always
    composer:
      build:
        context: ./config/docker/composer
      restart: 'no'
      image: "composer"
      volumes:
        - ./dist/wp-content:/var/www/html/wp-content
    phpmyadmin:
      build:
          context: ./config/docker/phpmyadmin
      ports:
        - 8181:80
      restart: always
      depends_on:
        - database
  volumes:
      datab: {}
  </code></pre>