You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stratos.apache.org by Lahiru Sandaruwan <la...@wso2.com> on 2014/04/02 08:20:33 UTC

"4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Hi,

We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
of the image. Need changes at[1]. File is [2].

Thanks.

[1]
https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
[2]
https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Dinesh Bandara <di...@wso2.com>.
On Thu, Apr 3, 2014 at 9:46 AM, Lahiru Sandaruwan <la...@wso2.com> wrote:

>
>
>
> On Wed, Apr 2, 2014 at 8:56 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>
>>
>>
>>
>> On Wed, Apr 2, 2014 at 8:48 PM, Dinesh Bandara <di...@wso2.com> wrote:
>>
>>>
>>> On Thu, Apr 3, 2014 at 9:15 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>
>>>>
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 8:38 PM, Nirmal Fernando <nirmal070125@gmail.com
>>>> > wrote:
>>>>
>>>>> Dinesh is already on it (I think he started a discussion on it.).
>>>>>
>>>>
>>>>  Great.
>>>>
>>>>>
>>>>>
>>>>> On Thu, Apr 3, 2014 at 9:06 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 8:24 PM, Nirmal Fernando <
>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>
>>>>>>>
>>>>>>> [Forwarding the bounced email]
>>>>>>>
>>>>>>> On Thu, Apr 3, 2014 at 8:51 AM, Nirmal Fernando <
>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>
>>>>>>>> puppetinstall is called by the config script
>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/config.sh;h=3347b805bc0841325ddf251b19572dfe1cc58394;hb=HEAD
>>>>>>>>
>>>>>>>> and puppetinstall file copies the stratos_sendinfo.rb.
>>>>>>>>
>>>>>>>>
>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/puppetinstall/puppetinstall;h=214edb3d6a79867ecec7e1e94e73a57d55e760a6;hb=HEAD
>>>>>>>>
>>>>>>>> Aren't you following the wiki document? :-)
>>>>>>>>
>>>>>>>
>>>>>> Nope. :) wiki document configuration is for creating a specific
>>>>>> cartridge image. I'm using a general image. I thought init.sh verifies all
>>>>>> the requirements as it has all the information from payload passed.
>>>>>>
>>>>>> Actually it is not the case and we can improve it.
>>>>>>
>>>>>> Generic image is a valid use case and we have to prepare resources
>>>>>> and create a guide for that.
>>>>>>
>>>>>
>>> I will add a note on wiki. simply we need to provide 'default' as the
>>> service name when running the config script then it will install puppet
>>> agent, java, cartridge agent which are required to create a generic image
>>>
>>
>> ah.. just the information i needed. :D
>> I was going to do it manually.
>>
>
>
> One question.
>
> If we change the puppet master after creating the base image, will it
> break the cartridge instance initialization?
>

Normally it won't be. All the time we have to initialize default
configurations at the bottom of the node.pp


 Thanks Dinesh.
>>
>>>
>>>
>>>
>>>>
>>>>>>>>
>>>>>>>> On Thu, Apr 3, 2014 at 4:52 AM, Lahiru Sandaruwan <lahirus@wso2.com
>>>>>>>> > wrote:
>>>>>>>>
>>>>>>>>> puppetinstall script is not call by any script. init-vcloud.sh
>>>>>>>>> seems to be having that. Seems the scripts are broken somewhere. So
>>>>>>>>> stratos_sendinfo.rb is not placed correctly.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Apr 2, 2014 at 9:46 AM, Nirmal Fernando <
>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>
>>>>>>>>>> Ah.. Please change
>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD
>>>>>>>>>>
>>>>>>>>>> to use
>>>>>>>>>>
>>>>>>>>>> stratos_instance_data_
>>>>>>>>>>
>>>>>>>>>> instead of stratos_
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <
>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>
>>>>>>>>>>> Issue was not adding correct parameters to
>>>>>>>>>>> "/etc/httpd/conf/httpd.conf". Because "<%= @stratos_host_name
>>>>>>>>>>> %>" was not exported since this script was not run.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <
>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Ok, can you send the issue you saw?
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <
>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> It seems not. I'm using a script used by Manula for some other
>>>>>>>>>>>>> deployment. But i cannot find that string in original one either...
>>>>>>>>>>>>> Here is the complete script i'm using,
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> class php ($syslog="", $docroot="/var/www/html",
>>>>>>>>>>>>> $samlalias="") {
>>>>>>>>>>>>>   $packages = [
>>>>>>>>>>>>>     'httpd',
>>>>>>>>>>>>>     'openssl.x86_64',
>>>>>>>>>>>>>     'mod_ssl.x86_64',
>>>>>>>>>>>>>     'php',
>>>>>>>>>>>>>     'php-adodb.noarch',
>>>>>>>>>>>>>     'php-dba.x86_64',
>>>>>>>>>>>>>     'php-gd.x86_64',
>>>>>>>>>>>>>     'php-imap.x86_64',
>>>>>>>>>>>>>     'php-ldap.x86_64',
>>>>>>>>>>>>>     'php-mcrypt.x86_64',
>>>>>>>>>>>>>     'php-mysql.x86_64',
>>>>>>>>>>>>>     'php-pear.noarch',
>>>>>>>>>>>>>     'php-xml.x86_64',
>>>>>>>>>>>>>     'php-xmlrpc.x86_64',
>>>>>>>>>>>>>     'php.x86_64',
>>>>>>>>>>>>>     'git-all.noarch',
>>>>>>>>>>>>>     ]
>>>>>>>>>>>>>
>>>>>>>>>>>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>>>>>>>>>>>> #    ensure => present,
>>>>>>>>>>>>> #    source => 'puppet:///modules/php/90forceyes';
>>>>>>>>>>>>> #  }
>>>>>>>>>>>>>
>>>>>>>>>>>>> #  exec { 'update-apt':
>>>>>>>>>>>>> #    path    => ['/bin', '/usr/bin'],
>>>>>>>>>>>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>>>>>>>>>>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>>>>>>>>>>>> #  }
>>>>>>>>>>>>>
>>>>>>>>>>>>>   package { $packages:
>>>>>>>>>>>>>     ensure   => installed,
>>>>>>>>>>>>>   }
>>>>>>>>>>>>>
>>>>>>>>>>>>>   # Apache
>>>>>>>>>>>>>   file {
>>>>>>>>>>>>>     '/etc/httpd/conf/httpd.conf':
>>>>>>>>>>>>>       owner   => 'root',
>>>>>>>>>>>>>       group   => 'root',
>>>>>>>>>>>>>       mode    => '0775',
>>>>>>>>>>>>>       notify  => Service['httpd'],
>>>>>>>>>>>>>       content => template('php/httpd/httpd.conf.erb'),
>>>>>>>>>>>>>       require => Package['httpd'];
>>>>>>>>>>>>> #
>>>>>>>>>>>>> #    '/etc/apache2/sites-available/default':
>>>>>>>>>>>>> #      owner   => 'root',
>>>>>>>>>>>>> #      group   => 'root',
>>>>>>>>>>>>> #      mode    => '0775',
>>>>>>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>>>>>>> #      content =>
>>>>>>>>>>>>> template('php/apache2/sites-available/default.erb'),
>>>>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>>>>> #
>>>>>>>>>>>>> #    '/etc/apache2/sites-available/default-ssl':
>>>>>>>>>>>>> #      owner   => 'root',
>>>>>>>>>>>>> #      group   => 'root',
>>>>>>>>>>>>> #      mode    => '0775',
>>>>>>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>>>>>>> #      content =>
>>>>>>>>>>>>> template('php/apache2/sites-available/default-ssl.erb'),
>>>>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>>>>>   }
>>>>>>>>>>>>>
>>>>>>>>>>>>> #  exec {
>>>>>>>>>>>>> #    'enable ssl module':
>>>>>>>>>>>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>>>>>>> #      command => 'a2enmod ssl',
>>>>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>>>>> #  }
>>>>>>>>>>>>>
>>>>>>>>>>>>>   service { 'httpd':
>>>>>>>>>>>>>     ensure    => running,
>>>>>>>>>>>>>     name      => 'httpd',
>>>>>>>>>>>>>     hasstatus => true,
>>>>>>>>>>>>>     pattern   => 'httpd',
>>>>>>>>>>>>>     require   => Package['httpd'];
>>>>>>>>>>>>>   }
>>>>>>>>>>>>>
>>>>>>>>>>>>>   exec { 'remove www contents':
>>>>>>>>>>>>>     path    => '/bin/',
>>>>>>>>>>>>>     command => "rm -rf /var/www/html/*",
>>>>>>>>>>>>>     require => Package['httpd'],
>>>>>>>>>>>>>   }
>>>>>>>>>>>>>
>>>>>>>>>>>>>   # Apache end
>>>>>>>>>>>>> #  exec { 'clone git repo':
>>>>>>>>>>>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>>>>>>> #    cwd      => '/var/www',
>>>>>>>>>>>>> #    command  => "git clone ${stratos_git_repo}",
>>>>>>>>>>>>> #    require  => [
>>>>>>>>>>>>> #      Package['git-all.noarch'],
>>>>>>>>>>>>> #      Package['httpd'],
>>>>>>>>>>>>> #    ]
>>>>>>>>>>>>> #  }
>>>>>>>>>>>>> }
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <
>>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> In your script, do you have "stratos_" string somewhere?
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <
>>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Hi Nirmal,
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Correct. I have a changed script to work with CentOS. Do you
>>>>>>>>>>>>>>> know which line calls this. Could not find :)
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> I think you might be using a different init.pp than
>>>>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <
>>>>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in
>>>>>>>>>>>>>>>>> place. May be my puppet master configurations are wrong.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Will look into it.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>>>>>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>>>>>>>>>>>> We need to remove the unnecessary files from puppet
>>>>>>>>>>>>>>>>>> modules.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Hi,
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>>>>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> [1]
>>>>>>>>>>>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>>>>>>>>>>>> [2]
>>>>>>>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>>>>>>>>>>>  --
>>>>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> --
>>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> --
>>>>>>>>>>>>> --
>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>
>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>
>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>
>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> --
>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>> Software Engineer,
>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>
>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>> linked-in:
>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Best Regards,
>>>>>>>>>> Nirmal
>>>>>>>>>>
>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>
>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> --
>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>> Software Engineer,
>>>>>>>>> Platform Technologies,
>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>
>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Best Regards,
>>>>>>>> Nirmal
>>>>>>>>
>>>>>>>> Nirmal Fernando.
>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>
>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Best Regards,
>>>>>>> Nirmal
>>>>>>>
>>>>>>> Nirmal Fernando.
>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>
>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> --
>>>>>> Lahiru Sandaruwan
>>>>>> Software Engineer,
>>>>>> Platform Technologies,
>>>>>> WSO2 Inc., http://wso2.com
>>>>>> lean.enterprise.middleware
>>>>>>
>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>> twitter: http://twitter.com/lahirus
>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>> Nirmal
>>>>>
>>>>> Nirmal Fernando.
>>>>> PPMC Member & Committer of Apache Stratos,
>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>
>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> --
>>>> Lahiru Sandaruwan
>>>> Software Engineer,
>>>> Platform Technologies,
>>>> WSO2 Inc., http://wso2.com
>>>> lean.enterprise.middleware
>>>>
>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>> blog: http://lahiruwrites.blogspot.com/
>>>> twitter: http://twitter.com/lahirus
>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>
>>>>
>>>
>>>
>>> --
>>> *Dinesh Bandara*
>>> Software Engineer
>>> WSO2 Inc.; http://wso2.com
>>> lean.enterprise.middleware
>>>
>>>
>>
>>
>> --
>> --
>> Lahiru Sandaruwan
>> Software Engineer,
>> Platform Technologies,
>> WSO2 Inc., http://wso2.com
>> lean.enterprise.middleware
>>
>> email: lahirus@wso2.com cell: (+94) 773 325 954
>> blog: http://lahiruwrites.blogspot.com/
>> twitter: http://twitter.com/lahirus
>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>
>>
>
>
> --
> --
> Lahiru Sandaruwan
> Software Engineer,
> Platform Technologies,
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> email: lahirus@wso2.com cell: (+94) 773 325 954
> blog: http://lahiruwrites.blogspot.com/
> twitter: http://twitter.com/lahirus
> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>
>


-- 
*Dinesh Bandara*
Software Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Lahiru Sandaruwan <la...@wso2.com>.
On Wed, Apr 2, 2014 at 8:56 PM, Lahiru Sandaruwan <la...@wso2.com> wrote:

>
>
>
> On Wed, Apr 2, 2014 at 8:48 PM, Dinesh Bandara <di...@wso2.com> wrote:
>
>>
>> On Thu, Apr 3, 2014 at 9:15 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>
>>>
>>>
>>>
>>> On Wed, Apr 2, 2014 at 8:38 PM, Nirmal Fernando <ni...@gmail.com>wrote:
>>>
>>>> Dinesh is already on it (I think he started a discussion on it.).
>>>>
>>>
>>>  Great.
>>>
>>>>
>>>>
>>>> On Thu, Apr 3, 2014 at 9:06 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>
>>>>>
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 8:24 PM, Nirmal Fernando <
>>>>> nirmal070125@gmail.com> wrote:
>>>>>
>>>>>>
>>>>>> [Forwarding the bounced email]
>>>>>>
>>>>>> On Thu, Apr 3, 2014 at 8:51 AM, Nirmal Fernando <
>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>
>>>>>>> puppetinstall is called by the config script
>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/config.sh;h=3347b805bc0841325ddf251b19572dfe1cc58394;hb=HEAD
>>>>>>>
>>>>>>> and puppetinstall file copies the stratos_sendinfo.rb.
>>>>>>>
>>>>>>>
>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/puppetinstall/puppetinstall;h=214edb3d6a79867ecec7e1e94e73a57d55e760a6;hb=HEAD
>>>>>>>
>>>>>>> Aren't you following the wiki document? :-)
>>>>>>>
>>>>>>
>>>>> Nope. :) wiki document configuration is for creating a specific
>>>>> cartridge image. I'm using a general image. I thought init.sh verifies all
>>>>> the requirements as it has all the information from payload passed.
>>>>>
>>>>> Actually it is not the case and we can improve it.
>>>>>
>>>>> Generic image is a valid use case and we have to prepare resources and
>>>>> create a guide for that.
>>>>>
>>>>
>> I will add a note on wiki. simply we need to provide 'default' as the
>> service name when running the config script then it will install puppet
>> agent, java, cartridge agent which are required to create a generic image
>>
>
> ah.. just the information i needed. :D
> I was going to do it manually.
>


One question.

If we change the puppet master after creating the base image, will it break
the cartridge instance initialization?

