Last active
August 29, 2015 14:06
-
-
Save ijobling/74cacf8f5174eb34d5d3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
########################################################################## | |
#### Script to copy install process explained in codio Phalcon PHP Tutorial at | |
#### https://codio.com/s/docs/specifics/phalcon/ --not done yet | |
########################################################################## | |
#### Instructions | |
#### Option 1. | |
#### From the Codio Dashboard, create a new project and select the Git Tab | |
#### and then paste the following URL into the box | |
#### https://gist.github.com/74cacf8f5174eb34d5d3.git | |
#### Give your project a name and click Create. | |
#### Option 2. | |
#### From the Codio Dashboard, create a new Empty template project. | |
#### Open a Terminal window from the Tools->Terminal window | |
#### Copy the contents of this file to a file called 'phalconinst.sh' in the root of your machines file system | |
#### Then run the script in the terminal window by typing | |
#### bash phalconinst.sh | |
#### End of Instructions | |
########################################################################## | |
echo | |
echo " START OF AUTOMATED INSTALL" | |
echo | |
# set the hostname variable | |
CODIO_HOST=`cat /etc/hostname` | |
# set colour output = echo -e '\E[1;33;44m' | |
# remove colour = ; tput sgr0 | |
# See http://www.tldp.org/LDP/abs/html/colorizing.html for colour codes | |
echo -e '\E[1;33;44m' "Install php-phalcon"; tput sgr0 | |
parts install php5-phalcon | |
echo -e '\E[1;33;44m' "Remove file to allow process to continue"; tput sgr0 | |
rm phalconinst.sh | |
echo -e '\E[1;33;44m' "Create a base directory for Phalcon-PHP projects"; tput sgr0 | |
mkdir -p ~/workspace/projects/phalcon | |
cd ~/workspace/projects/phalcon | |
echo -e '\E[1;33;44m' "Clone the Phalcon tutorial"; tput sgr0 | |
git clone https://github.com/phalcon/tutorial | |
# Use the built-in PHP web server to run the Phalcon website: | |
php -S 0.0.0.0:3000 -t ~/workspace/projects/phalcon/tutorial/public/ | |
echo | |
echo | |
echo -e '\E[1;37;44m'" ......Phalcon-PHP is Installed!"; tput sgr0 | |
echo - | |
echo To get to your Phalcon-PHP site, open your browser and go to - | |
echo | |
echo http://"$CODIO_HOST".codio.io:3000 | |
echo | |
echo "or" | |
echo from the Preview menu - the right most Codio menu and select | |
echo the drop down menu and check New Browser Tab and select Box URL. | |
echo and you should see | |
echo | |
echo "...Hello!...Sign Up Here!..." |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment