22850 Posts in 9711 Topics by 2803 members
General questions about getting started with SilverStripe that don't fit in any of the categories above.
|Go to End|
7 August 2013 at 8:40pm
Does anyone know how I could run
each night on a PC which is running Windows 2003?
8 August 2013 at 7:56am
I did not expect this to be so challenging!
The following command
d:/wamp/bin/php/php5.2.11/php d:/vhosts/buckfastleigh/sapphire/cli-script.php dev/buildcache flush=1 force=1
which I have issued at a dos prompt has so far taken 6 hours to publish 14 out of 17 pages. This operation takes seconds when issued in the browser after logging in.
Rather than trying to jump though all the hoops which running cli-script.php involves I think my preferred option would now be to run the command from my browser by bypassing authentication through checking IP address and script name.
However even this appears to be difficult in so far as I am struggling to find in which script I can add logic to stop the login page from appearing.
I will probably get there in the end but why does this have to be so time consuming? So far I have spent all day on this.
9 August 2013 at 4:26am Last edited: 9 August 2013 6:23am
Ok, after 2 whole days of trying various things I think I have this sussed.
I inserted the following line at the top of Security::permissionFailure
if(stristr($_SERVER['QUERY_STRING'],'buildcache') && $_SERVER['REMOTE_ADDR']==$exempt_ip)return;
where $exempt_ip is the IP address which runs the script.
I am running Version 2.4.7.
PS. For some reason the script would only complete and create the cache files if the script's url contained a trailing slash.
|Go to Top|