>
> Thanks Dinesh.
>
>>
>>
>>
>>>
>>>>>>>
>>>>>>> On Thu, Apr 3, 2014 at 4:52 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>>>
>>>>>>>> puppetinstall script is not call by any script. init-vcloud.sh
>>>>>>>> seems to be having that. Seems the scripts are broken somewhere. So
>>>>>>>> stratos_sendinfo.rb is not placed correctly.
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Apr 2, 2014 at 9:46 AM, Nirmal Fernando <
>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>
>>>>>>>>> Ah.. Please change
>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD
>>>>>>>>>
>>>>>>>>> to use
>>>>>>>>>
>>>>>>>>> stratos_instance_data_
>>>>>>>>>
>>>>>>>>> instead of stratos_
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <
>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>
>>>>>>>>>> Issue was not adding correct parameters to
>>>>>>>>>> "/etc/httpd/conf/httpd.conf". Because "<%= @stratos_host_name
>>>>>>>>>> %>" was not exported since this script was not run.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <
>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>
>>>>>>>>>>> Ok, can you send the issue you saw?
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <
>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> It seems not. I'm using a script used by Manula for some other
>>>>>>>>>>>> deployment. But i cannot find that string in original one either...
>>>>>>>>>>>> Here is the complete script i'm using,
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> class php ($syslog="", $docroot="/var/www/html", $samlalias="")
>>>>>>>>>>>> {
>>>>>>>>>>>>   $packages = [
>>>>>>>>>>>>     'httpd',
>>>>>>>>>>>>     'openssl.x86_64',
>>>>>>>>>>>>     'mod_ssl.x86_64',
>>>>>>>>>>>>     'php',
>>>>>>>>>>>>     'php-adodb.noarch',
>>>>>>>>>>>>     'php-dba.x86_64',
>>>>>>>>>>>>     'php-gd.x86_64',
>>>>>>>>>>>>     'php-imap.x86_64',
>>>>>>>>>>>>     'php-ldap.x86_64',
>>>>>>>>>>>>     'php-mcrypt.x86_64',
>>>>>>>>>>>>     'php-mysql.x86_64',
>>>>>>>>>>>>     'php-pear.noarch',
>>>>>>>>>>>>     'php-xml.x86_64',
>>>>>>>>>>>>     'php-xmlrpc.x86_64',
>>>>>>>>>>>>     'php.x86_64',
>>>>>>>>>>>>     'git-all.noarch',
>>>>>>>>>>>>     ]
>>>>>>>>>>>>
>>>>>>>>>>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>>>>>>>>>>> #    ensure => present,
>>>>>>>>>>>> #    source => 'puppet:///modules/php/90forceyes';
>>>>>>>>>>>> #  }
>>>>>>>>>>>>
>>>>>>>>>>>> #  exec { 'update-apt':
>>>>>>>>>>>> #    path    => ['/bin', '/usr/bin'],
>>>>>>>>>>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>>>>>>>>>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>>>>>>>>>>> #  }
>>>>>>>>>>>>
>>>>>>>>>>>>   package { $packages:
>>>>>>>>>>>>     ensure   => installed,
>>>>>>>>>>>>   }
>>>>>>>>>>>>
>>>>>>>>>>>>   # Apache
>>>>>>>>>>>>   file {
>>>>>>>>>>>>     '/etc/httpd/conf/httpd.conf':
>>>>>>>>>>>>       owner   => 'root',
>>>>>>>>>>>>       group   => 'root',
>>>>>>>>>>>>       mode    => '0775',
>>>>>>>>>>>>       notify  => Service['httpd'],
>>>>>>>>>>>>       content => template('php/httpd/httpd.conf.erb'),
>>>>>>>>>>>>       require => Package['httpd'];
>>>>>>>>>>>> #
>>>>>>>>>>>> #    '/etc/apache2/sites-available/default':
>>>>>>>>>>>> #      owner   => 'root',
>>>>>>>>>>>> #      group   => 'root',
>>>>>>>>>>>> #      mode    => '0775',
>>>>>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>>>>>> #      content =>
>>>>>>>>>>>> template('php/apache2/sites-available/default.erb'),
>>>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>>>> #
>>>>>>>>>>>> #    '/etc/apache2/sites-available/default-ssl':
>>>>>>>>>>>> #      owner   => 'root',
>>>>>>>>>>>> #      group   => 'root',
>>>>>>>>>>>> #      mode    => '0775',
>>>>>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>>>>>> #      content =>
>>>>>>>>>>>> template('php/apache2/sites-available/default-ssl.erb'),
>>>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>>>>   }
>>>>>>>>>>>>
>>>>>>>>>>>> #  exec {
>>>>>>>>>>>> #    'enable ssl module':
>>>>>>>>>>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>>>>>> #      command => 'a2enmod ssl',
>>>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>>>> #  }
>>>>>>>>>>>>
>>>>>>>>>>>>   service { 'httpd':
>>>>>>>>>>>>     ensure    => running,
>>>>>>>>>>>>     name      => 'httpd',
>>>>>>>>>>>>     hasstatus => true,
>>>>>>>>>>>>     pattern   => 'httpd',
>>>>>>>>>>>>     require   => Package['httpd'];
>>>>>>>>>>>>   }
>>>>>>>>>>>>
>>>>>>>>>>>>   exec { 'remove www contents':
>>>>>>>>>>>>     path    => '/bin/',
>>>>>>>>>>>>     command => "rm -rf /var/www/html/*",
>>>>>>>>>>>>     require => Package['httpd'],
>>>>>>>>>>>>   }
>>>>>>>>>>>>
>>>>>>>>>>>>   # Apache end
>>>>>>>>>>>> #  exec { 'clone git repo':
>>>>>>>>>>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>>>>>> #    cwd      => '/var/www',
>>>>>>>>>>>> #    command  => "git clone ${stratos_git_repo}",
>>>>>>>>>>>> #    require  => [
>>>>>>>>>>>> #      Package['git-all.noarch'],
>>>>>>>>>>>> #      Package['httpd'],
>>>>>>>>>>>> #    ]
>>>>>>>>>>>> #  }
>>>>>>>>>>>> }
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <
>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> In your script, do you have "stratos_" string somewhere?
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <
>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Hi Nirmal,
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Correct. I have a changed script to work with CentOS. Do you
>>>>>>>>>>>>>> know which line calls this. Could not find :)
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> I think you might be using a different init.pp than
>>>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <
>>>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in
>>>>>>>>>>>>>>>> place. May be my puppet master configurations are wrong.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Will look into it.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>>>>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>>>>>>>>>>> We need to remove the unnecessary files from puppet
>>>>>>>>>>>>>>>>> modules.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Hi,
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>>>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> [1]
>>>>>>>>>>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>>>>>>>>>>> [2]
>>>>>>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>>>>>>>>>>  --
>>>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> --
>>>>>>>>>>>>>> --
>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> --
>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>
>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> --
>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>
>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>> linked-in:
>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Best Regards,
>>>>>>>>>>> Nirmal
>>>>>>>>>>>
>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>
>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> --
>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>> Software Engineer,
>>>>>>>>>> Platform Technologies,
>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>
>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>> linked-in:
>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Best Regards,
>>>>>>>>> Nirmal
>>>>>>>>>
>>>>>>>>> Nirmal Fernando.
>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>
>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> --
>>>>>>>> Lahiru Sandaruwan
>>>>>>>> Software Engineer,
>>>>>>>> Platform Technologies,
>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>> lean.enterprise.middleware
>>>>>>>>
>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Best Regards,
>>>>>>> Nirmal
>>>>>>>
>>>>>>> Nirmal Fernando.
>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>
>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Best Regards,
>>>>>> Nirmal
>>>>>>
>>>>>> Nirmal Fernando.
>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>
>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> --
>>>>> Lahiru Sandaruwan
>>>>> Software Engineer,
>>>>> Platform Technologies,
>>>>> WSO2 Inc., http://wso2.com
>>>>> lean.enterprise.middleware
>>>>>
>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>> twitter: http://twitter.com/lahirus
>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Best Regards,
>>>> Nirmal
>>>>
>>>> Nirmal Fernando.
>>>> PPMC Member & Committer of Apache Stratos,
>>>> Senior Software Engineer, WSO2 Inc.
>>>>
>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>
>>>
>>>
>>>
>>> --
>>> --
>>> Lahiru Sandaruwan
>>> Software Engineer,
>>> Platform Technologies,
>>> WSO2 Inc., http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>> blog: http://lahiruwrites.blogspot.com/
>>> twitter: http://twitter.com/lahirus
>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>
>>>
>>
>>
>> --
>> *Dinesh Bandara*
>> Software Engineer
>> WSO2 Inc.; http://wso2.com
>> lean.enterprise.middleware
>>
>>
>
>
> --
> --
> Lahiru Sandaruwan
> Software Engineer,
> Platform Technologies,
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> email: lahirus@wso2.com cell: (+94) 773 325 954
> blog: http://lahiruwrites.blogspot.com/
> twitter: http://twitter.com/lahirus
> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>
>


-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Lahiru Sandaruwan <la...@wso2.com>.
On Wed, Apr 2, 2014 at 8:48 PM, Dinesh Bandara <di...@wso2.com> wrote:

>
> On Thu, Apr 3, 2014 at 9:15 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>
>>
>>
>>
>> On Wed, Apr 2, 2014 at 8:38 PM, Nirmal Fernando <ni...@gmail.com>wrote:
>>
>>> Dinesh is already on it (I think he started a discussion on it.).
>>>
>>
>>  Great.
>>
>>>
>>>
>>> On Thu, Apr 3, 2014 at 9:06 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>
>>>>
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 8:24 PM, Nirmal Fernando <nirmal070125@gmail.com
>>>> > wrote:
>>>>
>>>>>
>>>>> [Forwarding the bounced email]
>>>>>
>>>>> On Thu, Apr 3, 2014 at 8:51 AM, Nirmal Fernando <
>>>>> nirmal070125@gmail.com> wrote:
>>>>>
>>>>>> puppetinstall is called by the config script
>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/config.sh;h=3347b805bc0841325ddf251b19572dfe1cc58394;hb=HEAD
>>>>>>
>>>>>> and puppetinstall file copies the stratos_sendinfo.rb.
>>>>>>
>>>>>>
>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/puppetinstall/puppetinstall;h=214edb3d6a79867ecec7e1e94e73a57d55e760a6;hb=HEAD
>>>>>>
>>>>>> Aren't you following the wiki document? :-)
>>>>>>
>>>>>
>>>> Nope. :) wiki document configuration is for creating a specific
>>>> cartridge image. I'm using a general image. I thought init.sh verifies all
>>>> the requirements as it has all the information from payload passed.
>>>>
>>>> Actually it is not the case and we can improve it.
>>>>
>>>> Generic image is a valid use case and we have to prepare resources and
>>>> create a guide for that.
>>>>
>>>
> I will add a note on wiki. simply we need to provide 'default' as the
> service name when running the config script then it will install puppet
> agent, java, cartridge agent which are required to create a generic image
>

ah.. just the information i needed. :D
I was going to do it manually.

Thanks Dinesh.

>
>
>
>>
>>>>>>
>>>>>> On Thu, Apr 3, 2014 at 4:52 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>>
>>>>>>> puppetinstall script is not call by any script. init-vcloud.sh seems
>>>>>>> to be having that. Seems the scripts are broken somewhere. So
>>>>>>> stratos_sendinfo.rb is not placed correctly.
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Apr 2, 2014 at 9:46 AM, Nirmal Fernando <
>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>
>>>>>>>> Ah.. Please change
>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD
>>>>>>>>
>>>>>>>> to use
>>>>>>>>
>>>>>>>> stratos_instance_data_
>>>>>>>>
>>>>>>>> instead of stratos_
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <
>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>
>>>>>>>>> Issue was not adding correct parameters to
>>>>>>>>> "/etc/httpd/conf/httpd.conf". Because "<%= @stratos_host_name %>" was
>>>>>>>>> not exported since this script was not run.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <
>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>
>>>>>>>>>> Ok, can you send the issue you saw?
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <
>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>
>>>>>>>>>>> It seems not. I'm using a script used by Manula for some other
>>>>>>>>>>> deployment. But i cannot find that string in original one either...
>>>>>>>>>>> Here is the complete script i'm using,
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>>>>>>>>>>>   $packages = [
>>>>>>>>>>>     'httpd',
>>>>>>>>>>>     'openssl.x86_64',
>>>>>>>>>>>     'mod_ssl.x86_64',
>>>>>>>>>>>     'php',
>>>>>>>>>>>     'php-adodb.noarch',
>>>>>>>>>>>     'php-dba.x86_64',
>>>>>>>>>>>     'php-gd.x86_64',
>>>>>>>>>>>     'php-imap.x86_64',
>>>>>>>>>>>     'php-ldap.x86_64',
>>>>>>>>>>>     'php-mcrypt.x86_64',
>>>>>>>>>>>     'php-mysql.x86_64',
>>>>>>>>>>>     'php-pear.noarch',
>>>>>>>>>>>     'php-xml.x86_64',
>>>>>>>>>>>     'php-xmlrpc.x86_64',
>>>>>>>>>>>     'php.x86_64',
>>>>>>>>>>>     'git-all.noarch',
>>>>>>>>>>>     ]
>>>>>>>>>>>
>>>>>>>>>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>>>>>>>>>> #    ensure => present,
>>>>>>>>>>> #    source => 'puppet:///modules/php/90forceyes';
>>>>>>>>>>> #  }
>>>>>>>>>>>
>>>>>>>>>>> #  exec { 'update-apt':
>>>>>>>>>>> #    path    => ['/bin', '/usr/bin'],
>>>>>>>>>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>>>>>>>>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>>>>>>>>>> #  }
>>>>>>>>>>>
>>>>>>>>>>>   package { $packages:
>>>>>>>>>>>     ensure   => installed,
>>>>>>>>>>>   }
>>>>>>>>>>>
>>>>>>>>>>>   # Apache
>>>>>>>>>>>   file {
>>>>>>>>>>>     '/etc/httpd/conf/httpd.conf':
>>>>>>>>>>>       owner   => 'root',
>>>>>>>>>>>       group   => 'root',
>>>>>>>>>>>       mode    => '0775',
>>>>>>>>>>>       notify  => Service['httpd'],
>>>>>>>>>>>       content => template('php/httpd/httpd.conf.erb'),
>>>>>>>>>>>       require => Package['httpd'];
>>>>>>>>>>> #
>>>>>>>>>>> #    '/etc/apache2/sites-available/default':
>>>>>>>>>>> #      owner   => 'root',
>>>>>>>>>>> #      group   => 'root',
>>>>>>>>>>> #      mode    => '0775',
>>>>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>>>>> #      content =>
>>>>>>>>>>> template('php/apache2/sites-available/default.erb'),
>>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>>> #
>>>>>>>>>>> #    '/etc/apache2/sites-available/default-ssl':
>>>>>>>>>>> #      owner   => 'root',
>>>>>>>>>>> #      group   => 'root',
>>>>>>>>>>> #      mode    => '0775',
>>>>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>>>>> #      content =>
>>>>>>>>>>> template('php/apache2/sites-available/default-ssl.erb'),
>>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>>>   }
>>>>>>>>>>>
>>>>>>>>>>> #  exec {
>>>>>>>>>>> #    'enable ssl module':
>>>>>>>>>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>>>>> #      command => 'a2enmod ssl',
>>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>>> #  }
>>>>>>>>>>>
>>>>>>>>>>>   service { 'httpd':
>>>>>>>>>>>     ensure    => running,
>>>>>>>>>>>     name      => 'httpd',
>>>>>>>>>>>     hasstatus => true,
>>>>>>>>>>>     pattern   => 'httpd',
>>>>>>>>>>>     require   => Package['httpd'];
>>>>>>>>>>>   }
>>>>>>>>>>>
>>>>>>>>>>>   exec { 'remove www contents':
>>>>>>>>>>>     path    => '/bin/',
>>>>>>>>>>>     command => "rm -rf /var/www/html/*",
>>>>>>>>>>>     require => Package['httpd'],
>>>>>>>>>>>   }
>>>>>>>>>>>
>>>>>>>>>>>   # Apache end
>>>>>>>>>>> #  exec { 'clone git repo':
>>>>>>>>>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>>>>> #    cwd      => '/var/www',
>>>>>>>>>>> #    command  => "git clone ${stratos_git_repo}",
>>>>>>>>>>> #    require  => [
>>>>>>>>>>> #      Package['git-all.noarch'],
>>>>>>>>>>> #      Package['httpd'],
>>>>>>>>>>> #    ]
>>>>>>>>>>> #  }
>>>>>>>>>>> }
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <
>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> In your script, do you have "stratos_" string somewhere?
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <
>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> Hi Nirmal,
>>>>>>>>>>>>>
>>>>>>>>>>>>> Correct. I have a changed script to work with CentOS. Do you
>>>>>>>>>>>>> know which line calls this. Could not find :)
>>>>>>>>>>>>>
>>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> I think you might be using a different init.pp than
>>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <
>>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in place.
>>>>>>>>>>>>>>> May be my puppet master configurations are wrong.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Will look into it.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>>>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>>>>>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Hi,
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> [1]
>>>>>>>>>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>>>>>>>>>> [2]
>>>>>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>>>>>>>>>  --
>>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> --
>>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> --
>>>>>>>>>>>>> --
>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>
>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>
>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>
>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> --
>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>> Software Engineer,
>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>
>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>> linked-in:
>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Best Regards,
>>>>>>>>>> Nirmal
>>>>>>>>>>
>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>
>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> --
>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>> Software Engineer,
>>>>>>>>> Platform Technologies,
>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>
>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Best Regards,
>>>>>>>> Nirmal
>>>>>>>>
>>>>>>>> Nirmal Fernando.
>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>
>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> --
>>>>>>> Lahiru Sandaruwan
>>>>>>> Software Engineer,
>>>>>>> Platform Technologies,
>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>> lean.enterprise.middleware
>>>>>>>
>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Best Regards,
>>>>>> Nirmal
>>>>>>
>>>>>> Nirmal Fernando.
>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>
>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>> Nirmal
>>>>>
>>>>> Nirmal Fernando.
>>>>> PPMC Member & Committer of Apache Stratos,
>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>
>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> --
>>>> Lahiru Sandaruwan
>>>> Software Engineer,
>>>> Platform Technologies,
>>>> WSO2 Inc., http://wso2.com
>>>> lean.enterprise.middleware
>>>>
>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>> blog: http://lahiruwrites.blogspot.com/
>>>> twitter: http://twitter.com/lahirus
>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>
>>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> --
>> Lahiru Sandaruwan
>> Software Engineer,
>> Platform Technologies,
>> WSO2 Inc., http://wso2.com
>> lean.enterprise.middleware
>>
>> email: lahirus@wso2.com cell: (+94) 773 325 954
>> blog: http://lahiruwrites.blogspot.com/
>> twitter: http://twitter.com/lahirus
>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>
>>
>
>
> --
> *Dinesh Bandara*
> Software Engineer
> WSO2 Inc.; http://wso2.com
> lean.enterprise.middleware
>
>


-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Dinesh Bandara <di...@wso2.com>.
On Thu, Apr 3, 2014 at 9:15 AM, Lahiru Sandaruwan <la...@wso2.com> wrote:

>
>
>
> On Wed, Apr 2, 2014 at 8:38 PM, Nirmal Fernando <ni...@gmail.com>wrote:
>
>> Dinesh is already on it (I think he started a discussion on it.).
>>
>
>  Great.
>
>>
>>
>> On Thu, Apr 3, 2014 at 9:06 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>
>>>
>>>
>>>
>>> On Wed, Apr 2, 2014 at 8:24 PM, Nirmal Fernando <ni...@gmail.com>wrote:
>>>
>>>>
>>>> [Forwarding the bounced email]
>>>>
>>>> On Thu, Apr 3, 2014 at 8:51 AM, Nirmal Fernando <nirmal070125@gmail.com
>>>> > wrote:
>>>>
>>>>> puppetinstall is called by the config script
>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/config.sh;h=3347b805bc0841325ddf251b19572dfe1cc58394;hb=HEAD
>>>>>
>>>>> and puppetinstall file copies the stratos_sendinfo.rb.
>>>>>
>>>>>
>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/puppetinstall/puppetinstall;h=214edb3d6a79867ecec7e1e94e73a57d55e760a6;hb=HEAD
>>>>>
>>>>> Aren't you following the wiki document? :-)
>>>>>
>>>>
>>> Nope. :) wiki document configuration is for creating a specific
>>> cartridge image. I'm using a general image. I thought init.sh verifies all
>>> the requirements as it has all the information from payload passed.
>>>
>>> Actually it is not the case and we can improve it.
>>>
>>> Generic image is a valid use case and we have to prepare resources and
>>> create a guide for that.
>>>
>>
I will add a note on wiki. simply we need to provide 'default' as the
service name when running the config script then it will install puppet
agent, java, cartridge agent which are required to create a generic image



>
>>>>>
>>>>> On Thu, Apr 3, 2014 at 4:52 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>
>>>>>> puppetinstall script is not call by any script. init-vcloud.sh seems
>>>>>> to be having that. Seems the scripts are broken somewhere. So
>>>>>> stratos_sendinfo.rb is not placed correctly.
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 9:46 AM, Nirmal Fernando <
>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>
>>>>>>> Ah.. Please change
>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD
>>>>>>>
>>>>>>> to use
>>>>>>>
>>>>>>> stratos_instance_data_
>>>>>>>
>>>>>>> instead of stratos_
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <lahirus@wso2.com
>>>>>>> > wrote:
>>>>>>>
>>>>>>>> Issue was not adding correct parameters to
>>>>>>>> "/etc/httpd/conf/httpd.conf". Because "<%= @stratos_host_name %>" was
>>>>>>>> not exported since this script was not run.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <
>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>
>>>>>>>>> Ok, can you send the issue you saw?
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <
>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>
>>>>>>>>>> It seems not. I'm using a script used by Manula for some other
>>>>>>>>>> deployment. But i cannot find that string in original one either...
>>>>>>>>>> Here is the complete script i'm using,
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>>>>>>>>>>   $packages = [
>>>>>>>>>>     'httpd',
>>>>>>>>>>     'openssl.x86_64',
>>>>>>>>>>     'mod_ssl.x86_64',
>>>>>>>>>>     'php',
>>>>>>>>>>     'php-adodb.noarch',
>>>>>>>>>>     'php-dba.x86_64',
>>>>>>>>>>     'php-gd.x86_64',
>>>>>>>>>>     'php-imap.x86_64',
>>>>>>>>>>     'php-ldap.x86_64',
>>>>>>>>>>     'php-mcrypt.x86_64',
>>>>>>>>>>     'php-mysql.x86_64',
>>>>>>>>>>     'php-pear.noarch',
>>>>>>>>>>     'php-xml.x86_64',
>>>>>>>>>>     'php-xmlrpc.x86_64',
>>>>>>>>>>     'php.x86_64',
>>>>>>>>>>     'git-all.noarch',
>>>>>>>>>>     ]
>>>>>>>>>>
>>>>>>>>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>>>>>>>>> #    ensure => present,
>>>>>>>>>> #    source => 'puppet:///modules/php/90forceyes';
>>>>>>>>>> #  }
>>>>>>>>>>
>>>>>>>>>> #  exec { 'update-apt':
>>>>>>>>>> #    path    => ['/bin', '/usr/bin'],
>>>>>>>>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>>>>>>>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>>>>>>>>> #  }
>>>>>>>>>>
>>>>>>>>>>   package { $packages:
>>>>>>>>>>     ensure   => installed,
>>>>>>>>>>   }
>>>>>>>>>>
>>>>>>>>>>   # Apache
>>>>>>>>>>   file {
>>>>>>>>>>     '/etc/httpd/conf/httpd.conf':
>>>>>>>>>>       owner   => 'root',
>>>>>>>>>>       group   => 'root',
>>>>>>>>>>       mode    => '0775',
>>>>>>>>>>       notify  => Service['httpd'],
>>>>>>>>>>       content => template('php/httpd/httpd.conf.erb'),
>>>>>>>>>>       require => Package['httpd'];
>>>>>>>>>> #
>>>>>>>>>> #    '/etc/apache2/sites-available/default':
>>>>>>>>>> #      owner   => 'root',
>>>>>>>>>> #      group   => 'root',
>>>>>>>>>> #      mode    => '0775',
>>>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>>>> #      content =>
>>>>>>>>>> template('php/apache2/sites-available/default.erb'),
>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>> #
>>>>>>>>>> #    '/etc/apache2/sites-available/default-ssl':
>>>>>>>>>> #      owner   => 'root',
>>>>>>>>>> #      group   => 'root',
>>>>>>>>>> #      mode    => '0775',
>>>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>>>> #      content =>
>>>>>>>>>> template('php/apache2/sites-available/default-ssl.erb'),
>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>>   }
>>>>>>>>>>
>>>>>>>>>> #  exec {
>>>>>>>>>> #    'enable ssl module':
>>>>>>>>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>>>> #      command => 'a2enmod ssl',
>>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>> #  }
>>>>>>>>>>
>>>>>>>>>>   service { 'httpd':
>>>>>>>>>>     ensure    => running,
>>>>>>>>>>     name      => 'httpd',
>>>>>>>>>>     hasstatus => true,
>>>>>>>>>>     pattern   => 'httpd',
>>>>>>>>>>     require   => Package['httpd'];
>>>>>>>>>>   }
>>>>>>>>>>
>>>>>>>>>>   exec { 'remove www contents':
>>>>>>>>>>     path    => '/bin/',
>>>>>>>>>>     command => "rm -rf /var/www/html/*",
>>>>>>>>>>     require => Package['httpd'],
>>>>>>>>>>   }
>>>>>>>>>>
>>>>>>>>>>   # Apache end
>>>>>>>>>> #  exec { 'clone git repo':
>>>>>>>>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>>>> #    cwd      => '/var/www',
>>>>>>>>>> #    command  => "git clone ${stratos_git_repo}",
>>>>>>>>>> #    require  => [
>>>>>>>>>> #      Package['git-all.noarch'],
>>>>>>>>>> #      Package['httpd'],
>>>>>>>>>> #    ]
>>>>>>>>>> #  }
>>>>>>>>>> }
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <
>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>
>>>>>>>>>>> In your script, do you have "stratos_" string somewhere?
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <
>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Hi Nirmal,
>>>>>>>>>>>>
>>>>>>>>>>>> Correct. I have a changed script to work with CentOS. Do you
>>>>>>>>>>>> know which line calls this. Could not find :)
>>>>>>>>>>>>
>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>>
>>>>>>>>>>>>> I think you might be using a different init.pp than
>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <
>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in place.
>>>>>>>>>>>>>> May be my puppet master configurations are wrong.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Will look into it.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>>>>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Hi,
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> [1]
>>>>>>>>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>>>>>>>>> [2]
>>>>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>>>>>>>>  --
>>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> --
>>>>>>>>>>>>>> --
>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> --
>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>
>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> --
>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>
>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>> linked-in:
>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Best Regards,
>>>>>>>>>>> Nirmal
>>>>>>>>>>>
>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>
>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> --
>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>> Software Engineer,
>>>>>>>>>> Platform Technologies,
>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>
>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>> linked-in:
>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Best Regards,
>>>>>>>>> Nirmal
>>>>>>>>>
>>>>>>>>> Nirmal Fernando.
>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>
>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> --
>>>>>>>> Lahiru Sandaruwan
>>>>>>>> Software Engineer,
>>>>>>>> Platform Technologies,
>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>> lean.enterprise.middleware
>>>>>>>>
>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Best Regards,
>>>>>>> Nirmal
>>>>>>>
>>>>>>> Nirmal Fernando.
>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>
>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> --
>>>>>> Lahiru Sandaruwan
>>>>>> Software Engineer,
>>>>>> Platform Technologies,
>>>>>> WSO2 Inc., http://wso2.com
>>>>>> lean.enterprise.middleware
>>>>>>
>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>> twitter: http://twitter.com/lahirus
>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>> Nirmal
>>>>>
>>>>> Nirmal Fernando.
>>>>> PPMC Member & Committer of Apache Stratos,
>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>
>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Best Regards,
>>>> Nirmal
>>>>
>>>> Nirmal Fernando.
>>>> PPMC Member & Committer of Apache Stratos,
>>>> Senior Software Engineer, WSO2 Inc.
>>>>
>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>
>>>
>>>
>>>
>>> --
>>> --
>>> Lahiru Sandaruwan
>>> Software Engineer,
>>> Platform Technologies,
>>> WSO2 Inc., http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>> blog: http://lahiruwrites.blogspot.com/
>>> twitter: http://twitter.com/lahirus
>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>
>>>
>>
>>
>> --
>> Best Regards,
>> Nirmal
>>
>> Nirmal Fernando.
>> PPMC Member & Committer of Apache Stratos,
>> Senior Software Engineer, WSO2 Inc.
>>
>> Blog: http://nirmalfdo.blogspot.com/
>>
>
>
>
> --
> --
> Lahiru Sandaruwan
> Software Engineer,
> Platform Technologies,
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> email: lahirus@wso2.com cell: (+94) 773 325 954
> blog: http://lahiruwrites.blogspot.com/
> twitter: http://twitter.com/lahirus
> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>
>


-- 
*Dinesh Bandara*
Software Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Lahiru Sandaruwan <la...@wso2.com>.
On Wed, Apr 2, 2014 at 8:38 PM, Nirmal Fernando <ni...@gmail.com>wrote:

> Dinesh is already on it (I think he started a discussion on it.).
>

Great.

