lib/app42/base/help.rb in app42-0.6.2 vs lib/app42/base/help.rb in app42-0.6.3

- old
+ new

@@ -65,30 +65,33 @@ BPaaS setupBPaaS # Setup App42 BPaaS by choosing required configuration deleteBPaaS # Delete the BPaaS setup startBPaaS # Start the BPaaS setup stopBPaaS # Stop the BPaaS setup + restartBPaaS # Restart the BPaaS setup upgradeBPaas # Upgrade BPaaS by choosing required configuration downgradeBPaas # Downgrade BPaaS by choosing required configuration bPaaSInfo # Show BPaaS setup information bPaaSSetups # List all the BPaaS setups WordPress setupWordPress # Setup App42 WordPress by choosing required configuration deleteWordPress # Delete the WordPress setup startWordPress # Start the WordPress setup stopWordPress # Stop the WordPress setup + restartWordPress # Restart the WordPress setup upgradeWordPress # Upgrade WordPress by choosing required configuration downgradeWordPress # Downgrade WordPress by choosing required configuration wordPressInfo # Show WordPress setup information wordPressSetups # List all the WordPress setups GPaaS setupGPaaS # Setup App42 GPaaS by choosing required configuration deleteGPaaS # Delete the GPaaS setup startGPaaS # Start the GPaaS setup stopGPaaS # Stop the GPaaS setup + restartGPaaS # Restart the GPaaS setup upgradeGPaas # Upgrade GPaaS by choosing required configuration downgradeGPaas # Downgrade GPaaS by choosing required configuration gPaaSInfo # Show GPaaS setup information gPaaSSetups # List all the GPaaS setups @@ -188,69 +191,50 @@ Setup your deployment and runtime environment i.e. Instance(Memory, CPU) and Technology Stack Example: $app42 setupInfra - Application Name: demo + Enter App Name: demo Checking App Name Availability... OK 1: Shared Select Instance Type [Shared]: - 1: Amazon us-west-2 - Select IaaS Provider [Amazon us-west-2]: + 1: Amazon (Oregon) + Select IaaS Provider [Amazon (Oregon)]: 1: Ruby 2.0.0 2: Java 6 3: Java 7 4: PHP 5.3 5: PHP 5.5 + 6: Node 0.10.22 Select Runtime [Ruby 2.0.0]: 1: Ruby on Rack 2: Rails 4.0 3: Sinatra 1.4 Select Framework [Ruby on Rack ]: - 1: Nginx 1.4.1 - Select Web Server [Nginx 1.4.1]: + 1: Passenger 4.0 + 2: Thin 1.6 + 3: Unicorn 4.7 + Select Web Server [Passenger 4.0]: - Specify Kontena Power: 5 - + Specify Kontena Power: 1 + Setting up the infrastructure... OK - - Operation is in progress, Please wait.../ - - Setup Infra completed successfully. + Operation is in progress, Please wait...| + Setup Infra has been completed successfully. + Default application has been deployed. You can visit 'https://demo.iab.app42paas.com' to see the default application. DESC end - def apps - print <<-DESC -Usage: - app42 apps - - List all the deployed applications with their meta details - -Example: - $app42 apps - - +--------------------------------+------------+-----------------+------+------------+----------------+---------------+--------+ - | === My Apps === | - +--------------------------------+------------+-----------------+------+------------+----------------+---------------+--------+ - | App Url | App Status | Iaas Provider | Name | Runtime | Instance Count | Framework | Memory | - +--------------------------------+------------+-----------------+------+------------+----------------+---------------+--------+ - | https://demo.iab.app42paas.com | RUNNING | Amazon (Oregon) | demo | Ruby 2.0.0 | 1 | Ruby on Rack | 256 MB | - +--------------------------------+------------+-----------------+------+------------+----------------+---------------+--------+ - DESC - - end - def deploy print <<-DESC Usage: app42 deploy @@ -268,11 +252,11 @@ Enter Git URL?: https://github.com/shepHertz/demo.git Deploying Application... OK Operation is in progress, Please wait...| - App deployed successfully. + App has been deployed successfully. DESC end def update @@ -293,15 +277,66 @@ Choose Upload Type [Binary]: 2 Updating Application... OK Operation is in progress, Please wait...- - App deployed successfully. + App has been deployed successfully. DESC + end + def scale + print <<-DESC +Usage: + app42 scale + + Scale application either by number of instance(s) OR kontena(s) + +Options: + [--app APP] # Name of app, you want to scale + +Example: + $app42 scale + Enter App Name: demo + + 1: Horizontal + 2: Vertical + Choose Scale Type [Horizontal]: + + Horizontal scale by instance(s) [1]: + Scaling Application demo by instance 1... OK + + Operation is in progress, Please wait...- + Scale has been completed successfully. + DESC end + def descale + print <<-DESC +Usage: + app42 descale + + Descale application either by number of instance(s) OR kontena(s) + +Options: + [--app APP] # Name of app, you want to descale + +Example: + $app42 descale + Enter App Name: demo + + 1: Horizontal + 2: Vertical + Choose Scale Type [Horizontal]: + + Horizontal descale by instance(s) [1]: 1 + Descaling Application demo by instance 1... OK + + Operation is in progress, Please wait...| + Descale has been completed successfully. + DESC + end + def start print <<-DESC Usage: app42 start @@ -317,11 +352,11 @@ Operation is in progress, Please wait... 1 out of 3 started - 2 out of 3 started | - App started successfully. + App has been started successfully. DESC end def stop @@ -341,11 +376,11 @@ Operation is in progress, Please wait...- 1 out of 3 stopped - 2 out of 3 stopped - - App stopped successfully. + App has been stopped successfully. DESC end def restart print <<-DESC @@ -364,11 +399,11 @@ Operation is in progress, Please wait... 1 out of 3 restarted - 2 out of 3 restarted | - App restarted successfully. + App has been restarted successfully. DESC end def deleteinfra print <<-DESC @@ -387,93 +422,35 @@ Operation is in progress, Please wait... 1 out of 3 deleted - 2 out of 3 deleted | - App deleted successfully. + App has been deleted successfully. DESC end - def descale + def apps print <<-DESC Usage: - app42 descale + app42 apps - Descale application either by number of instance(s) OR kontena(s) + List all the deployed applications with their meta details -Options: - [--app APP] # Name of app, you want to descale - Example: - $app42 descale - Enter App Name: demo + $app42 apps + + +--------------------------------+------------+-----------------+--------------------------+------+------------+----------------+---------------+--------+ + | === My Apps === | + +--------------------------------+------------+-----------------+--------------------------+------+------------+----------------+---------------+--------+ + | App Url | App Status | Iaas Provider | Email | Name | Runtime | Instance Count | Framework | Memory | + +--------------------------------+------------+-----------------+--------------------------+------+------------+----------------+---------------+--------+ + | https://demo.iab.app42paas.com | RUNNING | Amazon (Oregon) | pravinmishra88@gmail.com | demo | Ruby 2.0.0 | 1 | Ruby on Rack | 256 MB | + +--------------------------------+------------+-----------------+--------------------------+------+------------+----------------+---------------+--------+ + DESC - 1: Horizontal - 2: Vertical - Choose Scale Type [Horizontal]: - - Horizontal descale by instance(s) [1]: 1 - Descaling Application demo by instance 1... OK - - Operation is in progress, Please wait...| - Descale completed successfully. - DESC end - def scale - print <<-DESC -Usage: - app42 scale - - Scale application either by number of instance(s) OR kontena(s) - -Options: - [--app APP] # Name of app, you want to scale - -Example: - $app42 scale - Enter App Name: demo - - 1: Horizontal - 2: Vertical - Choose Scale Type [Horizontal]: 2 - - Vertical scale by kontena power(s) [1]: - Scaling Application demo by kontena(s) 1... OK - - Operation is in progress, Please wait...| - - Scale completed successfully. - DESC - end - - def uploadbackup - print <<-DESC -Usage: - app42 uploadBackup - - Upload file data into a service - -Options: - [--service SERVICE] # Name of service, you want to scale - -Example: - $app42 uploadBackup - Enter Service Name: db - - Enter Backup File Path: /home/ubuntu/Downloads/demo_production-27Nov2013.sql - - Do you also want to restore uploaded backup? [Yn]: n - Please be patient... This process may take a while to complete. - - Uploading Service Backup... OK - - Operation is in progress, Please wait... - Backup has been successfully restored. - DESC - end - def appinfo print <<-DESC Usage: app42 appInfo @@ -535,27 +512,93 @@ | https://apphq.app42paas.com/app/getInstanceLog?id=wynv58rt509yj7fqwbkh80zlw6isf6g2 | +-----------------------------------------------------------------------------------+ DESC end + def addcustomurl + print <<-DESC +Usage: + app42 addCustomURL + Add a custom URL to an app + +Example: + $app42 addCustomURL + Enter App Name: demo + + Enter Custom URL: http://test.naveengoswami.com + + Adding Custom URL To Application demo... OK + Custom URL added successfully. + DESC + end + + def removecustomurl + print <<-DESC +Usage: + app42 removeCustomURL + + Remove a custom URL from an app + +Example: + $ app42 removeCustomURL + Enter App Name: demo + + Enter Custom URL: http://test.naveengoswami.com + + Removing Custom URL... OK + Custom URL deleted successfully. + DESC + end + + def customurlinfo + print <<-DESC +Usage: + app42 customURLInfo + + List all custom URLs of an app + +Example: + $app42 customURLInfo + Enter App Name: demo + + +----------+-----------------------+-------------------------------+ + | === testPhp Custome URLs Details === | + +----------+-----------------------+-------------------------------+ + | App Name | Created On | Url | + +-------------+-----------------------+----------------------------+ + | demo | 2014-01-27 06:35:55.0 | http://test.naveengoswami.com | + +----------+-----------------------+-------------------------------+ + DESC + end + def createservice print <<-DESC Usage: app42 createService Creates a new service e.g. MySQL, MongoDB, CouchDB, PostgreSQL etc. Example: $app42 createService + Enter Service Name: mysqldemo + + Deleting Service... OK + + Operation is in progress, Please wait... + Service has been deleted successfully. + + ubuntu@ubuntu-Lenovo-G580:~/workspace/App42PasS/PaaS/app42$ app42 createService Enter Service Name: mysqldb + Checking Service Name Availability... OK 1: MySQL 5.5.31 2: Mongodb 2.4.4 3: Couchdb 1.0.1 4: PostgreSQL 9.1.9 + 5: Redis 2.8.3 Select Service [MySQL 5.5.31]: Enter Database Name: demo_db 1: Shared @@ -566,20 +609,20 @@ Specify Kontena Power: 1 Creating Service... OK - Operation is in progress, Please wait...| - Service created successfully. + Operation is in progress, Please wait...- + Service has been created successfully. - +---------------+-----------------+----------------------------------+--------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | === mysqldb Details === | - +---------------+-----------------+----------------------------------+--------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | Database Name | Iaas Provider | Token | Vm Ip | State | User Name | Vm Port | Service Type | Password | Memory | Service Name | - +---------------+-----------------+----------------------------------+--------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | demo_db | Amazon (Oregon) | ytxsq0ov7lf5s4foh2igw01bwy32ydgp | 172.16.2.167 | RUNNING | aoafi8vgczxoftw4 | 12411 | MySQL 5.5.31 | a2rzmvrdr7hpa08a6k1a1r24ixdutyl9 | 256 MB | mysqldb | - +---------------+-----------------+----------------------------------+--------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ + +---------------+-----------------+----------------------------------+--------------+---------+------------------+-----------+---------+--------------+----------------+----------------------------------+--------+--------------+ + | === mysqldb Details === | + +---------------+-----------------+----------------------------------+--------------+---------+------------------+-----------+---------+--------------+----------------+----------------------------------+--------+--------------+ + | Database Name | Iaas Provider | Token | Vm Ip | State | User Name | Source Ip | Vm Port | Service Type | Destination Ip | Password | Memory | Service Name | + +---------------+-----------------+----------------------------------+--------------+---------+------------------+-----------+---------+--------------+----------------+----------------------------------+--------+--------------+ + | demo_db | Amazon (Oregon) | 0pcmpc64srphrwijmy616uipdjv7t0oi | 172.16.2.167 | RUNNING | admk0ltirejxgh3o | | 27875 | MySQL 5.5.31 | | a66tyn077yhlx2gue0t2nsjplls56g7m | 256 MB | mysqldb | + +---------------+-----------------+----------------------------------+--------------+---------+------------------+-----------+---------+--------------+----------------+----------------------------------+--------+--------------+ DESC end def deleteservice print <<-DESC @@ -591,16 +634,17 @@ Options: [--service SERVICE] # Name of service Example: $app42 deleteService - Enter Service Name: mysqldemo + Enter Service Name: mysqldb Deleting Service... OK - + Operation is in progress, Please wait...| - Service deleted successfully. + Service has been deleted successfully. + DESC end def startservice print <<-DESC @@ -612,19 +656,42 @@ Options: [--app Service] # Name of service, you want to start Example: $app42 startService - Enter Service Name: mysql - Starting Service mysql... OK + Enter Service Name: mysqldb - Operation is in progress, Please wait...| - Service started successfully. + Starting Service mysqldb... OK + + Operation is in progress, Please wait...- + Service has been started successfully. DESC end + def restartservice + print <<-DESC +Usage: + app42 restartService + + Restart the service + +Options: + [--app Service] # Name of service, you want to start + +Example: + $app42 restartService + Enter Service Name: mysqldb + + Restarting Service mysqldb... OK + + Operation is in progress, Please wait... + Service has been restarted successfully. + DESC + + end + def stopservice print <<-DESC Usage: app42 stopService @@ -633,19 +700,42 @@ Options: [--app Service] # Name of service, you want to start Example: $app42 stopService - Enter Service Name: mysql - Stopping Service mysql... OK + Enter Service Name: mysqldb - Operation is in progress, Please wait...| - Service stopped successfully. + Stopping Service mysqldb... OK + + Operation is in progress, Please wait... + Service has been stopped successfully. DESC end + def resetservicepassword + print <<-DESC +Usage: + resetServicePassword + + Reset the password of provisioned service + +Example: + $resetServicePassword + Enter Service Name: mysqldemo + + Enter Old Password: teh77o4b6kpb22ab6oogfu9lwru9vrlj + + Resetting Password... OK + + Operation is in progress, Please wait.../ + Service Password has been reset successfully. + + Your new password is: z2qo1vxeadak6jsmt9upobytwptc5eo0 + DESC + end + def scaleservice print <<-DESC Usage: app42 scaleService Vertically scale service by number of kontena(s) @@ -654,16 +744,16 @@ [--service SERVICE] # Name of service, you want to scale Example: $app42 scaleService Enter Service Name: mysqldb - + Vertical scale by kontena power(s) [1]: 1 Scaling Service 'mysqldb' by kontena 1... OK Operation is in progress, Please wait...| - Service scale completed successfully. + Vertical Scale has been completed successfully. DESC end def descaleservice @@ -676,252 +766,72 @@ [--service SERVICE] # Name of service, you want to scale Example: $app42 descaleService Enter Service Name: mysqldb - + Vertical descale by kontena power(s) [1]: 1 Descaling Service 'mysqldb' by kontena 1... OK - Operation is in progress, Please wait...| - Service descale completed successfully. + Operation is in progress, Please wait...- + Vertical Descale has been completed successfully. DESC end - def restartservice + def uploadbackup print <<-DESC Usage: - app42 restartService + app42 uploadBackup - Restart the service + Upload file data into a service Options: - [--app Service] # Name of service, you want to start + [--service SERVICE] # Name of service, you want to scale Example: - $app42 restartService - Enter Service Name: mysql - Restarting Service mysql... OK + $app42 uploadBackup + Enter Service Name: mysqldb - Operation is in progress, Please wait...| - Service restarted successfully. - DESC + Enter Backup File Path: /home/ubuntu/Downloads/demo_production-27Nov2013.sql - end + Do you also want to restore uploaded backup? [Yn]: n + Please be patient... This process may take a while to complete. - def services - print <<-DESC -Usage: - app42 services + Uploading Service Backup... OK - List the all provisioned services with their meta details - -Example: - $app42 services - +---------------+---------------+-----------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+ - | === Service List === | - +---------------+---------------+-----------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+ - | Database Name | Iaas Provider | Name | Vm Ip | State | User Name | Vm Port | Service Type | Password | Memory | - +---------------+---------------+-----------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+ - | demodb | Amazon | mysqldemo | 10.0.0.52 | RUNNING | j7zz1jsx1bb4eiz1 | 49695 | MySQL 5.5.1 | teh77o4b6kpb22ab6oogfu9lwru9vrlj | 512 MB | - +---------------+---------------+-----------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+ + Operation is in progress, Please wait... + Backup has been successfully restored. DESC end - def serviceinfo - print <<-DESC -Usage: - app42 serviceInfo - - Show meta information of the provisioned service - -Options: - [--service SERVICE] # Name of service - -Example: - 1: mysqldb - Select Service [mysqldb]: - - +---------------+-----------------+----------------------------------+--------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | === mysqldb Details === | - +---------------+-----------------+----------------------------------+--------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | Database Name | Iaas Provider | Token | Vm Ip | State | User Name | Vm Port | Service Type | Password | Memory | Service Name | - +---------------+-----------------+----------------------------------+--------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | demo_db | Amazon (Oregon) | ytxsq0ov7lf5s4foh2igw01bwy32ydgp | 172.16.2.167 | RUNNING | aoafi8vgczxoftw4 | 12411 | MySQL 5.5.31 | a2rzmvrdr7hpa08a6k1a1r24ixdutyl9 | 256 MB | mysqldb | - +---------------+-----------------+----------------------------------+--------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - DESC - end - - def supportedservices - print <<-DESC -Usage: - app42 supportedServices - - List the supported services by App42 - -Example: - $app42 supportedServices - +--------------+--------------+ - | === App42 PaaS Services === | - +--------------+--------------+ - | Name | Version | - +--------------+--------------+ - | MySQL | 5.5.1 | - | Mongodb | 2.4 | - | Couchdb | 10.1 | - | PostgreSQL | 9.1 | - +--------------+--------------+ - DESC - end - - def activities - print <<-DESC -Usage: - app42 activities - - List all activities with their status - -Example: - $app42 activities - +------------+-----------+------+------+-----------------------+ - | === User Activities === | - +------------+-----------+------+------+-----------------------+ - | Operation | Status | Name | Type | Date | - +------------+-----------+------+------+-----------------------+ - | setupInfra | COMPLETED | demo | APP | 2013-10-25 06:18:42.0 | - | scale | COMPLETED | demo | APP | 2013-10-25 06:40:39.0 | - | scale | COMPLETED | demo | APP | 2013-10-25 06:41:25.0 | - | descale | COMPLETED | demo | APP | 2013-10-25 06:42:12.0 | - | descale | COMPLETED | demo | APP | 2013-10-25 06:42:13.0 | - | restart | COMPLETED | demo | APP | 2013-10-25 06:44:31.0 | - | stop | COMPLETED | demo | APP | 2013-10-25 06:45:23.0 | - | start | COMPLETED | demo | APP | 2013-10-25 06:45:49.0 | - | scale | COMPLETED | demo | APP | 2013-10-25 06:52:56.0 | - | scale | COMPLETED | demo | APP | 2013-10-25 06:53:24.0 | - | descale | COMPLETED | demo | APP | 2013-10-25 06:58:10.0 | - | descale | COMPLETED | demo | APP | 2013-10-25 06:58:10.0 | - +------------+-----------+------+------+-----------------------+ - DESC - end - - def runtimes - print <<-DESC -Usage: - app42 runtimes - - List the supported runtimes - -Example: - $app42 runtimes - +--------------+--------------+ - | === Available Runtimes === | - +--------------+--------------+ - | Name | Version | - +--------------+--------------+ - | Ruby | 2.0 | - | Java | 6.0 | - | Java | 7.0 | - | Php | 5.3 | - | Php | 5.5 | - +--------------+--------------+ - DESC - end - - def iaasproviders - print <<-DESC -Usage: - app42 iaasProviders - - List the supported IaaS providers by App42 - -Example: - $app42 iaasProviders - +-----------------+-----------------+ - | === Available IaaS Providers === | - +-----------------+-----------------+ - | Name | Zone | - +-----------------+-----------------+ - | Amazon | (Oregon) | - +-----------------+-----------------+ - DESC - end - - - def app42_update + def bindip print <<-DESC Usage: - app42 app42-update - - Update App42PaaS client(app42) - -> Download app42 client, In a terminal, go to the folder where you have downloaded the client and run client update command. - -Example: - $app42 app42-update - Uninstalling current app42 client - Remove executables: - app42 - - in addition to the gem? [Yn] y - Removing app42 - Successfully uninstalled app42-0.5.0 - Installing latest app42 client - Successfully installed app42-0.5.0 - 1 gem installed - Installing ri documentation for app42-0.5.0... - Installing RDoc documentation for app42-0.5.0... - DESC - end - - def resetservicepassword - print <<-DESC -Usage: - resetServicePassword - - Reset the password of provisioned service - -Example: - $resetServicePassword - Enter Service Name: mysqldemo - - Enter Old Password: teh77o4b6kpb22ab6oogfu9lwru9vrlj - - Resetting Password... OK - - Operation is in progress, Please wait.../ - Service Password has been reset successfully. - - Your new password is: z2qo1vxeadak6jsmt9upobytwptc5eo0 - DESC - end - - def bindip - print <<-DESC -Usage: app42 bindIP Bind IP to provisioned service Example: $app42 bindIP - Enter Service Name: mysqldemo + Enter Service Name: mysqldb Please Provide Source IP - (For public access, use '0.0.0.0'): <IP address> + (For public access, use '0.0.0.0'): 0.0.0.0 Binding IP to service... OK - - Operation is in progress, Please wait...- - Service bind with IP successfully. - +---------------+---------------+----------------+-----------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | === mysqldemo Details === | - +---------------+---------------+----------------+-----------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | Database Name | Iaas Provider | Vm Ip | Source Ip | State | User Name | Vm Port | Service Type | Password | Memory | Service Name | - +---------------+---------------+----------------+-----------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | demodb | Amazon | 54.218.127.245 | 122.162.124.222 | RUNNING | j7zz1jsx1bb4eiz1 | 49695 | MySQL 5.5.1 | z2qo1vxeadak6jsmt9upobytwptc5eo0 | 512 MB | mysqldemo | - +---------------+---------------+----------------+-----------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ + Operation is in progress, Please wait... + Service binding has been completed successfully. + + +---------------+-----------------+----------------------------------+---------------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ + | === mysqldb Details === | + +---------------+-----------------+----------------------------------+---------------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ + | Database Name | Iaas Provider | Token | Vm Ip | Source Ip | State | User Name | Vm Port | Service Type | Password | Memory | Service Name | + +---------------+-----------------+----------------------------------+---------------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ + | demo_db | Amazon (Oregon) | 0pcmpc64srphrwijmy616uipdjv7t0oi | 54.213.93.154 | 0.0.0.0 | RUNNING | admk0ltirejxgh3o | 15847 | MySQL 5.5.31 | vagyqxta6e0a8q5jxunlr43v6cwohmdj | 256 MB | mysqldb | + +---------------+-----------------+----------------------------------+---------------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ DESC end def unbindip print <<-DESC @@ -930,18 +840,18 @@ Unbind IP from provisioned service Example: $app42 unbindIP - Enter Service Name: mysqldemo + Enter Service Name: mysqldb - Please Provide Source IP: <IP address> + Please Provide Source IP: 0.0.0.0 Unbinding IP to service... OK - - Operation is in progress, Please wait...| - Service unbind with IP successfully. + + Operation is in progress, Please wait... + Service unbinding has been completed successfully. DESC end def bindinfo print <<-DESC @@ -950,23 +860,68 @@ Show IP bind information related to provisioned service Example: $app42 bindInfo - 1: mysqldemo - Select Service [mysqldemo]: + 1: mysqldb + 2: redisdb + Select Service [mysqldb]: - +---------------+---------------+----------------+-----------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | === mysqldemo Details === | - +---------------+---------------+----------------+-----------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | Database Name | Iaas Provider | Vm Ip | Source Ip | State | User Name | Vm Port | Service Type | Password | Memory | Service Name | - +---------------+---------------+----------------+-----------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ - | demodb | Amazon | 54.218.127.245 | 122.162.124.222 | RUNNING | j7zz1jsx1bb4eiz1 | 49695 | MySQL 5.5.1 | z2qo1vxeadak6jsmt9upobytwptc5eo0 | 512 MB | mysqldemo | - +---------------+---------------+----------------+-----------------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ + +---------------+-----------------+----------------------------------+---------------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ + | === mysqldb Details === | + +---------------+-----------------+----------------------------------+---------------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ + | Database Name | Iaas Provider | Token | Vm Ip | Source Ip | State | User Name | Vm Port | Service Type | Password | Memory | Service Name | + +---------------+-----------------+----------------------------------+---------------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ + | demo_db | Amazon (Oregon) | 0pcmpc64srphrwijmy616uipdjv7t0oi | 54.213.93.154 | 0.0.0.0 | RUNNING | admk0ltirejxgh3o | 15847 | MySQL 5.5.31 | vagyqxta6e0a8q5jxunlr43v6cwohmdj | 256 MB | mysqldb | + +---------------+-----------------+----------------------------------+---------------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+--------------+ DESC end + def services + print <<-DESC +Usage: + app42 services + + List the all provisioned services with their meta details + +Example: + $app42 services + +---------------+---------------+-----------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+ + | === Service List === | + +---------------+---------------+-----------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+ + | Database Name | Iaas Provider | Name | Vm Ip | State | User Name | Vm Port | Service Type | Password | Memory | + +---------------+---------------+-----------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+ + | demodb | Amazon | mysqldemo | 10.0.0.52 | RUNNING | j7zz1jsx1bb4eiz1 | 49695 | MySQL 5.5.1 | teh77o4b6kpb22ab6oogfu9lwru9vrlj | 512 MB | + +---------------+---------------+-----------+-----------+---------+------------------+---------+--------------+----------------------------------+--------+ + DESC + end + + def serviceinfo + print <<-DESC +Usage: + app42 serviceInfo + + Show meta information of the provisioned service + +Options: + [--service SERVICE] # Name of service + +Example: + $ app42 serviceInfo + 1: mysqldb + Select Service [mysqldb]: 1 + + +---------------+-----------------+----------------------------------+--------------+---------+------------------+-----------+---------+--------------+----------------+----------------------------------+--------+--------------+ + | === mysqldb Details === | + +---------------+-----------------+----------------------------------+--------------+---------+------------------+-----------+---------+--------------+----------------+----------------------------------+--------+--------------+ + | Database Name | Iaas Provider | Token | Vm Ip | State | User Name | Source Ip | Vm Port | Service Type | Destination Ip | Password | Memory | Service Name | + +---------------+-----------------+----------------------------------+--------------+---------+------------------+-----------+---------+--------------+----------------+----------------------------------+--------+--------------+ + | demo_db | Amazon (Oregon) | 0pcmpc64srphrwijmy616uipdjv7t0oi | 172.16.2.167 | RUNNING | admk0ltirejxgh3o | 0.0.0.0 | 15847 | MySQL 5.5.31 | 54.213.93.154 | vagyqxta6e0a8q5jxunlr43v6cwohmdj | 256 MB | mysqldb | + +---------------+-----------------+----------------------------------+--------------+---------+------------------+-----------+---------+--------------+----------------+----------------------------------+--------+--------------+ + DESC + end + def setupbpaas print <<-DESC Usage: app42 setupBPaaS @@ -1012,51 +967,10 @@ Operation is in progress, Please wait...- Setup deleted successfully. DESC end - def bpaasinfo - print <<-DESC -Usage: - app42 bPaaSInfo - - Show setup information - -Example: - $app42 bPaaSInfo - Enter Setup Name: demo - - +-----------------------+----------------------------------------+------------+-----------------+------------+---------+---------------+--------------+-------------------------------------+ - | === demo Details === | - +-----------------------+----------------------------------------+------------+-----------------+------------+---------+---------------+--------------+-------------------------------------+ - | Created On | Api Server Url | Setup Name | Iaas Provider | Setup Type | Vm Type | Setup Flavour | Setup Status | App Hq Url | - +-----------------------+----------------------------------------+------------+-----------------+------------+---------+---------------+--------------+-------------------------------------+ - | 2014-02-24 08:00:21.0 | https://democloudapi.iab.app42paas.com | demo | Amazon (Oregon) | BPaaS | Shared | light | RUNNING | https://demoapphq.iab.app42paas.com | - +-----------------------+----------------------------------------+------------+-----------------+------------+---------+---------------+--------------+-------------------------------------+ - DESC - end - - def bpaassetups - print <<-DESC -Usage: - app42 bPaaSSetups - - List all the BPaaS setups - -Example: - $app42 bPaaSSetups - - +-----------------------+----------------------------------------+------------+-----------------+------------+--------------------------+---------+---------------+--------------+-------------------------------------+ - | === Setups List === | - +-----------------------+----------------------------------------+------------+-----------------+------------+--------------------------+---------+---------------+--------------+-------------------------------------+ - | Created On | Api Server Url | Setup Name | Iaas Provider | Setup Type | Email | Vm Type | Setup Flavour | Setup Status | App Hq Url | - +-----------------------+----------------------------------------+------------+-----------------+------------+--------------------------+---------+---------------+--------------+-------------------------------------+ - | 2014-02-24 08:00:21.0 | https://democloudapi.iab.app42paas.com | demo | Amazon (Oregon) | BPaaS | pravinmishra88@gmail.com | Shared | light | RUNNING | https://demoapphq.iab.app42paas.com | - +-----------------------+----------------------------------------+------------+-----------------+------------+--------------------------+---------+---------------+--------------+-------------------------------------+ - DESC - end - def startbpaas print <<-DESC Usage: app42 startBPaaS @@ -1089,10 +1003,28 @@ BPaaS setup demo stopped successfully. DESC end + def restartbpaas + print <<-DESC +Usage: + app42 restartBPaaS + + Restart the BPaaS setup + +Example: + $app42 restartBPaaS + Enter Setup Name: demo + Restarting BPaaS Setup demo... OK + + Operation is in progress, Please wait...| + + BPaaS setup demo restarted successfully. + DESC + end + def upgradebpaas print <<-DESC Usage: app42 upgradeBPaaS @@ -1135,10 +1067,51 @@ BPaaS setup demo downgraded successfully. DESC end + def bpaasinfo + print <<-DESC +Usage: + app42 bPaaSInfo + + Show setup information + +Example: + $app42 bPaaSInfo + Enter Setup Name: demo + + +-----------------------+----------------------------------------+------------+-----------------+------------+---------+---------------+--------------+-------------------------------------+ + | === demo Details === | + +-----------------------+----------------------------------------+------------+-----------------+------------+---------+---------------+--------------+-------------------------------------+ + | Created On | Api Server Url | Setup Name | Iaas Provider | Setup Type | Vm Type | Setup Flavour | Setup Status | App Hq Url | + +-----------------------+----------------------------------------+------------+-----------------+------------+---------+---------------+--------------+-------------------------------------+ + | 2014-02-24 08:00:21.0 | https://democloudapi.iab.app42paas.com | demo | Amazon (Oregon) | BPaaS | Shared | light | RUNNING | https://demoapphq.iab.app42paas.com | + +-----------------------+----------------------------------------+------------+-----------------+------------+---------+---------------+--------------+-------------------------------------+ + DESC + end + + def bpaassetups + print <<-DESC +Usage: + app42 bPaaSSetups + + List all the BPaaS setups + +Example: + $app42 bPaaSSetups + + +-----------------------+----------------------------------------+------------+-----------------+------------+--------------------------+---------+---------------+--------------+-------------------------------------+ + | === Setups List === | + +-----------------------+----------------------------------------+------------+-----------------+------------+--------------------------+---------+---------------+--------------+-------------------------------------+ + | Created On | Api Server Url | Setup Name | Iaas Provider | Setup Type | Email | Vm Type | Setup Flavour | Setup Status | App Hq Url | + +-----------------------+----------------------------------------+------------+-----------------+------------+--------------------------+---------+---------------+--------------+-------------------------------------+ + | 2014-02-24 08:00:21.0 | https://democloudapi.iab.app42paas.com | demo | Amazon (Oregon) | BPaaS | pravinmishra88@gmail.com | Shared | light | RUNNING | https://demoapphq.iab.app42paas.com | + +-----------------------+----------------------------------------+------------+-----------------+------------+--------------------------+---------+---------------+--------------+-------------------------------------+ + DESC + end + def setupwordpress print <<-DESC Usage: app42 setupWordPress @@ -1168,10 +1141,27 @@ Your WordPress setup has been completed successfully, For details, Login to PaaSHQ console. DESC end + def deletewordpress + print <<-DESC +Usage: + app42 deleteWordPress + + Delete the WordPress setup + +Example: + $app42 deleteWordPress + Enter Setup Name: demo + Deleting Setup... OK + + Operation is in progress, Please wait...- + WordPress Setup has been deleted successfully. + DESC + end + def startwordpress print <<-DESC Usage: app42 startWordPress @@ -1202,10 +1192,28 @@ Stopping Wordpress Setup demo... OK Operation is in progress, Please wait...| WordPress Setup has been stopped successfully. DESC + end + + def restartwordpress + print <<-DESC +Usage: + app42 restartWordPress + + Restart the WordPress setup + +Example: + $app42 restartWordPress + Enter Wordpress Name: demo + + Restarting Wordpress Setup demo... OK + + Operation is in progress, Please wait...- + WordPress Setup has been restarted successfully. + DESC end def upgradewordpress print <<-DESC Usage: @@ -1235,11 +1243,11 @@ app42 downgradeWordpress Downgrade WordPress by choosing required configuration Example: - $app42 upgradeWordPress + $app42 downgradeWordPress Enter Setup Name: demo 1: Light 2: Medium Select Flavour [Light]: 2 @@ -1248,27 +1256,10 @@ Operation is in progress, Please wait...- WordPress setup demo downgraded successfully. DESC - end - - def deletewordpress - print <<-DESC -Usage: - app42 deleteWordPress - - Delete the WordPress setup - -Example: - $app42 deleteWordPress - Enter Setup Name: demo - Deleting Setup... OK - - Operation is in progress, Please wait...- - Setup deleted successfully. - DESC end def wordpressinfo print <<-DESC @@ -1312,67 +1303,10 @@ +-----------------------+----------------------------------------+------------+----------------------------+------------+---------+---------------+--------------+ DESC end - def addcustomurl - print <<-DESC -Usage: - app42 addCustomURL - - Add a custom URL to an app - -Example: - $app42 addCustomURL - Enter App Name: demo - - Enter Custom URL: http://test.naveengoswami.com - - Adding Custom URL To Application demo... OK - Custom URL added successfully. - DESC - end - - def removecustomurl - print <<-DESC -Usage: - app42 removeCustomURL - - Remove a custom URL from an app - -Example: - $ app42 removeCustomURL - Enter App Name: demo - - Enter Custom URL: http://test.naveengoswami.com - - Removing Custom URL... OK - Custom URL deleted successfully. - DESC - end - - def customurlinfo - print <<-DESC -Usage: - app42 customURLInfo - - List all custom URLs of an app - -Example: - $app42 customURLInfo - Enter App Name: demo - - +----------+-----------------------+-------------------------------+ - | === testPhp Custome URLs Details === | - +----------+-----------------------+-------------------------------+ - | App Name | Created On | Url | - +-------------+-----------------------+----------------------------+ - | demo | 2014-01-27 06:35:55.0 | http://test.naveengoswami.com | - +----------+-----------------------+-------------------------------+ - DESC - end - def setupgpaas print <<-DESC Usage: app42 setupGPaaS @@ -1400,10 +1334,27 @@ Your GPaaS setup has been completed successfully, For details, Login to PaaSHQ console. DESC end + def deletegpaas + print <<-DESC +Usage: + app42 deleteGPaaS + + Delete the GPaaS setup + +Example: + $app42 deleteGPaaS + Enter Setup Name: demo + Deleting Setup... OK + + Operation is in progress, Please wait...| + GPaaS Setup has been deleted successfully. + DESC + end + def startgpaas print <<-DESC Usage: app42 startGPaaS @@ -1434,10 +1385,27 @@ Operation is in progress, Please wait...| GPaaS Setup has been stopped successfully. DESC end + def restartgpaas + print <<-DESC +Usage: + app42 restartGPaaS + + Restart the GPaaS setup + +Example: + $app42 restartGPaaS + Enter Setup Name: demo + Restarting GPaaS Setup demo... OK + + Operation is in progress, Please wait...| + GPaaS Setup has been restarted successfully. + DESC + end + def upgradegpaas print <<-DESC Usage: app42 upgradeGPaaS @@ -1479,27 +1447,10 @@ Operation is in progress, Please wait...- GPaaS Setup has been updated successfully. DESC end - def deletegpaas - print <<-DESC -Usage: - app42 deleteGPaaS - - Delete the GPaaS setup - -Example: - $app42 deleteGPaaS - Enter Setup Name: demo - Deleting Setup... OK - - Operation is in progress, Please wait...- - Setup deleted successfully. - DESC - end - def gpaasinfo print <<-DESC Usage: app42 gPaaSInfo @@ -1541,22 +1492,115 @@ +-----------------------+-------------------------------------------+------------+----------------------------+------------+--------------------------+-----------+---------------+--------------+ DESC end - def version - print <<-DESC + def supportedservices + print <<-DESC Usage: + app42 supportedServices + + List the supported services by App42 + +Example: + $app42 supportedServices + +--------------+--------------+ + | === App42 PaaS Services === | + +--------------+--------------+ + | Name | Version | + +--------------+--------------+ + | MySQL | 5.5.1 | + | Mongodb | 2.4 | + | Couchdb | 10.1 | + | PostgreSQL | 9.1 | + +--------------+--------------+ + DESC + end + + def activities + print <<-DESC +Usage: + app42 activities + + List all activities with their status + +Example: + $app42 activities + +------------+-----------+------+------+-----------------------+ + | === User Activities === | + +------------+-----------+------+------+-----------------------+ + | Operation | Status | Name | Type | Date | + +------------+-----------+------+------+-----------------------+ + | setupInfra | COMPLETED | demo | APP | 2013-10-25 06:18:42.0 | + | scale | COMPLETED | demo | APP | 2013-10-25 06:40:39.0 | + | scale | COMPLETED | demo | APP | 2013-10-25 06:41:25.0 | + | descale | COMPLETED | demo | APP | 2013-10-25 06:42:12.0 | + | descale | COMPLETED | demo | APP | 2013-10-25 06:42:13.0 | + | restart | COMPLETED | demo | APP | 2013-10-25 06:44:31.0 | + | stop | COMPLETED | demo | APP | 2013-10-25 06:45:23.0 | + | start | COMPLETED | demo | APP | 2013-10-25 06:45:49.0 | + | scale | COMPLETED | demo | APP | 2013-10-25 06:52:56.0 | + | scale | COMPLETED | demo | APP | 2013-10-25 06:53:24.0 | + | descale | COMPLETED | demo | APP | 2013-10-25 06:58:10.0 | + | descale | COMPLETED | demo | APP | 2013-10-25 06:58:10.0 | + +------------+-----------+------+------+-----------------------+ + DESC + end + + def runtimes + print <<-DESC +Usage: + app42 runtimes + + List the supported runtimes + +Example: + $app42 runtimes + +--------------+--------------+ + | === Available Runtimes === | + +--------------+--------------+ + | Name | Version | + +--------------+--------------+ + | Ruby | 2.0 | + | Java | 6.0 | + | Java | 7.0 | + | Php | 5.3 | + | Php | 5.5 | + +--------------+--------------+ + DESC + end + + def iaasproviders + print <<-DESC +Usage: + app42 iaasProviders + + List the supported IaaS providers by App42 + +Example: + $app42 iaasProviders + +-----------------+-----------------+ + | === Available IaaS Providers === | + +-----------------+-----------------+ + | Name | Zone | + +-----------------+-----------------+ + | Amazon | (Oregon) | + +-----------------+-----------------+ + DESC + end + + def version + print <<-DESC +Usage: app42 version Show Ruby client gem version Example: $app42 version App42 current version: 0.5.3 DESC - - end + end end end end