Deploy yii on pagoda box

You are viewing revision #6 of this wiki article.
This version may not be up to date with the latest version.
You may want to view the differences to the latest version.

next (#9) »

pagoda box is very useful tool for a programmer to test their php app online so its very useful one. For deploying code pagodabox use git command

pagoda getting-started

Refer article about yii:-

pagoda yii

especially refer how to use git in getting-started/articles

Before starting we need rubygems we can install it on linux using

sudo apt-get install rubygems1.9.1

then you need to install pagoda

sudo gem install pagoda

then check pagoda -h if its working your luck else you need to google the problem

may be you have to use rvm(ruby version mangaer)and install rubygems1.8.7 along with 1.9.1

Refer:-

http://blog.lysender.com/2011/12/pagodabox-terminal-client-on-slackware/

when you use pagoda command for first time

you may ask user name & password remember they are asking your pagodabox password not database Credentials username & password generated by pagodabox.

If you already entered wrong user name or password then they will show error find the directory in the error and remove the directory so then when you reuse ‘pagoda’ command they will ask again new user-name & password so enter correct one.

We can connect to database using two method

1)tunneling

2)phpmyadmin

Tunneling method is correct & recommended by pagodabox for those who pagoda terminal command is not working can use phpmyadmin

tunneling

sudo pagoda -a app_name tunnel -c db1

here app_name will be your app_name and db1 normally it should be db1 or may be it will db2 here it should be database component name

ok now if connection establish it show the response like in terminal 1 now without closing the terminal 1 open oter terminsl(terminal2) and connect using host name and port no shown in terminal 1 and database Credentials username & password.then using mysql command update database

setting box file also important check getting-started/articles about boxfile in boxfile we can define php extension we needed also

web1: #component type & number
  name: app_name            #component settings
  shared_writable_dirs:
    - /protected/runtime
    - /assets
  document_root: /
  php_version: 5.3.8
  php_extensions:
    - mysql #other extension are also included as you needed

db1:
  name: database_name
  type: mysql

ok now phpmyadmin download it and put in appication folder rename “config.sample.inc.php” inside phpMyAdmin to “config.inc.php” with follwoing change

$cfg[‘Servers’][$i][‘user’] = ‘username’; // database Credentials username

$cfg[‘Servers’][$i][‘password’] = ‘password’; // database Credentials password

$cfg[‘Servers’][$i][‘auth_type’] = ‘config’;

$cfg[‘Servers’][$i][‘connect_type’] = ‘tcp’; //

$cfg[‘Servers’][$i][‘host’] = ‘tunnel.pagodabox.com’;// database Credentials without port no

$cfg[‘Servers’][$i][‘port’] = ‘3306’;//database Credentials only port no

then commit with new change

now we can access to phpmyadmin by

http://app_name.pagodabox.com/phpMyAdmin/

instead of app_name give your app name then uploda or create db

Refer for using phpmyadmin:-

link..

Refer wiki article Collaborative software with git:- Collaborative software with git

regards

Nintriva

4 0
5 followers
Viewed: 11 921 times
Version: Unknown (update)
Category: Tutorials
Written by: francis ja
Last updated by: francis ja
Created on: Mar 7, 2012
Last updated: 11 years ago
Update Article

Revisions

View all history