>
>
> On Thu, Apr 3, 2014 at 9:06 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>
>>
>>
>>
>> On Wed, Apr 2, 2014 at 8:24 PM, Nirmal Fernando <ni...@gmail.com>wrote:
>>
>>>
>>> [Forwarding the bounced email]
>>>
>>> On Thu, Apr 3, 2014 at 8:51 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>>
>>>> puppetinstall is called by the config script
>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/config.sh;h=3347b805bc0841325ddf251b19572dfe1cc58394;hb=HEAD
>>>>
>>>> and puppetinstall file copies the stratos_sendinfo.rb.
>>>>
>>>>
>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/puppetinstall/puppetinstall;h=214edb3d6a79867ecec7e1e94e73a57d55e760a6;hb=HEAD
>>>>
>>>> Aren't you following the wiki document? :-)
>>>>
>>>
>> Nope. :) wiki document configuration is for creating a specific cartridge
>> image. I'm using a general image. I thought init.sh verifies all the
>> requirements as it has all the information from payload passed.
>>
>> Actually it is not the case and we can improve it.
>>
>> Generic image is a valid use case and we have to prepare resources and
>> create a guide for that.
>>
>>>
>>>>
>>>> On Thu, Apr 3, 2014 at 4:52 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>
>>>>> puppetinstall script is not call by any script. init-vcloud.sh seems
>>>>> to be having that. Seems the scripts are broken somewhere. So
>>>>> stratos_sendinfo.rb is not placed correctly.
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 9:46 AM, Nirmal Fernando <
>>>>> nirmal070125@gmail.com> wrote:
>>>>>
>>>>>> Ah.. Please change
>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD
>>>>>>
>>>>>> to use
>>>>>>
>>>>>> stratos_instance_data_
>>>>>>
>>>>>> instead of stratos_
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>>
>>>>>>> Issue was not adding correct parameters to
>>>>>>> "/etc/httpd/conf/httpd.conf". Because "<%= @stratos_host_name %>" was
>>>>>>> not exported since this script was not run.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <
>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>
>>>>>>>> Ok, can you send the issue you saw?
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <lahirus@wso2.com
>>>>>>>> > wrote:
>>>>>>>>
>>>>>>>>> It seems not. I'm using a script used by Manula for some other
>>>>>>>>> deployment. But i cannot find that string in original one either...
>>>>>>>>> Here is the complete script i'm using,
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>>>>>>>>>   $packages = [
>>>>>>>>>     'httpd',
>>>>>>>>>     'openssl.x86_64',
>>>>>>>>>     'mod_ssl.x86_64',
>>>>>>>>>     'php',
>>>>>>>>>     'php-adodb.noarch',
>>>>>>>>>     'php-dba.x86_64',
>>>>>>>>>     'php-gd.x86_64',
>>>>>>>>>     'php-imap.x86_64',
>>>>>>>>>     'php-ldap.x86_64',
>>>>>>>>>     'php-mcrypt.x86_64',
>>>>>>>>>     'php-mysql.x86_64',
>>>>>>>>>     'php-pear.noarch',
>>>>>>>>>     'php-xml.x86_64',
>>>>>>>>>     'php-xmlrpc.x86_64',
>>>>>>>>>     'php.x86_64',
>>>>>>>>>     'git-all.noarch',
>>>>>>>>>     ]
>>>>>>>>>
>>>>>>>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>>>>>>>> #    ensure => present,
>>>>>>>>> #    source => 'puppet:///modules/php/90forceyes';
>>>>>>>>> #  }
>>>>>>>>>
>>>>>>>>> #  exec { 'update-apt':
>>>>>>>>> #    path    => ['/bin', '/usr/bin'],
>>>>>>>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>>>>>>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>>>>>>>> #  }
>>>>>>>>>
>>>>>>>>>   package { $packages:
>>>>>>>>>     ensure   => installed,
>>>>>>>>>   }
>>>>>>>>>
>>>>>>>>>   # Apache
>>>>>>>>>   file {
>>>>>>>>>     '/etc/httpd/conf/httpd.conf':
>>>>>>>>>       owner   => 'root',
>>>>>>>>>       group   => 'root',
>>>>>>>>>       mode    => '0775',
>>>>>>>>>       notify  => Service['httpd'],
>>>>>>>>>       content => template('php/httpd/httpd.conf.erb'),
>>>>>>>>>       require => Package['httpd'];
>>>>>>>>> #
>>>>>>>>> #    '/etc/apache2/sites-available/default':
>>>>>>>>> #      owner   => 'root',
>>>>>>>>> #      group   => 'root',
>>>>>>>>> #      mode    => '0775',
>>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>>> #      content =>
>>>>>>>>> template('php/apache2/sites-available/default.erb'),
>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>> #
>>>>>>>>> #    '/etc/apache2/sites-available/default-ssl':
>>>>>>>>> #      owner   => 'root',
>>>>>>>>> #      group   => 'root',
>>>>>>>>> #      mode    => '0775',
>>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>>> #      content =>
>>>>>>>>> template('php/apache2/sites-available/default-ssl.erb'),
>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>>   }
>>>>>>>>>
>>>>>>>>> #  exec {
>>>>>>>>> #    'enable ssl module':
>>>>>>>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>>> #      command => 'a2enmod ssl',
>>>>>>>>> #      require => Package['apache2'];
>>>>>>>>> #  }
>>>>>>>>>
>>>>>>>>>   service { 'httpd':
>>>>>>>>>     ensure    => running,
>>>>>>>>>     name      => 'httpd',
>>>>>>>>>     hasstatus => true,
>>>>>>>>>     pattern   => 'httpd',
>>>>>>>>>     require   => Package['httpd'];
>>>>>>>>>   }
>>>>>>>>>
>>>>>>>>>   exec { 'remove www contents':
>>>>>>>>>     path    => '/bin/',
>>>>>>>>>     command => "rm -rf /var/www/html/*",
>>>>>>>>>     require => Package['httpd'],
>>>>>>>>>   }
>>>>>>>>>
>>>>>>>>>   # Apache end
>>>>>>>>> #  exec { 'clone git repo':
>>>>>>>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>>> #    cwd      => '/var/www',
>>>>>>>>> #    command  => "git clone ${stratos_git_repo}",
>>>>>>>>> #    require  => [
>>>>>>>>> #      Package['git-all.noarch'],
>>>>>>>>> #      Package['httpd'],
>>>>>>>>> #    ]
>>>>>>>>> #  }
>>>>>>>>> }
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <
>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>
>>>>>>>>>> In your script, do you have "stratos_" string somewhere?
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <
>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>
>>>>>>>>>>> Hi Nirmal,
>>>>>>>>>>>
>>>>>>>>>>> Correct. I have a changed script to work with CentOS. Do you
>>>>>>>>>>> know which line calls this. Could not find :)
>>>>>>>>>>>
>>>>>>>>>>> Thanks.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>
>>>>>>>>>>>> I think you might be using a different init.pp than
>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <
>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in place.
>>>>>>>>>>>>> May be my puppet master configurations are wrong.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Will look into it.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>>>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Hi,
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> [1]
>>>>>>>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>>>>>>>> [2]
>>>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>>>>>>>  --
>>>>>>>>>>>>>>> --
>>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> --
>>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> --
>>>>>>>>>>>>> --
>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>
>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>
>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>
>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> --
>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>> Software Engineer,
>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>
>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>> linked-in:
>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Best Regards,
>>>>>>>>>> Nirmal
>>>>>>>>>>
>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>
>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> --
>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>> Software Engineer,
>>>>>>>>> Platform Technologies,
>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>
>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Best Regards,
>>>>>>>> Nirmal
>>>>>>>>
>>>>>>>> Nirmal Fernando.
>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>
>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> --
>>>>>>> Lahiru Sandaruwan
>>>>>>> Software Engineer,
>>>>>>> Platform Technologies,
>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>> lean.enterprise.middleware
>>>>>>>
>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Best Regards,
>>>>>> Nirmal
>>>>>>
>>>>>> Nirmal Fernando.
>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>
>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> --
>>>>> Lahiru Sandaruwan
>>>>> Software Engineer,
>>>>> Platform Technologies,
>>>>> WSO2 Inc., http://wso2.com
>>>>> lean.enterprise.middleware
>>>>>
>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>> twitter: http://twitter.com/lahirus
>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Best Regards,
>>>> Nirmal
>>>>
>>>> Nirmal Fernando.
>>>> PPMC Member & Committer of Apache Stratos,
>>>> Senior Software Engineer, WSO2 Inc.
>>>>
>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>
>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> --
>> Lahiru Sandaruwan
>> Software Engineer,
>> Platform Technologies,
>> WSO2 Inc., http://wso2.com
>> lean.enterprise.middleware
>>
>> email: lahirus@wso2.com cell: (+94) 773 325 954
>> blog: http://lahiruwrites.blogspot.com/
>> twitter: http://twitter.com/lahirus
>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>
>>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Nirmal Fernando <ni...@gmail.com>.
Dinesh is already on it (I think he started a discussion on it.).


On Thu, Apr 3, 2014 at 9:06 AM, Lahiru Sandaruwan <la...@wso2.com> wrote:

>
>
>
> On Wed, Apr 2, 2014 at 8:24 PM, Nirmal Fernando <ni...@gmail.com>wrote:
>
>>
>> [Forwarding the bounced email]
>>
>> On Thu, Apr 3, 2014 at 8:51 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>
>>> puppetinstall is called by the config script
>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/config.sh;h=3347b805bc0841325ddf251b19572dfe1cc58394;hb=HEAD
>>>
>>> and puppetinstall file copies the stratos_sendinfo.rb.
>>>
>>>
>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/puppetinstall/puppetinstall;h=214edb3d6a79867ecec7e1e94e73a57d55e760a6;hb=HEAD
>>>
>>> Aren't you following the wiki document? :-)
>>>
>>
> Nope. :) wiki document configuration is for creating a specific cartridge
> image. I'm using a general image. I thought init.sh verifies all the
> requirements as it has all the information from payload passed.
>
> Actually it is not the case and we can improve it.
>
> Generic image is a valid use case and we have to prepare resources and
> create a guide for that.
>
>>
>>>
>>> On Thu, Apr 3, 2014 at 4:52 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>
>>>> puppetinstall script is not call by any script. init-vcloud.sh seems to
>>>> be having that. Seems the scripts are broken somewhere. So
>>>> stratos_sendinfo.rb is not placed correctly.
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 9:46 AM, Nirmal Fernando <nirmal070125@gmail.com
>>>> > wrote:
>>>>
>>>>> Ah.. Please change
>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD
>>>>>
>>>>> to use
>>>>>
>>>>> stratos_instance_data_
>>>>>
>>>>> instead of stratos_
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>
>>>>>> Issue was not adding correct parameters to
>>>>>> "/etc/httpd/conf/httpd.conf". Because "<%= @stratos_host_name %>" was
>>>>>> not exported since this script was not run.
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <
>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>
>>>>>>> Ok, can you send the issue you saw?
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>>>
>>>>>>>> It seems not. I'm using a script used by Manula for some other
>>>>>>>> deployment. But i cannot find that string in original one either...
>>>>>>>> Here is the complete script i'm using,
>>>>>>>>
>>>>>>>>
>>>>>>>> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>>>>>>>>   $packages = [
>>>>>>>>     'httpd',
>>>>>>>>     'openssl.x86_64',
>>>>>>>>     'mod_ssl.x86_64',
>>>>>>>>     'php',
>>>>>>>>     'php-adodb.noarch',
>>>>>>>>     'php-dba.x86_64',
>>>>>>>>     'php-gd.x86_64',
>>>>>>>>     'php-imap.x86_64',
>>>>>>>>     'php-ldap.x86_64',
>>>>>>>>     'php-mcrypt.x86_64',
>>>>>>>>     'php-mysql.x86_64',
>>>>>>>>     'php-pear.noarch',
>>>>>>>>     'php-xml.x86_64',
>>>>>>>>     'php-xmlrpc.x86_64',
>>>>>>>>     'php.x86_64',
>>>>>>>>     'git-all.noarch',
>>>>>>>>     ]
>>>>>>>>
>>>>>>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>>>>>>> #    ensure => present,
>>>>>>>> #    source => 'puppet:///modules/php/90forceyes';
>>>>>>>> #  }
>>>>>>>>
>>>>>>>> #  exec { 'update-apt':
>>>>>>>> #    path    => ['/bin', '/usr/bin'],
>>>>>>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>>>>>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>>>>>>> #  }
>>>>>>>>
>>>>>>>>   package { $packages:
>>>>>>>>     ensure   => installed,
>>>>>>>>   }
>>>>>>>>
>>>>>>>>   # Apache
>>>>>>>>   file {
>>>>>>>>     '/etc/httpd/conf/httpd.conf':
>>>>>>>>       owner   => 'root',
>>>>>>>>       group   => 'root',
>>>>>>>>       mode    => '0775',
>>>>>>>>       notify  => Service['httpd'],
>>>>>>>>       content => template('php/httpd/httpd.conf.erb'),
>>>>>>>>       require => Package['httpd'];
>>>>>>>> #
>>>>>>>> #    '/etc/apache2/sites-available/default':
>>>>>>>> #      owner   => 'root',
>>>>>>>> #      group   => 'root',
>>>>>>>> #      mode    => '0775',
>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>> #      content =>
>>>>>>>> template('php/apache2/sites-available/default.erb'),
>>>>>>>> #      require => Package['apache2'];
>>>>>>>> #
>>>>>>>> #    '/etc/apache2/sites-available/default-ssl':
>>>>>>>> #      owner   => 'root',
>>>>>>>> #      group   => 'root',
>>>>>>>> #      mode    => '0775',
>>>>>>>> #      notify  => Service['apache2'],
>>>>>>>> #      content =>
>>>>>>>> template('php/apache2/sites-available/default-ssl.erb'),
>>>>>>>> #      require => Package['apache2'];
>>>>>>>>   }
>>>>>>>>
>>>>>>>> #  exec {
>>>>>>>> #    'enable ssl module':
>>>>>>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>> #      command => 'a2enmod ssl',
>>>>>>>> #      require => Package['apache2'];
>>>>>>>> #  }
>>>>>>>>
>>>>>>>>   service { 'httpd':
>>>>>>>>     ensure    => running,
>>>>>>>>     name      => 'httpd',
>>>>>>>>     hasstatus => true,
>>>>>>>>     pattern   => 'httpd',
>>>>>>>>     require   => Package['httpd'];
>>>>>>>>   }
>>>>>>>>
>>>>>>>>   exec { 'remove www contents':
>>>>>>>>     path    => '/bin/',
>>>>>>>>     command => "rm -rf /var/www/html/*",
>>>>>>>>     require => Package['httpd'],
>>>>>>>>   }
>>>>>>>>
>>>>>>>>   # Apache end
>>>>>>>> #  exec { 'clone git repo':
>>>>>>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>>> #    cwd      => '/var/www',
>>>>>>>> #    command  => "git clone ${stratos_git_repo}",
>>>>>>>> #    require  => [
>>>>>>>> #      Package['git-all.noarch'],
>>>>>>>> #      Package['httpd'],
>>>>>>>> #    ]
>>>>>>>> #  }
>>>>>>>> }
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <
>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>
>>>>>>>>> In your script, do you have "stratos_" string somewhere?
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <
>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>
>>>>>>>>>> Hi Nirmal,
>>>>>>>>>>
>>>>>>>>>> Correct. I have a changed script to work with CentOS. Do you know
>>>>>>>>>> which line calls this. Could not find :)
>>>>>>>>>>
>>>>>>>>>> Thanks.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>
>>>>>>>>>>> Lahiru,
>>>>>>>>>>>
>>>>>>>>>>> I think you might be using a different init.pp than
>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <
>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in place.
>>>>>>>>>>>> May be my puppet master configurations are wrong.
>>>>>>>>>>>>
>>>>>>>>>>>> Will look into it.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>>
>>>>>>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>> Hi,
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> [1]
>>>>>>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>>>>>>> [2]
>>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>>>>>>  --
>>>>>>>>>>>>>> --
>>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>>
>>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>> --
>>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>>
>>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>>
>>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> --
>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>
>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>> linked-in:
>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Best Regards,
>>>>>>>>>>> Nirmal
>>>>>>>>>>>
>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>
>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> --
>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>> Software Engineer,
>>>>>>>>>> Platform Technologies,
>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>
>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>> linked-in:
>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Best Regards,
>>>>>>>>> Nirmal
>>>>>>>>>
>>>>>>>>> Nirmal Fernando.
>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>
>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> --
>>>>>>>> Lahiru Sandaruwan
>>>>>>>> Software Engineer,
>>>>>>>> Platform Technologies,
>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>> lean.enterprise.middleware
>>>>>>>>
>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Best Regards,
>>>>>>> Nirmal
>>>>>>>
>>>>>>> Nirmal Fernando.
>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>
>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> --
>>>>>> Lahiru Sandaruwan
>>>>>> Software Engineer,
>>>>>> Platform Technologies,
>>>>>> WSO2 Inc., http://wso2.com
>>>>>> lean.enterprise.middleware
>>>>>>
>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>> twitter: http://twitter.com/lahirus
>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>> Nirmal
>>>>>
>>>>> Nirmal Fernando.
>>>>> PPMC Member & Committer of Apache Stratos,
>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>
>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> --
>>>> Lahiru Sandaruwan
>>>> Software Engineer,
>>>> Platform Technologies,
>>>> WSO2 Inc., http://wso2.com
>>>> lean.enterprise.middleware
>>>>
>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>> blog: http://lahiruwrites.blogspot.com/
>>>> twitter: http://twitter.com/lahirus
>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>
>>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> Best Regards,
>> Nirmal
>>
>> Nirmal Fernando.
>> PPMC Member & Committer of Apache Stratos,
>> Senior Software Engineer, WSO2 Inc.
>>
>> Blog: http://nirmalfdo.blogspot.com/
>>
>
>
>
> --
> --
> Lahiru Sandaruwan
> Software Engineer,
> Platform Technologies,
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> email: lahirus@wso2.com cell: (+94) 773 325 954
> blog: http://lahiruwrites.blogspot.com/
> twitter: http://twitter.com/lahirus
> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>
>


-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Lahiru Sandaruwan <la...@wso2.com>.
On Wed, Apr 2, 2014 at 8:24 PM, Nirmal Fernando <ni...@gmail.com>wrote:

>
> [Forwarding the bounced email]
>
> On Thu, Apr 3, 2014 at 8:51 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>
>> puppetinstall is called by the config script
>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/config.sh;h=3347b805bc0841325ddf251b19572dfe1cc58394;hb=HEAD
>>
>> and puppetinstall file copies the stratos_sendinfo.rb.
>>
>>
>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/puppetinstall/puppetinstall;h=214edb3d6a79867ecec7e1e94e73a57d55e760a6;hb=HEAD
>>
>> Aren't you following the wiki document? :-)
>>
>
Nope. :) wiki document configuration is for creating a specific cartridge
image. I'm using a general image. I thought init.sh verifies all the
requirements as it has all the information from payload passed.

Actually it is not the case and we can improve it.

Generic image is a valid use case and we have to prepare resources and
create a guide for that.

