title: How do I install composer in container of docker?
body: <p>I am new at docker and docker-compose and I am developing a Laravel-project on docker and docker-compose with Laradock as following a tutorial(not sure whether It is a correct way or not to refer this situation though).</p>
  
  <p>I want to install the <code>composer</code> in this environment to be able to use the  <code>composer</code> command.</p>
  
  <p>As a matter of fact, I wanted to do seeding to put data into DB that I made by <code>php artisan make:migrate</code> but this error appeared.</p>
  
  <pre><code>include(/var/www/laravel_practice/vendor/composer/../../database/seeds/AdminsTableSeeder.php): failed to open stream: No such file or directory
  </code></pre>
  
  <p>So I googled this script to find a solution that will solve the error then I found it.
  It says, "Do <code>composer dump-autoload</code> and try seeding again", so I followed it then this error appeared.</p>
  
  <pre><code>bash: composer: command not found
  </code></pre>
  
  <p>Because I have not installed composer into docker-container.
  My docker's condition is like this now.
  ・workspace<br>
  ・mysql<br>
  ・apache<br>
  ・php-fpm<br>
  Since I have not installed the <code>composer</code>, I have to install it into docker-container to solve the problem, BUT I have no idea how to install it into docker-container.</p>
  
  <p>So could anyone tell me how to install <code>composer</code> into docker-container?
  Thank you.</p>
  
  <p>here is the <code>laradock/mysql/Dockerfile</code> and <code>laravelProject/docker-compose.yml</code>.</p>
  
  <pre><code>ARG MYSQL_VERSION=5.7
  FROM mysql:${MYSQL_VERSION}
  
  LABEL maintainer="Mahmoud Zalt &lt;mahmoud@zalt.me&gt;"
  
  #####################################
  # Set Timezone
  #####################################
  
  ARG TZ=UTC
  ENV TZ ${TZ}
  RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime &amp;&amp; echo $TZ &gt; /etc/timezone &amp;&amp; chown -R mysql:root /var/lib/mysql/
  
  COPY my.cnf /etc/mysql/conf.d/my.cnf
  
  CMD ["mysqld"]
  
  EXPOSE 3306
  </code></pre>
  
  <pre><code>version: '2'
  services:
    db:
      image: mysql:5.7
      ports:
        - "6603:3306"
      environment:
        - MYSQL_ALLOW_EMPTY_PASSWORD=true
        - MYSQL_DATABASE=laravelProject
        - LANG=C.UTF-8
      volumes:
        - db:/var/lib/mysql
      command: mysqld --sql-mode=NO_ENGINE_SUBSTITUTION --character-set-server=utf8 --collation-server=utf8_unicode_ci
  
    web:
      image: arbiedev/php-nginx:7.1.8
      ports:
        - "8080:80"
      volumes:
        - ./www:/var/www
        - ./nginx.conf:/etc/nginx/sites-enabled/default
  
  volumes:
    db:
  
  </code></pre>