Project

General

Profile

Using Redux to serve images on myamiweb » History » Revision 8

Revision 7 (Neil Voss, 08/14/2012 01:53 PM) → Revision 8/64 (Neil Voss, 08/14/2012 01:55 PM)

h1. Using Redux to serve images on myamiweb 

 h2. Installation 

 # Follow [[Web_Server_Installation]] but ignore warning on not using php 5.3 
 # Install redux prerequisites as found in its README file 
 # Install myami-redux branch of myami on the webserver machine.    Redux needs write permission at its installation location to write fftw wisdom file. 

 <pre> 
 sudo easy_install fs 
 </pre> 

 h2. Configurations: 

 # Assign redux server in myamiweb 
 <pre> 
 define('SERVER_HOST',"your_hostname") 
 </pre> 

 # Using Redux cache 
 ** At myamiweb/config.php 
 <pre> 
 define('USE_REDUX_CACHE',true) 
 </pre> 
 ** Turn it on or off in redux/pipeline.py 
 ** Input the desired disk_cache_path, disk_cache_size, and mem_cache_size in the next few lines 
 ** Create the disk_cache_path before running redux if cache will be used 
 <pre> 
 sudo mkdir /tmp/redux 
 chmod 777 /tmp/redux 
 </pre> 

 h2. Test Installation 

 # Using Redux to do simple input output: 
 <pre> 
 cd /your_myami_download/redux/bin 
 redux --filename=test.jpg --oformat=PNG > test.png 
 </pre> 

 h2. Using redux server with myamiweb 
 # start redux server. (reduxd is in excutable path if installed) 
 <pre> 
 reduxd 
 </pre> 
 # test by accessing an image in myamiweb/imageviewer.php 

 h2. run at boot 

 <pre> 
 sudo cp -v myami/redux/init.d/reduxd /etc/init.d/ 
 sudo service reduxd start 
 </pre>