>
>>
>> On Thu, Apr 3, 2014 at 4:52 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>
>>> puppetinstall script is not call by any script. init-vcloud.sh seems to
>>> be having that. Seems the scripts are broken somewhere. So
>>> stratos_sendinfo.rb is not placed correctly.
>>>
>>>
>>> On Wed, Apr 2, 2014 at 9:46 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>>
>>>> Ah.. Please change
>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD
>>>>
>>>> to use
>>>>
>>>> stratos_instance_data_
>>>>
>>>> instead of stratos_
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>
>>>>> Issue was not adding correct parameters to
>>>>> "/etc/httpd/conf/httpd.conf". Because "<%= @stratos_host_name %>" was
>>>>> not exported since this script was not run.
>>>>>
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <
>>>>> nirmal070125@gmail.com> wrote:
>>>>>
>>>>>> Ok, can you send the issue you saw?
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>>
>>>>>>> It seems not. I'm using a script used by Manula for some other
>>>>>>> deployment. But i cannot find that string in original one either...
>>>>>>> Here is the complete script i'm using,
>>>>>>>
>>>>>>>
>>>>>>> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>>>>>>>   $packages = [
>>>>>>>     'httpd',
>>>>>>>     'openssl.x86_64',
>>>>>>>     'mod_ssl.x86_64',
>>>>>>>     'php',
>>>>>>>     'php-adodb.noarch',
>>>>>>>     'php-dba.x86_64',
>>>>>>>     'php-gd.x86_64',
>>>>>>>     'php-imap.x86_64',
>>>>>>>     'php-ldap.x86_64',
>>>>>>>     'php-mcrypt.x86_64',
>>>>>>>     'php-mysql.x86_64',
>>>>>>>     'php-pear.noarch',
>>>>>>>     'php-xml.x86_64',
>>>>>>>     'php-xmlrpc.x86_64',
>>>>>>>     'php.x86_64',
>>>>>>>     'git-all.noarch',
>>>>>>>     ]
>>>>>>>
>>>>>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>>>>>> #    ensure => present,
>>>>>>> #    source => 'puppet:///modules/php/90forceyes';
>>>>>>> #  }
>>>>>>>
>>>>>>> #  exec { 'update-apt':
>>>>>>> #    path    => ['/bin', '/usr/bin'],
>>>>>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>>>>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>>>>>> #  }
>>>>>>>
>>>>>>>   package { $packages:
>>>>>>>     ensure   => installed,
>>>>>>>   }
>>>>>>>
>>>>>>>   # Apache
>>>>>>>   file {
>>>>>>>     '/etc/httpd/conf/httpd.conf':
>>>>>>>       owner   => 'root',
>>>>>>>       group   => 'root',
>>>>>>>       mode    => '0775',
>>>>>>>       notify  => Service['httpd'],
>>>>>>>       content => template('php/httpd/httpd.conf.erb'),
>>>>>>>       require => Package['httpd'];
>>>>>>> #
>>>>>>> #    '/etc/apache2/sites-available/default':
>>>>>>> #      owner   => 'root',
>>>>>>> #      group   => 'root',
>>>>>>> #      mode    => '0775',
>>>>>>> #      notify  => Service['apache2'],
>>>>>>> #      content =>
>>>>>>> template('php/apache2/sites-available/default.erb'),
>>>>>>> #      require => Package['apache2'];
>>>>>>> #
>>>>>>> #    '/etc/apache2/sites-available/default-ssl':
>>>>>>> #      owner   => 'root',
>>>>>>> #      group   => 'root',
>>>>>>> #      mode    => '0775',
>>>>>>> #      notify  => Service['apache2'],
>>>>>>> #      content =>
>>>>>>> template('php/apache2/sites-available/default-ssl.erb'),
>>>>>>> #      require => Package['apache2'];
>>>>>>>   }
>>>>>>>
>>>>>>> #  exec {
>>>>>>> #    'enable ssl module':
>>>>>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>> #      command => 'a2enmod ssl',
>>>>>>> #      require => Package['apache2'];
>>>>>>> #  }
>>>>>>>
>>>>>>>   service { 'httpd':
>>>>>>>     ensure    => running,
>>>>>>>     name      => 'httpd',
>>>>>>>     hasstatus => true,
>>>>>>>     pattern   => 'httpd',
>>>>>>>     require   => Package['httpd'];
>>>>>>>   }
>>>>>>>
>>>>>>>   exec { 'remove www contents':
>>>>>>>     path    => '/bin/',
>>>>>>>     command => "rm -rf /var/www/html/*",
>>>>>>>     require => Package['httpd'],
>>>>>>>   }
>>>>>>>
>>>>>>>   # Apache end
>>>>>>> #  exec { 'clone git repo':
>>>>>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>>> #    cwd      => '/var/www',
>>>>>>> #    command  => "git clone ${stratos_git_repo}",
>>>>>>> #    require  => [
>>>>>>> #      Package['git-all.noarch'],
>>>>>>> #      Package['httpd'],
>>>>>>> #    ]
>>>>>>> #  }
>>>>>>> }
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <
>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>
>>>>>>>> In your script, do you have "stratos_" string somewhere?
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <lahirus@wso2.com
>>>>>>>> > wrote:
>>>>>>>>
>>>>>>>>> Hi Nirmal,
>>>>>>>>>
>>>>>>>>> Correct. I have a changed script to work with CentOS. Do you know
>>>>>>>>> which line calls this. Could not find :)
>>>>>>>>>
>>>>>>>>> Thanks.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>
>>>>>>>>>> Lahiru,
>>>>>>>>>>
>>>>>>>>>> I think you might be using a different init.pp than
>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <
>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>
>>>>>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in place. May
>>>>>>>>>>> be my puppet master configurations are wrong.
>>>>>>>>>>>
>>>>>>>>>>> Will look into it.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Lahiru,
>>>>>>>>>>>>
>>>>>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>> Hi,
>>>>>>>>>>>>>
>>>>>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>>>>>
>>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>>
>>>>>>>>>>>>> [1]
>>>>>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>>>>>> [2]
>>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>>>>>  --
>>>>>>>>>>>>> --
>>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>>
>>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>>> linked-in:
>>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>>
>>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> --
>>>>>>>>>>>> Best Regards,
>>>>>>>>>>>> Nirmal
>>>>>>>>>>>>
>>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>>
>>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> --
>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>> Software Engineer,
>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>
>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>> linked-in:
>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> Best Regards,
>>>>>>>>>> Nirmal
>>>>>>>>>>
>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>
>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> --
>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>> Software Engineer,
>>>>>>>>> Platform Technologies,
>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>
>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Best Regards,
>>>>>>>> Nirmal
>>>>>>>>
>>>>>>>> Nirmal Fernando.
>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>
>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> --
>>>>>>> Lahiru Sandaruwan
>>>>>>> Software Engineer,
>>>>>>> Platform Technologies,
>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>> lean.enterprise.middleware
>>>>>>>
>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Best Regards,
>>>>>> Nirmal
>>>>>>
>>>>>> Nirmal Fernando.
>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>
>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> --
>>>>> Lahiru Sandaruwan
>>>>> Software Engineer,
>>>>> Platform Technologies,
>>>>> WSO2 Inc., http://wso2.com
>>>>> lean.enterprise.middleware
>>>>>
>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>> twitter: http://twitter.com/lahirus
>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Best Regards,
>>>> Nirmal
>>>>
>>>> Nirmal Fernando.
>>>> PPMC Member & Committer of Apache Stratos,
>>>> Senior Software Engineer, WSO2 Inc.
>>>>
>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>
>>>
>>>
>>>
>>> --
>>> --
>>> Lahiru Sandaruwan
>>> Software Engineer,
>>> Platform Technologies,
>>> WSO2 Inc., http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>> blog: http://lahiruwrites.blogspot.com/
>>> twitter: http://twitter.com/lahirus
>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>
>>>
>>
>>
>> --
>> Best Regards,
>> Nirmal
>>
>> Nirmal Fernando.
>> PPMC Member & Committer of Apache Stratos,
>> Senior Software Engineer, WSO2 Inc.
>>
>> Blog: http://nirmalfdo.blogspot.com/
>>
>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Nirmal Fernando <ni...@gmail.com>.
[Forwarding the bounced email]

On Thu, Apr 3, 2014 at 8:51 AM, Nirmal Fernando <ni...@gmail.com>wrote:

> puppetinstall is called by the config script
> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/config.sh;h=3347b805bc0841325ddf251b19572dfe1cc58394;hb=HEAD
>
> and puppetinstall file copies the stratos_sendinfo.rb.
>
>
> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3-agent/puppetinstall/puppetinstall;h=214edb3d6a79867ecec7e1e94e73a57d55e760a6;hb=HEAD
>
> Aren't you following the wiki document? :-)
>
>
> On Thu, Apr 3, 2014 at 4:52 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>
>> puppetinstall script is not call by any script. init-vcloud.sh seems to
>> be having that. Seems the scripts are broken somewhere. So
>> stratos_sendinfo.rb is not placed correctly.
>>
>>
>> On Wed, Apr 2, 2014 at 9:46 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>
>>> Ah.. Please change
>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD
>>>
>>> to use
>>>
>>> stratos_instance_data_
>>>
>>> instead of stratos_
>>>
>>>
>>> On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>
>>>> Issue was not adding correct parameters to
>>>> "/etc/httpd/conf/httpd.conf". Because "<%= @stratos_host_name %>" was
>>>> not exported since this script was not run.
>>>>
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <nirmal070125@gmail.com
>>>> > wrote:
>>>>
>>>>> Ok, can you send the issue you saw?
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>
>>>>>> It seems not. I'm using a script used by Manula for some other
>>>>>> deployment. But i cannot find that string in original one either...
>>>>>> Here is the complete script i'm using,
>>>>>>
>>>>>>
>>>>>> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>>>>>>   $packages = [
>>>>>>     'httpd',
>>>>>>     'openssl.x86_64',
>>>>>>     'mod_ssl.x86_64',
>>>>>>     'php',
>>>>>>     'php-adodb.noarch',
>>>>>>     'php-dba.x86_64',
>>>>>>     'php-gd.x86_64',
>>>>>>     'php-imap.x86_64',
>>>>>>     'php-ldap.x86_64',
>>>>>>     'php-mcrypt.x86_64',
>>>>>>     'php-mysql.x86_64',
>>>>>>     'php-pear.noarch',
>>>>>>     'php-xml.x86_64',
>>>>>>     'php-xmlrpc.x86_64',
>>>>>>     'php.x86_64',
>>>>>>     'git-all.noarch',
>>>>>>     ]
>>>>>>
>>>>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>>>>> #    ensure => present,
>>>>>> #    source => 'puppet:///modules/php/90forceyes';
>>>>>> #  }
>>>>>>
>>>>>> #  exec { 'update-apt':
>>>>>> #    path    => ['/bin', '/usr/bin'],
>>>>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>>>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>>>>> #  }
>>>>>>
>>>>>>   package { $packages:
>>>>>>     ensure   => installed,
>>>>>>   }
>>>>>>
>>>>>>   # Apache
>>>>>>   file {
>>>>>>     '/etc/httpd/conf/httpd.conf':
>>>>>>       owner   => 'root',
>>>>>>       group   => 'root',
>>>>>>       mode    => '0775',
>>>>>>       notify  => Service['httpd'],
>>>>>>       content => template('php/httpd/httpd.conf.erb'),
>>>>>>       require => Package['httpd'];
>>>>>> #
>>>>>> #    '/etc/apache2/sites-available/default':
>>>>>> #      owner   => 'root',
>>>>>> #      group   => 'root',
>>>>>> #      mode    => '0775',
>>>>>> #      notify  => Service['apache2'],
>>>>>> #      content => template('php/apache2/sites-available/default.erb'),
>>>>>> #      require => Package['apache2'];
>>>>>> #
>>>>>> #    '/etc/apache2/sites-available/default-ssl':
>>>>>> #      owner   => 'root',
>>>>>> #      group   => 'root',
>>>>>> #      mode    => '0775',
>>>>>> #      notify  => Service['apache2'],
>>>>>> #      content =>
>>>>>> template('php/apache2/sites-available/default-ssl.erb'),
>>>>>> #      require => Package['apache2'];
>>>>>>   }
>>>>>>
>>>>>> #  exec {
>>>>>> #    'enable ssl module':
>>>>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>> #      command => 'a2enmod ssl',
>>>>>> #      require => Package['apache2'];
>>>>>> #  }
>>>>>>
>>>>>>   service { 'httpd':
>>>>>>     ensure    => running,
>>>>>>     name      => 'httpd',
>>>>>>     hasstatus => true,
>>>>>>     pattern   => 'httpd',
>>>>>>     require   => Package['httpd'];
>>>>>>   }
>>>>>>
>>>>>>   exec { 'remove www contents':
>>>>>>     path    => '/bin/',
>>>>>>     command => "rm -rf /var/www/html/*",
>>>>>>     require => Package['httpd'],
>>>>>>   }
>>>>>>
>>>>>>   # Apache end
>>>>>> #  exec { 'clone git repo':
>>>>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>>>> #    cwd      => '/var/www',
>>>>>> #    command  => "git clone ${stratos_git_repo}",
>>>>>> #    require  => [
>>>>>> #      Package['git-all.noarch'],
>>>>>> #      Package['httpd'],
>>>>>> #    ]
>>>>>> #  }
>>>>>> }
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <
>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>
>>>>>>> In your script, do you have "stratos_" string somewhere?
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>>>
>>>>>>>> Hi Nirmal,
>>>>>>>>
>>>>>>>> Correct. I have a changed script to work with CentOS. Do you know
>>>>>>>> which line calls this. Could not find :)
>>>>>>>>
>>>>>>>> Thanks.
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>
>>>>>>>>> Lahiru,
>>>>>>>>>
>>>>>>>>> I think you might be using a different init.pp than
>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <
>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>
>>>>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in place. May
>>>>>>>>>> be my puppet master configurations are wrong.
>>>>>>>>>>
>>>>>>>>>> Will look into it.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>>>
>>>>>>>>>>> Lahiru,
>>>>>>>>>>>
>>>>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>>> Hi,
>>>>>>>>>>>>
>>>>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>>>>
>>>>>>>>>>>> Thanks.
>>>>>>>>>>>>
>>>>>>>>>>>> [1]
>>>>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>>>>> [2]
>>>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>>>>  --
>>>>>>>>>>>> --
>>>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>>>> Software Engineer,
>>>>>>>>>>>> Platform Technologies,
>>>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>>>
>>>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>>>> linked-in:
>>>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
>>>>>>>>>>> Best Regards,
>>>>>>>>>>> Nirmal
>>>>>>>>>>>
>>>>>>>>>>> Nirmal Fernando.
>>>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>>>
>>>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>>>>>>>>>> --
>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>> Software Engineer,
>>>>>>>>>> Platform Technologies,
>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>
>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>> linked-in:
>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Best Regards,
>>>>>>>>> Nirmal
>>>>>>>>>
>>>>>>>>> Nirmal Fernando.
>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>
>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> --
>>>>>>>> Lahiru Sandaruwan
>>>>>>>> Software Engineer,
>>>>>>>> Platform Technologies,
>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>> lean.enterprise.middleware
>>>>>>>>
>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Best Regards,
>>>>>>> Nirmal
>>>>>>>
>>>>>>> Nirmal Fernando.
>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>
>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> --
>>>>>> Lahiru Sandaruwan
>>>>>> Software Engineer,
>>>>>> Platform Technologies,
>>>>>> WSO2 Inc., http://wso2.com
>>>>>> lean.enterprise.middleware
>>>>>>
>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>> twitter: http://twitter.com/lahirus
>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>> Nirmal
>>>>>
>>>>> Nirmal Fernando.
>>>>> PPMC Member & Committer of Apache Stratos,
>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>
>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> --
>>>> Lahiru Sandaruwan
>>>> Software Engineer,
>>>> Platform Technologies,
>>>> WSO2 Inc., http://wso2.com
>>>> lean.enterprise.middleware
>>>>
>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>> blog: http://lahiruwrites.blogspot.com/
>>>> twitter: http://twitter.com/lahirus
>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>
>>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> --
>> Lahiru Sandaruwan
>> Software Engineer,
>> Platform Technologies,
>> WSO2 Inc., http://wso2.com
>> lean.enterprise.middleware
>>
>> email: lahirus@wso2.com cell: (+94) 773 325 954
>> blog: http://lahiruwrites.blogspot.com/
>> twitter: http://twitter.com/lahirus
>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>
>>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Lahiru Sandaruwan <la...@wso2.com>.
puppetinstall script is not call by any script. init-vcloud.sh seems to be
having that. Seems the scripts are broken somewhere. So stratos_sendinfo.rb
is not placed correctly.


On Wed, Apr 2, 2014 at 9:46 AM, Nirmal Fernando <ni...@gmail.com>wrote:

> Ah.. Please change
> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD
>
> to use
>
> stratos_instance_data_
>
> instead of stratos_
>
>
> On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>
>> Issue was not adding correct parameters to "/etc/httpd/conf/httpd.conf".
>> Because "<%= @stratos_host_name %>" was not exported since this script
>> was not run.
>>
>>
>>
>> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>
>>> Ok, can you send the issue you saw?
>>>
>>>
>>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>
>>>> It seems not. I'm using a script used by Manula for some other
>>>> deployment. But i cannot find that string in original one either...
>>>> Here is the complete script i'm using,
>>>>
>>>>
>>>> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>>>>   $packages = [
>>>>     'httpd',
>>>>     'openssl.x86_64',
>>>>     'mod_ssl.x86_64',
>>>>     'php',
>>>>     'php-adodb.noarch',
>>>>     'php-dba.x86_64',
>>>>     'php-gd.x86_64',
>>>>     'php-imap.x86_64',
>>>>     'php-ldap.x86_64',
>>>>     'php-mcrypt.x86_64',
>>>>     'php-mysql.x86_64',
>>>>     'php-pear.noarch',
>>>>     'php-xml.x86_64',
>>>>     'php-xmlrpc.x86_64',
>>>>     'php.x86_64',
>>>>     'git-all.noarch',
>>>>     ]
>>>>
>>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>>> #    ensure => present,
>>>> #    source => 'puppet:///modules/php/90forceyes';
>>>> #  }
>>>>
>>>> #  exec { 'update-apt':
>>>> #    path    => ['/bin', '/usr/bin'],
>>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>>> #  }
>>>>
>>>>   package { $packages:
>>>>     ensure   => installed,
>>>>   }
>>>>
>>>>   # Apache
>>>>   file {
>>>>     '/etc/httpd/conf/httpd.conf':
>>>>       owner   => 'root',
>>>>       group   => 'root',
>>>>       mode    => '0775',
>>>>       notify  => Service['httpd'],
>>>>       content => template('php/httpd/httpd.conf.erb'),
>>>>       require => Package['httpd'];
>>>> #
>>>> #    '/etc/apache2/sites-available/default':
>>>> #      owner   => 'root',
>>>> #      group   => 'root',
>>>> #      mode    => '0775',
>>>> #      notify  => Service['apache2'],
>>>> #      content => template('php/apache2/sites-available/default.erb'),
>>>> #      require => Package['apache2'];
>>>> #
>>>> #    '/etc/apache2/sites-available/default-ssl':
>>>> #      owner   => 'root',
>>>> #      group   => 'root',
>>>> #      mode    => '0775',
>>>> #      notify  => Service['apache2'],
>>>> #      content =>
>>>> template('php/apache2/sites-available/default-ssl.erb'),
>>>> #      require => Package['apache2'];
>>>>   }
>>>>
>>>> #  exec {
>>>> #    'enable ssl module':
>>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>> #      command => 'a2enmod ssl',
>>>> #      require => Package['apache2'];
>>>> #  }
>>>>
>>>>   service { 'httpd':
>>>>     ensure    => running,
>>>>     name      => 'httpd',
>>>>     hasstatus => true,
>>>>     pattern   => 'httpd',
>>>>     require   => Package['httpd'];
>>>>   }
>>>>
>>>>   exec { 'remove www contents':
>>>>     path    => '/bin/',
>>>>     command => "rm -rf /var/www/html/*",
>>>>     require => Package['httpd'],
>>>>   }
>>>>
>>>>   # Apache end
>>>> #  exec { 'clone git repo':
>>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>> #    cwd      => '/var/www',
>>>> #    command  => "git clone ${stratos_git_repo}",
>>>> #    require  => [
>>>> #      Package['git-all.noarch'],
>>>> #      Package['httpd'],
>>>> #    ]
>>>> #  }
>>>> }
>>>>
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <nirmal070125@gmail.com
>>>> > wrote:
>>>>
>>>>> In your script, do you have "stratos_" string somewhere?
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>
>>>>>> Hi Nirmal,
>>>>>>
>>>>>> Correct. I have a changed script to work with CentOS. Do you know
>>>>>> which line calls this. Could not find :)
>>>>>>
>>>>>> Thanks.
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>
>>>>>>> Lahiru,
>>>>>>>
>>>>>>> I think you might be using a different init.pp than
>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>>>
>>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in place. May be
>>>>>>>> my puppet master configurations are wrong.
>>>>>>>>
>>>>>>>> Will look into it.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>
>>>>>>>>> Lahiru,
>>>>>>>>>
>>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>
>>>>>>>>>> Hi,
>>>>>>>>>>
>>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>>
>>>>>>>>>> Thanks.
>>>>>>>>>>
>>>>>>>>>> [1]
>>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>>> [2]
>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>>  --
>>>>>>>>>> --
>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>> Software Engineer,
>>>>>>>>>> Platform Technologies,
>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>
>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>> linked-in:
>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Best Regards,
>>>>>>>>> Nirmal
>>>>>>>>>
>>>>>>>>> Nirmal Fernando.
>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>
>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> --
>>>>>>>> Lahiru Sandaruwan
>>>>>>>> Software Engineer,
>>>>>>>> Platform Technologies,
>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>> lean.enterprise.middleware
>>>>>>>>
>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Best Regards,
>>>>>>> Nirmal
>>>>>>>
>>>>>>> Nirmal Fernando.
>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>
>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> --
>>>>>> Lahiru Sandaruwan
>>>>>> Software Engineer,
>>>>>> Platform Technologies,
>>>>>> WSO2 Inc., http://wso2.com
>>>>>> lean.enterprise.middleware
>>>>>>
>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>> twitter: http://twitter.com/lahirus
>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>> Nirmal
>>>>>
>>>>> Nirmal Fernando.
>>>>> PPMC Member & Committer of Apache Stratos,
>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>
>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> --
>>>> Lahiru Sandaruwan
>>>> Software Engineer,
>>>> Platform Technologies,
>>>> WSO2 Inc., http://wso2.com
>>>> lean.enterprise.middleware
>>>>
>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>> blog: http://lahiruwrites.blogspot.com/
>>>> twitter: http://twitter.com/lahirus
>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>
>>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> --
>> Lahiru Sandaruwan
>> Software Engineer,
>> Platform Technologies,
>> WSO2 Inc., http://wso2.com
>> lean.enterprise.middleware
>>
>> email: lahirus@wso2.com cell: (+94) 773 325 954
>> blog: http://lahiruwrites.blogspot.com/
>> twitter: http://twitter.com/lahirus
>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>
>>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Lahiru Sandaruwan <la...@wso2.com>.
Ahh. ok. Will try that. We should change this in source. right?


On Wed, Apr 2, 2014 at 9:46 AM, Nirmal Fernando <ni...@gmail.com>wrote:

> Ah.. Please change
> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD
>
> to use
>
> stratos_instance_data_
>
> instead of stratos_
>
>
> On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>
>> Issue was not adding correct parameters to "/etc/httpd/conf/httpd.conf".
>> Because "<%= @stratos_host_name %>" was not exported since this script
>> was not run.
>>
>>
>>
>> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>
>>> Ok, can you send the issue you saw?
>>>
>>>
>>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>
>>>> It seems not. I'm using a script used by Manula for some other
>>>> deployment. But i cannot find that string in original one either...
>>>> Here is the complete script i'm using,
>>>>
>>>>
>>>> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>>>>   $packages = [
>>>>     'httpd',
>>>>     'openssl.x86_64',
>>>>     'mod_ssl.x86_64',
>>>>     'php',
>>>>     'php-adodb.noarch',
>>>>     'php-dba.x86_64',
>>>>     'php-gd.x86_64',
>>>>     'php-imap.x86_64',
>>>>     'php-ldap.x86_64',
>>>>     'php-mcrypt.x86_64',
>>>>     'php-mysql.x86_64',
>>>>     'php-pear.noarch',
>>>>     'php-xml.x86_64',
>>>>     'php-xmlrpc.x86_64',
>>>>     'php.x86_64',
>>>>     'git-all.noarch',
>>>>     ]
>>>>
>>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>>> #    ensure => present,
>>>> #    source => 'puppet:///modules/php/90forceyes';
>>>> #  }
>>>>
>>>> #  exec { 'update-apt':
>>>> #    path    => ['/bin', '/usr/bin'],
>>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>>> #  }
>>>>
>>>>   package { $packages:
>>>>     ensure   => installed,
>>>>   }
>>>>
>>>>   # Apache
>>>>   file {
>>>>     '/etc/httpd/conf/httpd.conf':
>>>>       owner   => 'root',
>>>>       group   => 'root',
>>>>       mode    => '0775',
>>>>       notify  => Service['httpd'],
>>>>       content => template('php/httpd/httpd.conf.erb'),
>>>>       require => Package['httpd'];
>>>> #
>>>> #    '/etc/apache2/sites-available/default':
>>>> #      owner   => 'root',
>>>> #      group   => 'root',
>>>> #      mode    => '0775',
>>>> #      notify  => Service['apache2'],
>>>> #      content => template('php/apache2/sites-available/default.erb'),
>>>> #      require => Package['apache2'];
>>>> #
>>>> #    '/etc/apache2/sites-available/default-ssl':
>>>> #      owner   => 'root',
>>>> #      group   => 'root',
>>>> #      mode    => '0775',
>>>> #      notify  => Service['apache2'],
>>>> #      content =>
>>>> template('php/apache2/sites-available/default-ssl.erb'),
>>>> #      require => Package['apache2'];
>>>>   }
>>>>
>>>> #  exec {
>>>> #    'enable ssl module':
>>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>> #      command => 'a2enmod ssl',
>>>> #      require => Package['apache2'];
>>>> #  }
>>>>
>>>>   service { 'httpd':
>>>>     ensure    => running,
>>>>     name      => 'httpd',
>>>>     hasstatus => true,
>>>>     pattern   => 'httpd',
>>>>     require   => Package['httpd'];
>>>>   }
>>>>
>>>>   exec { 'remove www contents':
>>>>     path    => '/bin/',
>>>>     command => "rm -rf /var/www/html/*",
>>>>     require => Package['httpd'],
>>>>   }
>>>>
>>>>   # Apache end
>>>> #  exec { 'clone git repo':
>>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>>> #    cwd      => '/var/www',
>>>> #    command  => "git clone ${stratos_git_repo}",
>>>> #    require  => [
>>>> #      Package['git-all.noarch'],
>>>> #      Package['httpd'],
>>>> #    ]
>>>> #  }
>>>> }
>>>>
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <nirmal070125@gmail.com
>>>> > wrote:
>>>>
>>>>> In your script, do you have "stratos_" string somewhere?
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>
>>>>>> Hi Nirmal,
>>>>>>
>>>>>> Correct. I have a changed script to work with CentOS. Do you know
>>>>>> which line calls this. Could not find :)
>>>>>>
>>>>>> Thanks.
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>
>>>>>>> Lahiru,
>>>>>>>
>>>>>>> I think you might be using a different init.pp than
>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>>>
>>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in place. May be
>>>>>>>> my puppet master configurations are wrong.
>>>>>>>>
>>>>>>>> Will look into it.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>>
>>>>>>>>> Lahiru,
>>>>>>>>>
>>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>>
>>>>>>>>>> Hi,
>>>>>>>>>>
>>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>>
>>>>>>>>>> Thanks.
>>>>>>>>>>
>>>>>>>>>> [1]
>>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>>> [2]
>>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>>  --
>>>>>>>>>> --
>>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>>> Software Engineer,
>>>>>>>>>> Platform Technologies,
>>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>>
>>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>>> linked-in:
>>>>>>>>>> http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Best Regards,
>>>>>>>>> Nirmal
>>>>>>>>>
>>>>>>>>> Nirmal Fernando.
>>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>>
>>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> --
>>>>>>>> Lahiru Sandaruwan
>>>>>>>> Software Engineer,
>>>>>>>> Platform Technologies,
>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>> lean.enterprise.middleware
>>>>>>>>
>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Best Regards,
>>>>>>> Nirmal
>>>>>>>
>>>>>>> Nirmal Fernando.
>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>
>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> --
>>>>>> Lahiru Sandaruwan
>>>>>> Software Engineer,
>>>>>> Platform Technologies,
>>>>>> WSO2 Inc., http://wso2.com
>>>>>> lean.enterprise.middleware
>>>>>>
>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>> twitter: http://twitter.com/lahirus
>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>> Nirmal
>>>>>
>>>>> Nirmal Fernando.
>>>>> PPMC Member & Committer of Apache Stratos,
>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>
>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> --
>>>> Lahiru Sandaruwan
>>>> Software Engineer,
>>>> Platform Technologies,
>>>> WSO2 Inc., http://wso2.com
>>>> lean.enterprise.middleware
>>>>
>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>> blog: http://lahiruwrites.blogspot.com/
>>>> twitter: http://twitter.com/lahirus
>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>
>>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> --
>> Lahiru Sandaruwan
>> Software Engineer,
>> Platform Technologies,
>> WSO2 Inc., http://wso2.com
>> lean.enterprise.middleware
>>
>> email: lahirus@wso2.com cell: (+94) 773 325 954
>> blog: http://lahiruwrites.blogspot.com/
>> twitter: http://twitter.com/lahirus
>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>
>>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Nirmal Fernando <ni...@gmail.com>.
Ah.. Please change
https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/templates/httpd/httpd.conf.erb;h=ce3ebebeda15cf0fe6a21087650e9a96868de983;hb=HEAD

to use

stratos_instance_data_

instead of stratos_


On Wed, Apr 2, 2014 at 10:07 PM, Lahiru Sandaruwan <la...@wso2.com> wrote:

