Welcome Guest, Not a member yet? Register   Sign In
Solved: Server Installation Trouble
#11

[eluser]ywftdg[/eluser]
That worked fine for say app path, but for system path it makes a wonky path

$system_folder = dirname(__FILE__)."../../system";

when I echo that, it comes back '/var/www/vhosts/domain.com/httpdocs/thedesigners../../system'

This all works locally (of course) but for system locally I just use "../../system". So when on server this didn't work, i started using full path, no go still.
#12

[eluser]gon[/eluser]
Then put a slash:

$system_folder = dirname(__FILE__)."/../../system";
#13

[eluser]ywftdg[/eluser]
Same thing: http://www.youworkforthem.com/thedesigners/index.php
My application is in that dir, but in /designers folder. Either way, you can see CI just isn't loading. I put an echo on the sstem path on index.php so you can see what its reading that code as.
#14

[eluser]ywftdg[/eluser]
I will have to say, the past two weeks with CI have ben a real hell, and for sure tested my patience with this framework, and the concept of frameworks in general. I think if I can get over this hump, the reward will be good, atleast i'm trying to tell myself that as i'm yelling at my server and computers.

So heres something for your pipe, or anyone out there who might be able to lay light on this. So my server, it wont allow me to put the system folder outside of httpdocs. I have tried it all, i made sure it was defined in he vhost.conf and rebuilt the include file on server, and the paths all show up for open base dir. Still no work. I have now said f it, I will move the system folder into httpdocs and pw protect the folder. BUT when I try to put my application index.php file into a folder, doesn't work again. It only works if the index.php (application file with system path and such) is in the main httpdocs folder, or application is in the system folder. For example, I have this structure now:

httpdocs
->system
->thedesigners
->->index.php
->->designers (application folder)


also, a CI file that does work, only if in root of httpdocs
httpdocs
->system
->ci_test.php


You can see, this page works:
http://www.youworkforthem.com/ci_test.php
Code:
$system_folder = "system";
$application_folder = "application";

This page does NOT work
http://www.youworkforthem.com/thedesigners/index.php
Code:
$system_folder = "/var/www/vhosts/youworkforthem.com/httpdocs/system";
$application_folder = "/var/www/vhosts/youworkforthem.com/httpdocs/thedesigners/designers";

If there is anyone out there with any info on this, I would be of greatttt help, at this point i'm about to just ditch CI, as its basically sucking more time than saving anything.
#15

[eluser]awpti[/eluser]
You're running PLESK. I can tell by the directory structure and the open_basedir error.

Here's your fix;

vim /var/www/vhosts/youworkforthem.com/conf/vhost.conf

In vhost.conf:

<Directory /var/www/vhosts/youworkforthem.com/httpdocs>
php_admin_value open_basedir none
</Directory>
<DirectoryMatch /var/www/vhosts/youworkforthem.com/subdomains/(.*)/httpdocs>
php_admin_value open_basedir none
</DirectoryMatch>

Write/quit.

/usr/local/psa/admin/sbin/websrvmng -v -a

That should fix it.

If you want to kill open_basedir on the entire server:

vim /etc/httpd/conf.d/zzz_remove_openbasedir.conf

<DirectoryMatch /var/www/vhosts/(.*)/httpdocs>
php_admin_value open_basedir none
</DirectoryMatch>
<DirectoryMatch /var/www/vhosts/(.*)/subdomains/(.*)/httpdocs>
php_admin_value open_basedir none
</DirectoryMatch>

.. and restart apache.
#16

[eluser]awpti[/eluser]
As a side note:

I run a base codeigniter setup in /usr/share/codeigniter

People just stick their CI index.php and application directory wherever they want. They just have to edit the index.php Smile
#17

[eluser]ywftdg[/eluser]
Yes, but for some reason, this doesn't work for me. In the past CI was quite flexible on more shared hosting like plans, works great locally in MAMP too. But now on my dedicated server (I have a few sites on here) CI just doesn't want to play nice with my server.
#18

[eluser]awpti[/eluser]
It's something with your configuration.

I just moved the application directory out of the docroot for ignitedjobs and it still works.
#19

[eluser]ywftdg[/eluser]
I for sure have everything set right as far as paths and server stuff. Basically, what we have here is some no smooth way to get this on this dedicated server running plesk. CI only runs if its in the httpdocs area. But there does seem to be some issue with my application, I am eve trying to get it running on a subdomain now. If I use the default folder that comes with CI, application, that runs. But my app will not even run a basic test page. Something strange going on here, and no bugs or logs are showing up, so hard as hell to see what's going on here...
#20

[eluser]ywftdg[/eluser]
Solved -> Sigh....this was all because the system/logs folder was not writable. Hopefully my days of trouble and posts on here will help a poor soul in the future should you have they have instal issues.




Theme © iAndrew 2016 - Forum software by © MyBB