WebFaction
Community site: login faq

How can I create my own global php.ini, so that I can customize my include path when running propel-gen from the command line? I tried it, and I got this error from CLI, which means it can't find the Phing instance in the pear folder I created.

Fatal error: require_once(): Failed opening required 'phing/Project.php' 
(include_path='/home/quantegy/pear/php/../classes:.:/usr/local/lib/php') in
/home/quantegy/pear/php/phing/Phing.php on line 22

asked 25 Aug '13, 21:31

quantegy
337
accept rate: 0%

We're unsure what you mean by "global php.ini" - can you clarify?

In general, you can use an app-level php.ini, and more information is available in our documentation here: http://docs.webfaction.com/software/php.html#configuring-php

(25 Aug '13, 22:29) ryans ♦♦

Well, maybe global was the wrong term. What I mean is that php.ini on a application-by-application basis, works great for sites, but propel-gen is used from the command line, and it is referring to what I assume is the server-wide php.ini. Is this correct or is there another ini file around specifically for my use in my home directory? The first include path is close to what I need, but for some reason it points to a directory that doesn't even exist.

(26 Aug '13, 09:27) quantegy

Use the -c option when invoking PHP:

$ php54 --help | grep -- -c
  -c <path>|<file> Look for php.ini file in this directory

Hope that helps!

permanent link

answered 26 Aug '13, 13:04

seanf
12.2k41836
accept rate: 37%

Problem here is I'm not invoking php, I'm invoking propel-gen. I'll have to change something in that script maybe.

(26 Aug '13, 14:05) quantegy

Ok, looking at ~/pear/phing, I think if you set a PHP_COMMAND environment variable, then you should be good to go, eg:

export PHP_COMMAND="/usr/local/bin/php53 -c ~/path/to/php.ini"
(26 Aug '13, 14:17) seanf

It's not referencing my custom php.ini at all.

(26 Aug '13, 17:48) quantegy

Ok, open a support ticket and we'll be happy to look into it further.

(26 Aug '13, 18:32) seanf
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×262
×9
×1
×1

question asked: 25 Aug '13, 21:31

question was seen: 3,636 times

last updated: 26 Aug '13, 18:32

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2019 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM