0

I am trying to install Symfony 3.2, I have tried to walk through the instructions here:

http://symfony.com/doc/current/setup.html.

first when running the command:

php.exe symfony new SymfonyProject

I got the error:

cURL error 60: SSL certificate problem: unable to get local issuer certificate

Which has a solution in here:

cURL error 60: SSL certificate: unable to get local issuer certificate

Afterward, I have installed and created a Symfony project successfully, I got an error page while trying to access http://localhost:port/config.php of my apache server.

so I headed to the apache configuration page:

http://symfony.com/doc/current/setup/web_server_configuration.html

and changed the minimum requirement variables to meet my system (off course a restart for the apache service is required):

<VirtualHost *:port>
    ServerName localhost
    ServerAlias localhost

    DocumentRoot "C:\xampp\htdocs\SymfonyProject\web"
    <Directory "C:\xampp\htdocs\SymfonyProject\web">
        AllowOverride All
        Order Allow,Deny
        Allow from All
    </Directory>

    ErrorLog "C:\xampp\apache\logs\project_error.log"
    CustomLog "C:\xampp\apache\logs\project_access.log" combined
</VirtualHost>

I also changed Document root to "C:\xampp\htdocs\SymfonyProject\web" and tried also "C:\xampp\htdocs\SymfonyProject" (just in case) to no avail.

But am still getting an error:

Error from apache running Symfony project

project_access.log and project_error.log are empty.

I tried another page besides http://localhost:port/config.php

in here: http://symfony.com/doc/current/quick_tour/the_big_picture.html

it is being suggested that going to http://localhost:port/app/example is also a valid page, but I still get an error.

your help would be highly appreciated.

Community
  • 1
  • 1
CodePro
  • 161
  • 1
  • 12
  • Add Require local under – Cerad Jan 07 '17 at 22:04
  • Yes, I am using the actual port, though according to my answer when running: php bin/console server:run it defaults to 8000(and not my port) in any case thank you for your suggestion. – CodePro Jan 08 '17 at 07:25

2 Answers2

0

sorry, I have missed a step.

running, php bin/console server:run as described here:

http://symfony.com/doc/current/setup.html

allowed me accessing the config.php file.

CodePro
  • 161
  • 1
  • 12
  • 1
    Just for info, this is the sort of thing you can add to your original question by using the edit button. – Cerad Jan 07 '17 at 22:00
-1

Try this change:

...
NameVirtualHost *:80
...
<VirtualHost *:80>
    ServerName localhost
    ServerAlias localhost

    DocumentRoot "C:\xampp\htdocs\SymfonyProject\web"
    <Directory />
        Options Indexes FollowSymLinks MultiViews
          AllowOverride All
    </Directory>

    ErrorLog "C:\xampp\apache\logs\project_error.log"
    CustomLog "C:\xampp\apache\logs\project_access.log" combined
</VirtualHost>

Make sure that NameVirtualHost is uncommented. Also, why are you trying to access:

http://localhost:port/config.php

I don't think you will be able to access the config.php file. Try instead (for a default route):

http://localhost/

Alvin Bunk
  • 7,621
  • 3
  • 29
  • 45
  • Might want to review your suggested answer because, with all due respect, it's not even close. – Cerad Jan 08 '17 at 02:14
  • @Cerad , this is a cut and paste (roughly) from my actual working apache config. I just double-checked now, and it's the same. Also, I use the default .htaccess generated by Symfony. I'm not sure what you mean by "not even close"? See [my link on it](https://alvinbunk.wordpress.com/2016/11/21/apache-httpd-virtualhost-config/) – Alvin Bunk Jan 08 '17 at 03:45
  • Maybe the key work here is roughly. is not going to do much of anything. You are missing the Require local. And missing the directory path. Details are important. And the stuff about not being able to access config.php almost make it seem like you have not actually installed a Symfony app? – Cerad Jan 08 '17 at 16:21