FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


PHP CLI





Slammer
hey everyone. Ive got a socket server that ive written in php and run it through the php command line. And currently im running it locally while im developing it. Which is fine. Although i want to move it to a proper server for when i make it open to the public. I know its not possible on frihost, as you need shell access(I think) to be able to run them. I dont need any 'web' space with it, i just need to be able to run this script and have some bandwidth to handle the traffic. So am i right in saying that i would need a shell account somewhere? that supports php...and would a script running be classed as a background job?

I dont know if im making much sense. I just need to be able to host this script somewhere. If you know how then please let me know. And if you know of any free hosts that would it, that would be great!.

Thanks
Slammer
Atomo64
I don't think that anybody is going to let you use their hosting to run a CLI script, may I ask you what your script does? that you can't do it by using a normal script?
Slammer
I said what is does in my original post. Its my socket server, therefore it cant run on normal hosting obviously.
simplyw00x
You can certainly run this. Check out my AMAZING OH DEAR GOD IT'S SO GOOD I WANT IT NOW tutorial on getting shell access on Frihost here.

If your php file name is woot.php, enter:
Code:
php woot.php

If it's a socket server it should probably run as a background process. Try:
Code:
php woot.php&


It may be that Frihost does not have php-cli installed, however. In this case consider writing it in either a bash script or perl, both of which Frihost supports. I don't know excactly what a socket server is, but this is a good place to get started.[/code]
svecia
http://www.arbornet.org/ is a place where You may have Your own shell account
but I recomend to run shell on Your own system Linux or some other Unix, or if You
use windows install bash it works just like a Unix shell.
Atomo64
Slammer wrote:
I said what is does in my original post. Its my socket server, therefore it cant run on normal hosting obviously.

but what I mean is... why do you need that
Quote:
socket server
? that's my question Smile
Slammer
Atomo64 wrote:
Slammer wrote:
I said what is does in my original post. Its my socket server, therefore it cant run on normal hosting obviously.

but what I mean is... why do you need that
Quote:
socket server
? that's my question Smile


Its for my web-based messaging service. Im currently researching funding and shall start looking for the first round of investors. Then i can run it on my own private dedicated servers, once i can afford them. It is fully scalable, so multiple servers can be running to share the load.

But until i can afford a dedicated server, i want to have it up and running with 1 server, with user limit cap on it. Just to get it out there in public. I can run it locally perfectly fine. And works great, but i dont want it to be running locally when its open to the public, due to several reasons. Like, other people in my family use my computers so theres no guarentee i can keep them on 24/7, isp might cut my connection if the traffic gets to much etc.
Atomo64
good, that reminds me an IM protocol system I started developing some time ago (I still have some parts of the specs), a very easy to use P2P IM protocol
Slammer
thank you simplyw00x! That got it working perfectly for me!

Atomo64, that sounds cool. My messenger is called 'Vobe' (http://vobe.frihost.net). It should be open to the public by the middle/end of Feburary hopefully!
Atomo64
Ok, I'm going to be checking your website so I can see how it is going your project Wink
simplyw00x
Quote:
thank you simplyw00x! That got it working perfectly for me!

No problem. I'm surprised it worked :p.
Related topics
http://tuvanonline.com/library/index.php
PHP-Nuke platium?
PHP Write to line
Anyone good with PHP-NUKE?
PHP safety?
PEAR path
PHP DB Error: syntax error
Running PHP Script without PHP Server?
Pear
How competitive is PHP?
Newbie needs help... Is PHP the answer???
Fetch Alexa Rank of website using PHP function easily
CLI for PHP available?
PHP 5.4.0 Release Announcement
Reply to topic    Frihost Forum Index -> Scripting -> Php and MySQL

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.