> Issue was not adding correct parameters to "/etc/httpd/conf/httpd.conf".
> Because "<%= @stratos_host_name %>" was not exported since this script
> was not run.
>
>
>
> On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>
>> Ok, can you send the issue you saw?
>>
>>
>> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>
>>> It seems not. I'm using a script used by Manula for some other
>>> deployment. But i cannot find that string in original one either...
>>> Here is the complete script i'm using,
>>>
>>>
>>> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>>>   $packages = [
>>>     'httpd',
>>>     'openssl.x86_64',
>>>     'mod_ssl.x86_64',
>>>     'php',
>>>     'php-adodb.noarch',
>>>     'php-dba.x86_64',
>>>     'php-gd.x86_64',
>>>     'php-imap.x86_64',
>>>     'php-ldap.x86_64',
>>>     'php-mcrypt.x86_64',
>>>     'php-mysql.x86_64',
>>>     'php-pear.noarch',
>>>     'php-xml.x86_64',
>>>     'php-xmlrpc.x86_64',
>>>     'php.x86_64',
>>>     'git-all.noarch',
>>>     ]
>>>
>>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>>> #    ensure => present,
>>> #    source => 'puppet:///modules/php/90forceyes';
>>> #  }
>>>
>>> #  exec { 'update-apt':
>>> #    path    => ['/bin', '/usr/bin'],
>>> #    command => 'apt-get update > /dev/null 2>&1 &',
>>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>>> #  }
>>>
>>>   package { $packages:
>>>     ensure   => installed,
>>>   }
>>>
>>>   # Apache
>>>   file {
>>>     '/etc/httpd/conf/httpd.conf':
>>>       owner   => 'root',
>>>       group   => 'root',
>>>       mode    => '0775',
>>>       notify  => Service['httpd'],
>>>       content => template('php/httpd/httpd.conf.erb'),
>>>       require => Package['httpd'];
>>> #
>>> #    '/etc/apache2/sites-available/default':
>>> #      owner   => 'root',
>>> #      group   => 'root',
>>> #      mode    => '0775',
>>> #      notify  => Service['apache2'],
>>> #      content => template('php/apache2/sites-available/default.erb'),
>>> #      require => Package['apache2'];
>>> #
>>> #    '/etc/apache2/sites-available/default-ssl':
>>> #      owner   => 'root',
>>> #      group   => 'root',
>>> #      mode    => '0775',
>>> #      notify  => Service['apache2'],
>>> #      content =>
>>> template('php/apache2/sites-available/default-ssl.erb'),
>>> #      require => Package['apache2'];
>>>   }
>>>
>>> #  exec {
>>> #    'enable ssl module':
>>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>>> #      command => 'a2enmod ssl',
>>> #      require => Package['apache2'];
>>> #  }
>>>
>>>   service { 'httpd':
>>>     ensure    => running,
>>>     name      => 'httpd',
>>>     hasstatus => true,
>>>     pattern   => 'httpd',
>>>     require   => Package['httpd'];
>>>   }
>>>
>>>   exec { 'remove www contents':
>>>     path    => '/bin/',
>>>     command => "rm -rf /var/www/html/*",
>>>     require => Package['httpd'],
>>>   }
>>>
>>>   # Apache end
>>> #  exec { 'clone git repo':
>>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>>> #    cwd      => '/var/www',
>>> #    command  => "git clone ${stratos_git_repo}",
>>> #    require  => [
>>> #      Package['git-all.noarch'],
>>> #      Package['httpd'],
>>> #    ]
>>> #  }
>>> }
>>>
>>>
>>>
>>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>>
>>>> In your script, do you have "stratos_" string somewhere?
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>
>>>>> Hi Nirmal,
>>>>>
>>>>> Correct. I have a changed script to work with CentOS. Do you know
>>>>> which line calls this. Could not find :)
>>>>>
>>>>> Thanks.
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <
>>>>> nirmal070125@gmail.com> wrote:
>>>>>
>>>>>> Lahiru,
>>>>>>
>>>>>> I think you might be using a different init.pp than
>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>>
>>>>>>> PHP cartridge did not work with stratos_seninfo.rb in place. May be
>>>>>>> my puppet master configurations are wrong.
>>>>>>>
>>>>>>> Will look into it.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>>
>>>>>>>> Lahiru,
>>>>>>>>
>>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <
>>>>>>>> lahirus@wso2.com> wrote:
>>>>>>>>
>>>>>>>>> Hi,
>>>>>>>>>
>>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>>
>>>>>>>>> Thanks.
>>>>>>>>>
>>>>>>>>> [1]
>>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>>> [2]
>>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>>  --
>>>>>>>>> --
>>>>>>>>> Lahiru Sandaruwan
>>>>>>>>> Software Engineer,
>>>>>>>>> Platform Technologies,
>>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>>> lean.enterprise.middleware
>>>>>>>>>
>>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>>
>>>>>>>>>
>>>>>>>>
>>>>>>>>
>>>>>>>> --
>>>>>>>> Best Regards,
>>>>>>>> Nirmal
>>>>>>>>
>>>>>>>> Nirmal Fernando.
>>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>>
>>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> --
>>>>>>> Lahiru Sandaruwan
>>>>>>> Software Engineer,
>>>>>>> Platform Technologies,
>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>> lean.enterprise.middleware
>>>>>>>
>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Best Regards,
>>>>>> Nirmal
>>>>>>
>>>>>> Nirmal Fernando.
>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>
>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> --
>>>>> Lahiru Sandaruwan
>>>>> Software Engineer,
>>>>> Platform Technologies,
>>>>> WSO2 Inc., http://wso2.com
>>>>> lean.enterprise.middleware
>>>>>
>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>> twitter: http://twitter.com/lahirus
>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Best Regards,
>>>> Nirmal
>>>>
>>>> Nirmal Fernando.
>>>> PPMC Member & Committer of Apache Stratos,
>>>> Senior Software Engineer, WSO2 Inc.
>>>>
>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>
>>>
>>>
>>>
>>> --
>>> --
>>> Lahiru Sandaruwan
>>> Software Engineer,
>>> Platform Technologies,
>>> WSO2 Inc., http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>> blog: http://lahiruwrites.blogspot.com/
>>> twitter: http://twitter.com/lahirus
>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>
>>>
>>
>>
>> --
>> Best Regards,
>> Nirmal
>>
>> Nirmal Fernando.
>> PPMC Member & Committer of Apache Stratos,
>> Senior Software Engineer, WSO2 Inc.
>>
>> Blog: http://nirmalfdo.blogspot.com/
>>
>
>
>
> --
> --
> Lahiru Sandaruwan
> Software Engineer,
> Platform Technologies,
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> email: lahirus@wso2.com cell: (+94) 773 325 954
> blog: http://lahiruwrites.blogspot.com/
> twitter: http://twitter.com/lahirus
> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>
>


-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Lahiru Sandaruwan <la...@wso2.com>.
Issue was not adding correct parameters to "/etc/httpd/conf/httpd.conf".
Because "<%= @stratos_host_name %>" was not exported since this script was
not run.



On Wed, Apr 2, 2014 at 9:21 AM, Nirmal Fernando <ni...@gmail.com>wrote:

> Ok, can you send the issue you saw?
>
>
> On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>
>> It seems not. I'm using a script used by Manula for some other
>> deployment. But i cannot find that string in original one either...
>> Here is the complete script i'm using,
>>
>>
>> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>>   $packages = [
>>     'httpd',
>>     'openssl.x86_64',
>>     'mod_ssl.x86_64',
>>     'php',
>>     'php-adodb.noarch',
>>     'php-dba.x86_64',
>>     'php-gd.x86_64',
>>     'php-imap.x86_64',
>>     'php-ldap.x86_64',
>>     'php-mcrypt.x86_64',
>>     'php-mysql.x86_64',
>>     'php-pear.noarch',
>>     'php-xml.x86_64',
>>     'php-xmlrpc.x86_64',
>>     'php.x86_64',
>>     'git-all.noarch',
>>     ]
>>
>> #  file { '/etc/apt/apt.conf.d/90forceyes':
>> #    ensure => present,
>> #    source => 'puppet:///modules/php/90forceyes';
>> #  }
>>
>> #  exec { 'update-apt':
>> #    path    => ['/bin', '/usr/bin'],
>> #    command => 'apt-get update > /dev/null 2>&1 &',
>> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
>> #  }
>>
>>   package { $packages:
>>     ensure   => installed,
>>   }
>>
>>   # Apache
>>   file {
>>     '/etc/httpd/conf/httpd.conf':
>>       owner   => 'root',
>>       group   => 'root',
>>       mode    => '0775',
>>       notify  => Service['httpd'],
>>       content => template('php/httpd/httpd.conf.erb'),
>>       require => Package['httpd'];
>> #
>> #    '/etc/apache2/sites-available/default':
>> #      owner   => 'root',
>> #      group   => 'root',
>> #      mode    => '0775',
>> #      notify  => Service['apache2'],
>> #      content => template('php/apache2/sites-available/default.erb'),
>> #      require => Package['apache2'];
>> #
>> #    '/etc/apache2/sites-available/default-ssl':
>> #      owner   => 'root',
>> #      group   => 'root',
>> #      mode    => '0775',
>> #      notify  => Service['apache2'],
>> #      content => template('php/apache2/sites-available/default-ssl.erb'),
>> #      require => Package['apache2'];
>>   }
>>
>> #  exec {
>> #    'enable ssl module':
>> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
>> #      command => 'a2enmod ssl',
>> #      require => Package['apache2'];
>> #  }
>>
>>   service { 'httpd':
>>     ensure    => running,
>>     name      => 'httpd',
>>     hasstatus => true,
>>     pattern   => 'httpd',
>>     require   => Package['httpd'];
>>   }
>>
>>   exec { 'remove www contents':
>>     path    => '/bin/',
>>     command => "rm -rf /var/www/html/*",
>>     require => Package['httpd'],
>>   }
>>
>>   # Apache end
>> #  exec { 'clone git repo':
>> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
>> #    cwd      => '/var/www',
>> #    command  => "git clone ${stratos_git_repo}",
>> #    require  => [
>> #      Package['git-all.noarch'],
>> #      Package['httpd'],
>> #    ]
>> #  }
>> }
>>
>>
>>
>> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>
>>> In your script, do you have "stratos_" string somewhere?
>>>
>>>
>>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>
>>>> Hi Nirmal,
>>>>
>>>> Correct. I have a changed script to work with CentOS. Do you know which
>>>> line calls this. Could not find :)
>>>>
>>>> Thanks.
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <nirmal070125@gmail.com
>>>> > wrote:
>>>>
>>>>> Lahiru,
>>>>>
>>>>> I think you might be using a different init.pp than
>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>>
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>
>>>>>> PHP cartridge did not work with stratos_seninfo.rb in place. May be
>>>>>> my puppet master configurations are wrong.
>>>>>>
>>>>>> Will look into it.
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>>> nirmal070125@gmail.com> wrote:
>>>>>>
>>>>>>> Lahiru,
>>>>>>>
>>>>>>> No, we do not need the file you have pointed. We need
>>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <lahirus@wso2.com
>>>>>>> > wrote:
>>>>>>>
>>>>>>>> Hi,
>>>>>>>>
>>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>>
>>>>>>>> Thanks.
>>>>>>>>
>>>>>>>> [1]
>>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>>> [2]
>>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>>  --
>>>>>>>> --
>>>>>>>> Lahiru Sandaruwan
>>>>>>>> Software Engineer,
>>>>>>>> Platform Technologies,
>>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>>> lean.enterprise.middleware
>>>>>>>>
>>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>>
>>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> --
>>>>>>> Best Regards,
>>>>>>> Nirmal
>>>>>>>
>>>>>>> Nirmal Fernando.
>>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>>
>>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> --
>>>>>> Lahiru Sandaruwan
>>>>>> Software Engineer,
>>>>>> Platform Technologies,
>>>>>> WSO2 Inc., http://wso2.com
>>>>>> lean.enterprise.middleware
>>>>>>
>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>> twitter: http://twitter.com/lahirus
>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>> Nirmal
>>>>>
>>>>> Nirmal Fernando.
>>>>> PPMC Member & Committer of Apache Stratos,
>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>
>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> --
>>>> Lahiru Sandaruwan
>>>> Software Engineer,
>>>> Platform Technologies,
>>>> WSO2 Inc., http://wso2.com
>>>> lean.enterprise.middleware
>>>>
>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>> blog: http://lahiruwrites.blogspot.com/
>>>> twitter: http://twitter.com/lahirus
>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>
>>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> --
>> Lahiru Sandaruwan
>> Software Engineer,
>> Platform Technologies,
>> WSO2 Inc., http://wso2.com
>> lean.enterprise.middleware
>>
>> email: lahirus@wso2.com cell: (+94) 773 325 954
>> blog: http://lahiruwrites.blogspot.com/
>> twitter: http://twitter.com/lahirus
>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>
>>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Nirmal Fernando <ni...@gmail.com>.
Ok, can you send the issue you saw?


On Wed, Apr 2, 2014 at 9:47 PM, Lahiru Sandaruwan <la...@wso2.com> wrote:

> It seems not. I'm using a script used by Manula for some other deployment.
> But i cannot find that string in original one either...
> Here is the complete script i'm using,
>
>
> class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
>   $packages = [
>     'httpd',
>     'openssl.x86_64',
>     'mod_ssl.x86_64',
>     'php',
>     'php-adodb.noarch',
>     'php-dba.x86_64',
>     'php-gd.x86_64',
>     'php-imap.x86_64',
>     'php-ldap.x86_64',
>     'php-mcrypt.x86_64',
>     'php-mysql.x86_64',
>     'php-pear.noarch',
>     'php-xml.x86_64',
>     'php-xmlrpc.x86_64',
>     'php.x86_64',
>     'git-all.noarch',
>     ]
>
> #  file { '/etc/apt/apt.conf.d/90forceyes':
> #    ensure => present,
> #    source => 'puppet:///modules/php/90forceyes';
> #  }
>
> #  exec { 'update-apt':
> #    path    => ['/bin', '/usr/bin'],
> #    command => 'apt-get update > /dev/null 2>&1 &',
> #    require => File['/etc/apt/apt.conf.d/90forceyes'],
> #  }
>
>   package { $packages:
>     ensure   => installed,
>   }
>
>   # Apache
>   file {
>     '/etc/httpd/conf/httpd.conf':
>       owner   => 'root',
>       group   => 'root',
>       mode    => '0775',
>       notify  => Service['httpd'],
>       content => template('php/httpd/httpd.conf.erb'),
>       require => Package['httpd'];
> #
> #    '/etc/apache2/sites-available/default':
> #      owner   => 'root',
> #      group   => 'root',
> #      mode    => '0775',
> #      notify  => Service['apache2'],
> #      content => template('php/apache2/sites-available/default.erb'),
> #      require => Package['apache2'];
> #
> #    '/etc/apache2/sites-available/default-ssl':
> #      owner   => 'root',
> #      group   => 'root',
> #      mode    => '0775',
> #      notify  => Service['apache2'],
> #      content => template('php/apache2/sites-available/default-ssl.erb'),
> #      require => Package['apache2'];
>   }
>
> #  exec {
> #    'enable ssl module':
> #      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
> #      command => 'a2enmod ssl',
> #      require => Package['apache2'];
> #  }
>
>   service { 'httpd':
>     ensure    => running,
>     name      => 'httpd',
>     hasstatus => true,
>     pattern   => 'httpd',
>     require   => Package['httpd'];
>   }
>
>   exec { 'remove www contents':
>     path    => '/bin/',
>     command => "rm -rf /var/www/html/*",
>     require => Package['httpd'],
>   }
>
>   # Apache end
> #  exec { 'clone git repo':
> #    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
> #    cwd      => '/var/www',
> #    command  => "git clone ${stratos_git_repo}",
> #    require  => [
> #      Package['git-all.noarch'],
> #      Package['httpd'],
> #    ]
> #  }
> }
>
>
>
> On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>
>> In your script, do you have "stratos_" string somewhere?
>>
>>
>> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>
>>> Hi Nirmal,
>>>
>>> Correct. I have a changed script to work with CentOS. Do you know which
>>> line calls this. Could not find :)
>>>
>>> Thanks.
>>>
>>>
>>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>>
>>>> Lahiru,
>>>>
>>>> I think you might be using a different init.pp than
>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>>
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>
>>>>> PHP cartridge did not work with stratos_seninfo.rb in place. May be my
>>>>> puppet master configurations are wrong.
>>>>>
>>>>> Will look into it.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>>> nirmal070125@gmail.com> wrote:
>>>>>
>>>>>> Lahiru,
>>>>>>
>>>>>> No, we do not need the file you have pointed. We need
>>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>>
>>>>>>> Hi,
>>>>>>>
>>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>>
>>>>>>> Thanks.
>>>>>>>
>>>>>>> [1]
>>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>>> [2]
>>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>>  --
>>>>>>> --
>>>>>>> Lahiru Sandaruwan
>>>>>>> Software Engineer,
>>>>>>> Platform Technologies,
>>>>>>> WSO2 Inc., http://wso2.com
>>>>>>> lean.enterprise.middleware
>>>>>>>
>>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>>> twitter: http://twitter.com/lahirus
>>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>>
>>>>>>>
>>>>>>
>>>>>>
>>>>>> --
>>>>>> Best Regards,
>>>>>> Nirmal
>>>>>>
>>>>>> Nirmal Fernando.
>>>>>> PPMC Member & Committer of Apache Stratos,
>>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>>
>>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>>
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> --
>>>>> Lahiru Sandaruwan
>>>>> Software Engineer,
>>>>> Platform Technologies,
>>>>> WSO2 Inc., http://wso2.com
>>>>> lean.enterprise.middleware
>>>>>
>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>> twitter: http://twitter.com/lahirus
>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Best Regards,
>>>> Nirmal
>>>>
>>>> Nirmal Fernando.
>>>> PPMC Member & Committer of Apache Stratos,
>>>> Senior Software Engineer, WSO2 Inc.
>>>>
>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>
>>>
>>>
>>>
>>> --
>>> --
>>> Lahiru Sandaruwan
>>> Software Engineer,
>>> Platform Technologies,
>>> WSO2 Inc., http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>> blog: http://lahiruwrites.blogspot.com/
>>> twitter: http://twitter.com/lahirus
>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>
>>>
>>
>>
>> --
>> Best Regards,
>> Nirmal
>>
>> Nirmal Fernando.
>> PPMC Member & Committer of Apache Stratos,
>> Senior Software Engineer, WSO2 Inc.
>>
>> Blog: http://nirmalfdo.blogspot.com/
>>
>
>
>
> --
> --
> Lahiru Sandaruwan
> Software Engineer,
> Platform Technologies,
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> email: lahirus@wso2.com cell: (+94) 773 325 954
> blog: http://lahiruwrites.blogspot.com/
> twitter: http://twitter.com/lahirus
> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>
>


