[jbosstools-issues] [JBoss JIRA] (JBIDE-15261) Fail to create an app with both addon cartridge and source code

Andre Dietisheim (JIRA) jira-events at lists.jboss.org
Fri Jul 19 09:15:28 EDT 2013


    [ https://issues.jboss.org/browse/JBIDE-15261?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12791000#comment-12791000 ] 

Andre Dietisheim commented on JBIDE-15261:
------------------------------------------

If you read the above error message you see that the initial build on OpenShift is missing the mysql database. We tell OpenShift to create an application starting with the sourcecode at the given git url and only add the cartridge in a 2nd latter step:

# create application (with or without custom sourcecode)
# add cartridge

The initial build on OpenShift therefore cannot find the embedded mysql database. It'll get added latter only.
When executing rhc I see that they apparently have a different sequence of operations:

# create application
# add cartridge
# clone custom source into application

{code}
rhc app create mysqltest1 php-5.3 mysql-5.1 --from-code=https://github.com/openshift/wordpress-example
Invalid gemspec in [/usr/lib/ruby/gems/1.8/specifications/json_pure-1.6.1.gemspec]: invalid date format in specification: "2011-09-18 00:00:00.000000000Z"
Password: *********


Application Options
-------------------
  Namespace:   foobarz
  Cartridges:  php-5.3, mysql-5.1
  Source Code: https://github.com/openshift/wordpress-example
  Gear Size:   default
  Scaling:     no

Creating application 'mysqltest1' ... done

Your public SSH key must be uploaded to the OpenShift server to access code.  Upload now? (yes|no) no

You can upload your SSH key at a later time using the 'rhc sshkey' command

Waiting for your DNS name to be available ... done

Downloading the application Git repository ...
Cloning into 'mysqltest1'...
The authenticity of host 'mysqltest1-foobarz.rhcloud.com (107.20.6.145)' can't be established.
RSA key fingerprint is cf:ee:77:cb:0e:fc:02:d7:72:7e:ae:80:c0:90:88:a7.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'mysqltest1-foobarz.rhcloud.com' (RSA) to the list of known hosts.

Your application code is now in 'mysqltest1'

mysqltest1 @ http://mysqltest1-foobarz.rhcloud.com/ (uuid: 51e939cce0b8cd91e9000005)
------------------------------------------------------------------------------------
  Created:         3:06 PM
  Gears:           1 (defaults to small)
  Git URL:         ssh://51e939cce0b8cd91e9000005@mysqltest1-foobarz.rhcloud.com/~/git/mysqltest1.git/
  Initial Git URL: https://github.com/openshift/wordpress-example
  SSH:             51e939cce0b8cd91e9000005 at mysqltest1-foobarz.rhcloud.com

  php-5.3 (PHP 5.3)
  -----------------
    Gears: Located with mysql-5.1

  mysql-5.1 (MySQL Database 5.1)
  ------------------------------
    Gears:          Located with php-5.3
    Connection URL: mysql://$OPENSHIFT_MYSQL_DB_HOST:$OPENSHIFT_MYSQL_DB_PORT/
    Database Name:  mysqltest1
    Password:       ******
    Username:       ******

RESULT:
Application mysqltest1 was created.


mysql-5.1: Connection URL: mysql://$OPENSHIFT_MYSQL_DB_HOST:$OPENSHIFT_MYSQL_DB_PORT

Starting Apache+mod_php HTTPD server

MySQL 5.1 database added.  Please make note of these credentials:
       Root User: *****
   Root Password: *****
   Database Name: mysqltest1
Connection URL: mysql://$OPENSHIFT_MYSQL_DB_HOST:$OPENSHIFT_MYSQL_DB_PORT/
You can manage your new MySQL database by also embedding phpmyadmin-3.4.
The phpmyadmin username and password will be the same as the MySQL credentials above.
{code}
                
> Fail to create an app with both addon cartridge and source code
> ---------------------------------------------------------------
>
>                 Key: JBIDE-15261
>                 URL: https://issues.jboss.org/browse/JBIDE-15261
>             Project: Tools (JBoss Tools)
>          Issue Type: Bug
>          Components: openshift
>    Affects Versions: 4.1.0.Beta2
>            Reporter: nan wei
>            Assignee: Andre Dietisheim
>         Attachments: create-wordpress-example.png, initial-build-failed.png
>
>
> Version:
> JBoss Deverloper Studio 7 Beta
> OpenShift Plugin: 2.5.0.Beta2-v20130621-1052-B65
> OpenShift Enterprise 1.2/2013-07-18.4
> How reproducible:
> always
> Steps to Reproduce:
> 1. Create an app in the JBoss Deverloper Studio.
>    Name: mysqltest
>    Type: PHP 5.3(php-5.3)
>    Embeddable Cartridges: MySQL Database 5.1(mysql-5.1)
> 2. Click Advanced
>    Add Source Code:https://github.com/openshift/wordpress-example
> !create-wordpress-example.png!
> Actual results:
> When creating an app, check mysql cartridge and add source code together, it will fail, and return the following error:
> !initial-build-failed.png!
> {code}
> Could not create application "a3"
> Could not request https://broker.ose0717.com/broker/rest/domains/nwei/applications: The initial build for the application failed. Last 10 kB of build output:
> httpd (no pid file) not running
> Could not find mysql database.  Please run:
> rhc cartridge add -a a3 -c mysql-5.1
> then make a sample commit (add whitespace somewhere) and re-push
> An error occurred executing 'gear postreceive'
> For more details about the problem, try running the command again with the '--trace' option.
> {code}
> But if use rhc client, there is no such problem, it is created successfully.
> # rhc app create mysqltest1 php-5.3 mysql-5.1 --from-code=https://github.com/openshift/wordpress-example

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jbosstools-issues mailing list