Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to run symfony via docker-composer

I git cloned this repository: docker-symfony and followed the installation instructions.

When I visited symfony.dev:81, I saw kibana 4.

My problem is, I don't understand where I should put the Symfony project.

My OS is Ubuntu 14.04

like image 900
Rider_BY Avatar asked Oct 30 '22 12:10

Rider_BY


1 Answers

The instructions mention:

put your Symfony application into symfony folder and do not forget to add symfony.dev in your /etc/hosts file.

Then, run:

$ docker-compose up

You are done, you can visite your Symfony application on the following URL: http://symfony.dev (and access Kibana on http://symfony.dev:81)

That "symfony folder" comes from docker-compose.yml#L4

volumes:
    - ./symfony:/var/www/symfony

It means you should create a symfony folder in your docker-symfony cloned repo, which will be mounted as /var/www/symfony in the application container.

docker-symfony
  code
  elk/logstash
  nginx
  php-fpm
  .gitignore
  .travis.yml
  README.md
  symfony   <====== Add your folder there

That folder can be a symbolic link to wherever you have your symfony project.

like image 184
VonC Avatar answered Nov 02 '22 02:11

VonC