-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Lahiru Sandaruwan <la...@wso2.com>.
It seems not. I'm using a script used by Manula for some other deployment.
But i cannot find that string in original one either...
Here is the complete script i'm using,


class php ($syslog="", $docroot="/var/www/html", $samlalias="") {
  $packages = [
    'httpd',
    'openssl.x86_64',
    'mod_ssl.x86_64',
    'php',
    'php-adodb.noarch',
    'php-dba.x86_64',
    'php-gd.x86_64',
    'php-imap.x86_64',
    'php-ldap.x86_64',
    'php-mcrypt.x86_64',
    'php-mysql.x86_64',
    'php-pear.noarch',
    'php-xml.x86_64',
    'php-xmlrpc.x86_64',
    'php.x86_64',
    'git-all.noarch',
    ]

#  file { '/etc/apt/apt.conf.d/90forceyes':
#    ensure => present,
#    source => 'puppet:///modules/php/90forceyes';
#  }

#  exec { 'update-apt':
#    path    => ['/bin', '/usr/bin'],
#    command => 'apt-get update > /dev/null 2>&1 &',
#    require => File['/etc/apt/apt.conf.d/90forceyes'],
#  }

  package { $packages:
    ensure   => installed,
  }

  # Apache
  file {
    '/etc/httpd/conf/httpd.conf':
      owner   => 'root',
      group   => 'root',
      mode    => '0775',
      notify  => Service['httpd'],
      content => template('php/httpd/httpd.conf.erb'),
      require => Package['httpd'];
#
#    '/etc/apache2/sites-available/default':
#      owner   => 'root',
#      group   => 'root',
#      mode    => '0775',
#      notify  => Service['apache2'],
#      content => template('php/apache2/sites-available/default.erb'),
#      require => Package['apache2'];
#
#    '/etc/apache2/sites-available/default-ssl':
#      owner   => 'root',
#      group   => 'root',
#      mode    => '0775',
#      notify  => Service['apache2'],
#      content => template('php/apache2/sites-available/default-ssl.erb'),
#      require => Package['apache2'];
  }

#  exec {
#    'enable ssl module':
#      path    => ['/bin', '/usr/bin', '/usr/sbin/'],
#      command => 'a2enmod ssl',
#      require => Package['apache2'];
#  }

  service { 'httpd':
    ensure    => running,
    name      => 'httpd',
    hasstatus => true,
    pattern   => 'httpd',
    require   => Package['httpd'];
  }

  exec { 'remove www contents':
    path    => '/bin/',
    command => "rm -rf /var/www/html/*",
    require => Package['httpd'],
  }

  # Apache end
#  exec { 'clone git repo':
#    path     => ['/bin', '/usr/bin', '/usr/sbin/'],
#    cwd      => '/var/www',
#    command  => "git clone ${stratos_git_repo}",
#    require  => [
#      Package['git-all.noarch'],
#      Package['httpd'],
#    ]
#  }
}



On Wed, Apr 2, 2014 at 9:05 AM, Nirmal Fernando <ni...@gmail.com>wrote:

> In your script, do you have "stratos_" string somewhere?
>
>
> On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>
>> Hi Nirmal,
>>
>> Correct. I have a changed script to work with CentOS. Do you know which
>> line calls this. Could not find :)
>>
>> Thanks.
>>
>>
>> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>
>>> Lahiru,
>>>
>>> I think you might be using a different init.pp than
>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>>
>>>
>>>
>>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>
>>>> PHP cartridge did not work with stratos_seninfo.rb in place. May be my
>>>> puppet master configurations are wrong.
>>>>
>>>> Will look into it.
>>>>
>>>>
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <
>>>> nirmal070125@gmail.com> wrote:
>>>>
>>>>> Lahiru,
>>>>>
>>>>> No, we do not need the file you have pointed. We need
>>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>>> We need to remove the unnecessary files from puppet modules.
>>>>>
>>>>>
>>>>>
>>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>>> of the image. Need changes at[1]. File is [2].
>>>>>>
>>>>>> Thanks.
>>>>>>
>>>>>> [1]
>>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>>> [2]
>>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>>  --
>>>>>> --
>>>>>> Lahiru Sandaruwan
>>>>>> Software Engineer,
>>>>>> Platform Technologies,
>>>>>> WSO2 Inc., http://wso2.com
>>>>>> lean.enterprise.middleware
>>>>>>
>>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>>> twitter: http://twitter.com/lahirus
>>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>>
>>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>> Nirmal
>>>>>
>>>>> Nirmal Fernando.
>>>>> PPMC Member & Committer of Apache Stratos,
>>>>> Senior Software Engineer, WSO2 Inc.
>>>>>
>>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> --
>>>> Lahiru Sandaruwan
>>>> Software Engineer,
>>>> Platform Technologies,
>>>> WSO2 Inc., http://wso2.com
>>>> lean.enterprise.middleware
>>>>
>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>> blog: http://lahiruwrites.blogspot.com/
>>>> twitter: http://twitter.com/lahirus
>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>
>>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> --
>> Lahiru Sandaruwan
>> Software Engineer,
>> Platform Technologies,
>> WSO2 Inc., http://wso2.com
>> lean.enterprise.middleware
>>
>> email: lahirus@wso2.com cell: (+94) 773 325 954
>> blog: http://lahiruwrites.blogspot.com/
>> twitter: http://twitter.com/lahirus
>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>
>>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Nirmal Fernando <ni...@gmail.com>.
In your script, do you have "stratos_" string somewhere?


On Wed, Apr 2, 2014 at 9:30 PM, Lahiru Sandaruwan <la...@wso2.com> wrote:

> Hi Nirmal,
>
> Correct. I have a changed script to work with CentOS. Do you know which
> line calls this. Could not find :)
>
> Thanks.
>
>
> On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>
>> Lahiru,
>>
>> I think you might be using a different init.pp than
>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>>
>>
>>
>> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>
>>> PHP cartridge did not work with stratos_seninfo.rb in place. May be my
>>> puppet master configurations are wrong.
>>>
>>> Will look into it.
>>>
>>>
>>>
>>>
>>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <nirmal070125@gmail.com
>>> > wrote:
>>>
>>>> Lahiru,
>>>>
>>>> No, we do not need the file you have pointed. We need
>>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>>> We need to remove the unnecessary files from puppet modules.
>>>>
>>>>
>>>>
>>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>>> of the image. Need changes at[1]. File is [2].
>>>>>
>>>>> Thanks.
>>>>>
>>>>> [1]
>>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>>> [2]
>>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>>  --
>>>>> --
>>>>> Lahiru Sandaruwan
>>>>> Software Engineer,
>>>>> Platform Technologies,
>>>>> WSO2 Inc., http://wso2.com
>>>>> lean.enterprise.middleware
>>>>>
>>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>>> blog: http://lahiruwrites.blogspot.com/
>>>>> twitter: http://twitter.com/lahirus
>>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>>
>>>>>
>>>>
>>>>
>>>> --
>>>> Best Regards,
>>>> Nirmal
>>>>
>>>> Nirmal Fernando.
>>>> PPMC Member & Committer of Apache Stratos,
>>>> Senior Software Engineer, WSO2 Inc.
>>>>
>>>> Blog: http://nirmalfdo.blogspot.com/
>>>>
>>>
>>>
>>>
>>> --
>>> --
>>> Lahiru Sandaruwan
>>> Software Engineer,
>>> Platform Technologies,
>>> WSO2 Inc., http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>> blog: http://lahiruwrites.blogspot.com/
>>> twitter: http://twitter.com/lahirus
>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>
>>>
>>
>>
>> --
>> Best Regards,
>> Nirmal
>>
>> Nirmal Fernando.
>> PPMC Member & Committer of Apache Stratos,
>> Senior Software Engineer, WSO2 Inc.
>>
>> Blog: http://nirmalfdo.blogspot.com/
>>
>
>
>
> --
> --
> Lahiru Sandaruwan
> Software Engineer,
> Platform Technologies,
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> email: lahirus@wso2.com cell: (+94) 773 325 954
> blog: http://lahiruwrites.blogspot.com/
> twitter: http://twitter.com/lahirus
> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>
>


-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Lahiru Sandaruwan <la...@wso2.com>.
Hi Nirmal,

Correct. I have a changed script to work with CentOS. Do you know which
line calls this. Could not find :)

Thanks.


On Wed, Apr 2, 2014 at 7:51 AM, Nirmal Fernando <ni...@gmail.com>wrote:

> Lahiru,
>
> I think you might be using a different init.pp than
> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD
>
>
>
> On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>
>> PHP cartridge did not work with stratos_seninfo.rb in place. May be my
>> puppet master configurations are wrong.
>>
>> Will look into it.
>>
>>
>>
>>
>> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>>
>>> Lahiru,
>>>
>>> No, we do not need the file you have pointed. We need
>>> stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>>> We need to remove the unnecessary files from puppet modules.
>>>
>>>
>>>
>>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>>
>>>> Hi,
>>>>
>>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>>> of the image. Need changes at[1]. File is [2].
>>>>
>>>> Thanks.
>>>>
>>>> [1]
>>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>>> [2]
>>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>>  --
>>>> --
>>>> Lahiru Sandaruwan
>>>> Software Engineer,
>>>> Platform Technologies,
>>>> WSO2 Inc., http://wso2.com
>>>> lean.enterprise.middleware
>>>>
>>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>>> blog: http://lahiruwrites.blogspot.com/
>>>> twitter: http://twitter.com/lahirus
>>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>>
>>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Nirmal
>>>
>>> Nirmal Fernando.
>>> PPMC Member & Committer of Apache Stratos,
>>> Senior Software Engineer, WSO2 Inc.
>>>
>>> Blog: http://nirmalfdo.blogspot.com/
>>>
>>
>>
>>
>> --
>> --
>> Lahiru Sandaruwan
>> Software Engineer,
>> Platform Technologies,
>> WSO2 Inc., http://wso2.com
>> lean.enterprise.middleware
>>
>> email: lahirus@wso2.com cell: (+94) 773 325 954
>> blog: http://lahiruwrites.blogspot.com/
>> twitter: http://twitter.com/lahirus
>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>
>>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Nirmal Fernando <ni...@gmail.com>.
Lahiru,

I think you might be using a different init.pp than
https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/manifests/init.pp;h=5c66ecc72e160fe87dd91df12f89d57e6cc3dd70;hb=HEAD



On Wed, Apr 2, 2014 at 8:01 PM, Lahiru Sandaruwan <la...@wso2.com> wrote:

> PHP cartridge did not work with stratos_seninfo.rb in place. May be my
> puppet master configurations are wrong.
>
> Will look into it.
>
>
>
>
> On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <ni...@gmail.com>wrote:
>
>> Lahiru,
>>
>> No, we do not need the file you have pointed. We need stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
>> We need to remove the unnecessary files from puppet modules.
>>
>>
>>
>> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>>
>>> Hi,
>>>
>>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>>> of the image. Need changes at[1]. File is [2].
>>>
>>> Thanks.
>>>
>>> [1]
>>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>>> [2]
>>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>>  --
>>> --
>>> Lahiru Sandaruwan
>>> Software Engineer,
>>> Platform Technologies,
>>> WSO2 Inc., http://wso2.com
>>> lean.enterprise.middleware
>>>
>>> email: lahirus@wso2.com cell: (+94) 773 325 954
>>> blog: http://lahiruwrites.blogspot.com/
>>> twitter: http://twitter.com/lahirus
>>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>>
>>>
>>
>>
>> --
>> Best Regards,
>> Nirmal
>>
>> Nirmal Fernando.
>> PPMC Member & Committer of Apache Stratos,
>> Senior Software Engineer, WSO2 Inc.
>>
>> Blog: http://nirmalfdo.blogspot.com/
>>
>
>
>
> --
> --
> Lahiru Sandaruwan
> Software Engineer,
> Platform Technologies,
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> email: lahirus@wso2.com cell: (+94) 773 325 954
> blog: http://lahiruwrites.blogspot.com/
> twitter: http://twitter.com/lahirus
> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>
>


-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Lahiru Sandaruwan <la...@wso2.com>.
PHP cartridge did not work with stratos_seninfo.rb in place. May be my
puppet master configurations are wrong.

Will look into it.




On Wed, Apr 2, 2014 at 12:18 AM, Nirmal Fernando <ni...@gmail.com>wrote:

> Lahiru,
>
> No, we do not need the file you have pointed. We need stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and it's correctly documented as step 13 in [1].
> We need to remove the unnecessary files from puppet modules.
>
>
>
> On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <la...@wso2.com>wrote:
>
>> Hi,
>>
>> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
>> of the image. Need changes at[1]. File is [2].
>>
>> Thanks.
>>
>> [1]
>> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
>> [2]
>> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
>>  --
>> --
>> Lahiru Sandaruwan
>> Software Engineer,
>> Platform Technologies,
>> WSO2 Inc., http://wso2.com
>> lean.enterprise.middleware
>>
>> email: lahirus@wso2.com cell: (+94) 773 325 954
>> blog: http://lahiruwrites.blogspot.com/
>> twitter: http://twitter.com/lahirus
>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>>
>>
>
>
> --
> Best Regards,
> Nirmal
>
> Nirmal Fernando.
> PPMC Member & Committer of Apache Stratos,
> Senior Software Engineer, WSO2 Inc.
>
> Blog: http://nirmalfdo.blogspot.com/
>



-- 
--
Lahiru Sandaruwan
Software Engineer,
Platform Technologies,
WSO2 Inc., http://wso2.com
lean.enterprise.middleware

email: lahirus@wso2.com cell: (+94) 773 325 954
blog: http://lahiruwrites.blogspot.com/
twitter: http://twitter.com/lahirus
linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146

Re: "4.0.0 Creating a Cartridge on OpenStack or EC2" does not mention about "stratos_facts.rb"

Posted by Nirmal Fernando <ni...@gmail.com>.
Lahiru,

No, we do not need the file you have pointed. We need
stratos_sendinfo.rb<https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob_plain;f=tools/puppet3-agent/stratos_sendinfo.rb;hb=HEAD>and
it's correctly documented as step 13 in [1].
We need to remove the unnecessary files from puppet modules.



On Wed, Apr 2, 2014 at 11:50 AM, Lahiru Sandaruwan <la...@wso2.com> wrote:

> Hi,
>
> We need to add "stratos_facts.rb" to "/usr/lib/ruby/site_ruby/1.8/facter"
> of the image. Need changes at[1]. File is [2].
>
> Thanks.
>
> [1]
> https://cwiki.apache.org/confluence/display/STRATOS/4.0.0+Creating+a+Cartridge+on+OpenStack+or+EC2
> [2]
> https://git-wip-us.apache.org/repos/asf?p=incubator-stratos.git;a=blob;f=tools/puppet3/modules/php/lib/facter/stratos_facts.rb;h=3cab535efeed2c9bc6772130508f4b46e43722c2;hb=HEAD
> --
> --
> Lahiru Sandaruwan
> Software Engineer,
> Platform Technologies,
> WSO2 Inc., http://wso2.com
> lean.enterprise.middleware
>
> email: lahirus@wso2.com cell: (+94) 773 325 954
> blog: http://lahiruwrites.blogspot.com/
> twitter: http://twitter.com/lahirus
> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146
>
>


-- 
Best Regards,
Nirmal

Nirmal Fernando.
PPMC Member & Committer of Apache Stratos,
Senior Software Engineer, WSO2 Inc.

Blog: http://nirmalfdo.blogspot.com/