You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stratos.apache.org by ch...@apache.org on 2014/07/04 20:33:52 UTC

[1/2] git commit: Puppet node definitions restructured

Repository: stratos
Updated Branches:
  refs/heads/master 39f4a8f85 -> 2bab7e453


Puppet node definitions restructured


Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/0c8318be
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/0c8318be
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/0c8318be

Branch: refs/heads/master
Commit: 0c8318be45bba4f31962f235af7aa75c58d76fba
Parents: 4a2c5b5
Author: Akila Perera <ra...@gmail.com>
Authored: Wed Jul 2 11:29:51 2014 +0530
Committer: Akila Perera <ra...@gmail.com>
Committed: Wed Jul 2 11:29:51 2014 +0530

----------------------------------------------------------------------
 tools/puppet3/manifests/base.pp            | 44 -------------------------
 tools/puppet3/manifests/default.pp         | 24 --------------
 tools/puppet3/manifests/haproxy.pp         | 25 --------------
 tools/puppet3/manifests/lb.pp              | 25 --------------
 tools/puppet3/manifests/mysql.pp           | 27 ---------------
 tools/puppet3/manifests/nodejs.pp          | 27 ---------------
 tools/puppet3/manifests/nodes.pp           | 18 ++++++++++
 tools/puppet3/manifests/nodes/base.pp      | 44 +++++++++++++++++++++++++
 tools/puppet3/manifests/nodes/default.pp   | 24 ++++++++++++++
 tools/puppet3/manifests/nodes/haproxy.pp   | 25 ++++++++++++++
 tools/puppet3/manifests/nodes/lb.pp        | 25 ++++++++++++++
 tools/puppet3/manifests/nodes/mysql.pp     | 27 +++++++++++++++
 tools/puppet3/manifests/nodes/nodejs.pp    | 27 +++++++++++++++
 tools/puppet3/manifests/nodes/php.pp       | 32 ++++++++++++++++++
 tools/puppet3/manifests/nodes/ruby.pp      | 26 +++++++++++++++
 tools/puppet3/manifests/nodes/tomcat.pp    | 28 ++++++++++++++++
 tools/puppet3/manifests/nodes/wordpress.pp | 26 +++++++++++++++
 tools/puppet3/manifests/php.pp             | 32 ------------------
 tools/puppet3/manifests/ruby.pp            | 26 ---------------
 tools/puppet3/manifests/site.pp            | 33 +++++++++++++++++++
 tools/puppet3/manifests/tomcat.pp          | 28 ----------------
 tools/puppet3/manifests/wordpress.pp       | 26 ---------------
 tools/puppet3/puppet.conf                  |  3 +-
 23 files changed, 336 insertions(+), 286 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/base.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/base.pp b/tools/puppet3/manifests/base.pp
deleted file mode 100755
index 5722073..0000000
--- a/tools/puppet3/manifests/base.pp
+++ /dev/null
@@ -1,44 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-# 
-#   http://www.apache.org/licenses/LICENSE-2.0
-# 
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# Stratos base node
-node 'base' {
-
-  #essential variables
-  $package_repo         = 'http://10.4.128.7'
-  $local_package_dir    = '/mnt/packs'
-  $mb_ip                = '127.0.0.1'
-  $mb_port              = '61616'
-  $mb_type		= 'activemq' #in wso2 mb case, value should be 'wso2mb'
-  $cep_ip               = '127.0.0.1'
-  $cep_port             = '7611'
-  $truststore_password  = 'wso2carbon'
-  $java_distribution	= 'jdk-7u51-linux-x64.tar.gz'
-  $java_name		= 'jdk1.7.0_51'
-  $member_type_ip       = 'private'
-  $lb_httpPort          = '80'
-  $lb_httpsPort         = '443'
-  $tomcat_version       = '7.0.52'
-  $enable_log_publisher = 'false'
-  $bam_ip		= '127.0.0.1'
-  $bam_port		= '7611'
-  $bam_secure_port	= '7711'
-  $bam_username		= 'admin'
-  $bam_password		= 'admin'
-
-  require stratos_base 
-}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/default.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/default.pp b/tools/puppet3/manifests/default.pp
deleted file mode 100755
index 1708013..0000000
--- a/tools/puppet3/manifests/default.pp
+++ /dev/null
@@ -1,24 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-# 
-#   http://www.apache.org/licenses/LICENSE-2.0
-# 
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# default (base) cartridge node
-node /default/ inherits base {
-  require java
-  class {'agent':}
-
-  Class['stratos_base'] -> Class['java'] ~> Class['agent']
-}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/haproxy.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/haproxy.pp b/tools/puppet3/manifests/haproxy.pp
deleted file mode 100755
index abce18b..0000000
--- a/tools/puppet3/manifests/haproxy.pp
+++ /dev/null
@@ -1,25 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-# 
-#   http://www.apache.org/licenses/LICENSE-2.0
-# 
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# haproxy extension loadbalancer cartridge node
-node /haproxy/ inherits base {
-  require java
-  class {'haproxy':}
-  class {'agent':}
-
-  Class['stratos_base'] -> Class['java'] -> Class['haproxy'] ~> Class['agent']
-}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/lb.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/lb.pp b/tools/puppet3/manifests/lb.pp
deleted file mode 100755
index 3faa7d9..0000000
--- a/tools/puppet3/manifests/lb.pp
+++ /dev/null
@@ -1,25 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-# 
-#   http://www.apache.org/licenses/LICENSE-2.0
-# 
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# loadbalancer cartridge node
-node /lb/ inherits base {
-  require java
-  class {'agent':}
-  class {'lb': maintenance_mode   => 'norestart'}
-
-  Class['stratos_base'] -> Class['java'] -> Class['lb'] ~> Class['agent']
-}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/mysql.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/mysql.pp b/tools/puppet3/manifests/mysql.pp
deleted file mode 100755
index 9b62f7e..0000000
--- a/tools/puppet3/manifests/mysql.pp
+++ /dev/null
@@ -1,27 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-# 
-#   http://www.apache.org/licenses/LICENSE-2.0
-# 
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# mysql cartridge node
-node /mysql/ inherits base {
-  require java
-  class {'agent':
-    type => 'mysql',
-  }
-  class {'mysql':}
-
-  Class['stratos_base'] -> Class['java'] -> Class['mysql'] ~> Class['agent']
-}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodejs.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodejs.pp b/tools/puppet3/manifests/nodejs.pp
deleted file mode 100755
index e99cbc8..0000000
--- a/tools/puppet3/manifests/nodejs.pp
+++ /dev/null
@@ -1,27 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-# 
-#   http://www.apache.org/licenses/LICENSE-2.0
-# 
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# nodejs cartridge node
-node /nodejs/ inherits base {
-  require java
-  class {'agent':
-    type => 'nodejs',
-  }
-  class {'nodejs':}
-
-  Class['stratos_base'] -> Class['java'] -> Class['nodejs'] ~> Class['agent']
-}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes.pp b/tools/puppet3/manifests/nodes.pp
new file mode 100644
index 0000000..701b541
--- /dev/null
+++ b/tools/puppet3/manifests/nodes.pp
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# Stratos Puppet nodes defnitions

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes/base.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes/base.pp b/tools/puppet3/manifests/nodes/base.pp
new file mode 100755
index 0000000..5722073
--- /dev/null
+++ b/tools/puppet3/manifests/nodes/base.pp
@@ -0,0 +1,44 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# Stratos base node
+node 'base' {
+
+  #essential variables
+  $package_repo         = 'http://10.4.128.7'
+  $local_package_dir    = '/mnt/packs'
+  $mb_ip                = '127.0.0.1'
+  $mb_port              = '61616'
+  $mb_type		= 'activemq' #in wso2 mb case, value should be 'wso2mb'
+  $cep_ip               = '127.0.0.1'
+  $cep_port             = '7611'
+  $truststore_password  = 'wso2carbon'
+  $java_distribution	= 'jdk-7u51-linux-x64.tar.gz'
+  $java_name		= 'jdk1.7.0_51'
+  $member_type_ip       = 'private'
+  $lb_httpPort          = '80'
+  $lb_httpsPort         = '443'
+  $tomcat_version       = '7.0.52'
+  $enable_log_publisher = 'false'
+  $bam_ip		= '127.0.0.1'
+  $bam_port		= '7611'
+  $bam_secure_port	= '7711'
+  $bam_username		= 'admin'
+  $bam_password		= 'admin'
+
+  require stratos_base 
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes/default.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes/default.pp b/tools/puppet3/manifests/nodes/default.pp
new file mode 100755
index 0000000..1708013
--- /dev/null
+++ b/tools/puppet3/manifests/nodes/default.pp
@@ -0,0 +1,24 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# default (base) cartridge node
+node /default/ inherits base {
+  require java
+  class {'agent':}
+
+  Class['stratos_base'] -> Class['java'] ~> Class['agent']
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes/haproxy.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes/haproxy.pp b/tools/puppet3/manifests/nodes/haproxy.pp
new file mode 100755
index 0000000..abce18b
--- /dev/null
+++ b/tools/puppet3/manifests/nodes/haproxy.pp
@@ -0,0 +1,25 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# haproxy extension loadbalancer cartridge node
+node /haproxy/ inherits base {
+  require java
+  class {'haproxy':}
+  class {'agent':}
+
+  Class['stratos_base'] -> Class['java'] -> Class['haproxy'] ~> Class['agent']
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes/lb.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes/lb.pp b/tools/puppet3/manifests/nodes/lb.pp
new file mode 100755
index 0000000..3faa7d9
--- /dev/null
+++ b/tools/puppet3/manifests/nodes/lb.pp
@@ -0,0 +1,25 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# loadbalancer cartridge node
+node /lb/ inherits base {
+  require java
+  class {'agent':}
+  class {'lb': maintenance_mode   => 'norestart'}
+
+  Class['stratos_base'] -> Class['java'] -> Class['lb'] ~> Class['agent']
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes/mysql.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes/mysql.pp b/tools/puppet3/manifests/nodes/mysql.pp
new file mode 100755
index 0000000..9b62f7e
--- /dev/null
+++ b/tools/puppet3/manifests/nodes/mysql.pp
@@ -0,0 +1,27 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# mysql cartridge node
+node /mysql/ inherits base {
+  require java
+  class {'agent':
+    type => 'mysql',
+  }
+  class {'mysql':}
+
+  Class['stratos_base'] -> Class['java'] -> Class['mysql'] ~> Class['agent']
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes/nodejs.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes/nodejs.pp b/tools/puppet3/manifests/nodes/nodejs.pp
new file mode 100755
index 0000000..e99cbc8
--- /dev/null
+++ b/tools/puppet3/manifests/nodes/nodejs.pp
@@ -0,0 +1,27 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# nodejs cartridge node
+node /nodejs/ inherits base {
+  require java
+  class {'agent':
+    type => 'nodejs',
+  }
+  class {'nodejs':}
+
+  Class['stratos_base'] -> Class['java'] -> Class['nodejs'] ~> Class['agent']
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes/php.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes/php.pp b/tools/puppet3/manifests/nodes/php.pp
new file mode 100755
index 0000000..da47e11
--- /dev/null
+++ b/tools/puppet3/manifests/nodes/php.pp
@@ -0,0 +1,32 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# php cartridge node
+node /php/ inherits base {
+  $docroot = "/var/www/"
+  $syslog="/var/log/apache2/error.log"
+  $samlalias="/var/www/"
+
+  require java
+  class {'agent':
+    type => 'php',
+  }
+  class {'php':}
+  
+  #install stratos_base before java before php before agent
+  Class['stratos_base'] -> Class['java'] -> Class['php'] ~> Class['agent']
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes/ruby.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes/ruby.pp b/tools/puppet3/manifests/nodes/ruby.pp
new file mode 100755
index 0000000..b4ade98
--- /dev/null
+++ b/tools/puppet3/manifests/nodes/ruby.pp
@@ -0,0 +1,26 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# ruby cartridge node
+node /ruby/ inherits base {
+  require java
+  class {'agent':
+  }
+  class {'ruby':}
+
+  Class['stratos_base'] -> Class['java'] -> Class['ruby'] ~> Class['agent']
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes/tomcat.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes/tomcat.pp b/tools/puppet3/manifests/nodes/tomcat.pp
new file mode 100755
index 0000000..8826d27
--- /dev/null
+++ b/tools/puppet3/manifests/nodes/tomcat.pp
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# tomcat cartridge node
+node /tomcat/ inherits base {
+  $docroot = "/mnt/apache-tomcat-${tomcat_version}/webapps/"
+  $samlalias="/mnt/apache-tomcat-${tomcat_version}/webapps/"
+
+  require java
+  class {'agent':}
+  class {'tomcat':}
+
+  Class['stratos_base'] -> Class['java'] -> Class['tomcat'] ~> Class['agent']
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/nodes/wordpress.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/nodes/wordpress.pp b/tools/puppet3/manifests/nodes/wordpress.pp
new file mode 100755
index 0000000..7233842
--- /dev/null
+++ b/tools/puppet3/manifests/nodes/wordpress.pp
@@ -0,0 +1,26 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+#wordpress cartridge node
+node /wordpress/ inherits base {
+  require java
+  class {'agent':}
+  class {'wordpress':}
+  class {'mysql':}
+
+  Class['stratos_base'] -> Class['java'] -> Class['mysql'] -> Class['wordpress'] ~> Class['agent']
+}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/php.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/php.pp b/tools/puppet3/manifests/php.pp
deleted file mode 100755
index da47e11..0000000
--- a/tools/puppet3/manifests/php.pp
+++ /dev/null
@@ -1,32 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-# 
-#   http://www.apache.org/licenses/LICENSE-2.0
-# 
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# php cartridge node
-node /php/ inherits base {
-  $docroot = "/var/www/"
-  $syslog="/var/log/apache2/error.log"
-  $samlalias="/var/www/"
-
-  require java
-  class {'agent':
-    type => 'php',
-  }
-  class {'php':}
-  
-  #install stratos_base before java before php before agent
-  Class['stratos_base'] -> Class['java'] -> Class['php'] ~> Class['agent']
-}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/ruby.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/ruby.pp b/tools/puppet3/manifests/ruby.pp
deleted file mode 100755
index b4ade98..0000000
--- a/tools/puppet3/manifests/ruby.pp
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-# 
-#   http://www.apache.org/licenses/LICENSE-2.0
-# 
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# ruby cartridge node
-node /ruby/ inherits base {
-  require java
-  class {'agent':
-  }
-  class {'ruby':}
-
-  Class['stratos_base'] -> Class['java'] -> Class['ruby'] ~> Class['agent']
-}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/site.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/site.pp b/tools/puppet3/manifests/site.pp
new file mode 100644
index 0000000..5404576
--- /dev/null
+++ b/tools/puppet3/manifests/site.pp
@@ -0,0 +1,33 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+# 
+#   http://www.apache.org/licenses/LICENSE-2.0
+# 
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+# import Stratos cartridge nodes definitions
+import 'nodes/base.pp'
+import 'nodes/haproxy.pp'
+import 'nodes/lb.pp'
+import 'nodes/mysql.pp'
+import 'nodes/nodejs.pp'
+import 'nodes/php.pp'
+import 'nodes/ruby.pp'
+import 'nodes/tomcat.pp'
+import 'nodes/wordpress.pp'
+
+# import a single manifest file with node definitions
+import 'nodes.pp'
+
+# import default cartridge definition at the last
+import 'nodes/default.pp'

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/tomcat.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/tomcat.pp b/tools/puppet3/manifests/tomcat.pp
deleted file mode 100755
index 8826d27..0000000
--- a/tools/puppet3/manifests/tomcat.pp
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-# 
-#   http://www.apache.org/licenses/LICENSE-2.0
-# 
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-# tomcat cartridge node
-node /tomcat/ inherits base {
-  $docroot = "/mnt/apache-tomcat-${tomcat_version}/webapps/"
-  $samlalias="/mnt/apache-tomcat-${tomcat_version}/webapps/"
-
-  require java
-  class {'agent':}
-  class {'tomcat':}
-
-  Class['stratos_base'] -> Class['java'] -> Class['tomcat'] ~> Class['agent']
-}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/manifests/wordpress.pp
----------------------------------------------------------------------
diff --git a/tools/puppet3/manifests/wordpress.pp b/tools/puppet3/manifests/wordpress.pp
deleted file mode 100755
index 7233842..0000000
--- a/tools/puppet3/manifests/wordpress.pp
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements.  See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership.  The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License.  You may obtain a copy of the License at
-# 
-#   http://www.apache.org/licenses/LICENSE-2.0
-# 
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied.  See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-#wordpress cartridge node
-node /wordpress/ inherits base {
-  require java
-  class {'agent':}
-  class {'wordpress':}
-  class {'mysql':}
-
-  Class['stratos_base'] -> Class['java'] -> Class['mysql'] -> Class['wordpress'] ~> Class['agent']
-}

http://git-wip-us.apache.org/repos/asf/stratos/blob/0c8318be/tools/puppet3/puppet.conf
----------------------------------------------------------------------
diff --git a/tools/puppet3/puppet.conf b/tools/puppet3/puppet.conf
index 9ef66db..a2ba7cc 100644
--- a/tools/puppet3/puppet.conf
+++ b/tools/puppet3/puppet.conf
@@ -16,6 +16,7 @@
 # under the License.
 
 [main]
+#server=puppet
 logdir=/var/log/puppet
 vardir=/var/lib/puppet
 ssldir=/var/lib/puppet/ssl
@@ -28,5 +29,3 @@ templatedir=$confdir/templates
 # and can safely be removed if webrick is used.
 ssl_client_header = SSL_CLIENT_S_DN 
 ssl_client_verify_header = SSL_CLIENT_VERIFY
-manifest = $confdir/manifests
-


[2/2] git commit: Merge branch 'master' of github.com:apache/stratos

Posted by ch...@apache.org.
Merge branch 'master' of github.com:apache/stratos


Project: http://git-wip-us.apache.org/repos/asf/stratos/repo
Commit: http://git-wip-us.apache.org/repos/asf/stratos/commit/2bab7e45
Tree: http://git-wip-us.apache.org/repos/asf/stratos/tree/2bab7e45
Diff: http://git-wip-us.apache.org/repos/asf/stratos/diff/2bab7e45

Branch: refs/heads/master
Commit: 2bab7e453eb58248e9878ff0306c4f18884b08a0
Parents: 0c8318b 39f4a8f
Author: Akila Perera <ra...@gmail.com>
Authored: Fri Jul 4 13:02:51 2014 +0530
Committer: Akila Perera <ra...@gmail.com>
Committed: Fri Jul 4 13:02:51 2014 +0530

----------------------------------------------------------------------
 .../distribution/src/main/conf/log4j.properties |  4 +-
 tools/puppet3/manifests/nodes/php.pp            |  2 +-
 tools/puppet3/modules/haproxy/files/README.txt  | 12 +++
 tools/puppet3/modules/haproxy/manifests/init.pp | 70 ++++++++++++++++++
 .../modules/haproxy/manifests/initialize.pp     | 77 ++++++++++++++++++++
 .../modules/haproxy/manifests/push_templates.pp | 30 ++++++++
 .../puppet3/modules/haproxy/manifests/start.pp  | 25 +++++++
 .../templates/bin/haproxy-extension.sh.erb      | 48 ++++++++++++
 .../haproxy/templates/conf/jndi.properties.erb  | 33 +++++++++
 9 files changed, 299 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/stratos/blob/2bab7e45/tools/puppet3/manifests/nodes/php.pp
----------------------------------------------------------------------
diff --cc tools/puppet3/manifests/nodes/php.pp
index da47e11,0000000..f16b9fd
mode 100755,000000..100755
--- a/tools/puppet3/manifests/nodes/php.pp
+++ b/tools/puppet3/manifests/nodes/php.pp
@@@ -1,32 -1,0 +1,32 @@@
 +# Licensed to the Apache Software Foundation (ASF) under one
 +# or more contributor license agreements.  See the NOTICE file
 +# distributed with this work for additional information
 +# regarding copyright ownership.  The ASF licenses this file
 +# to you under the Apache License, Version 2.0 (the
 +# "License"); you may not use this file except in compliance
 +# with the License.  You may obtain a copy of the License at
 +# 
 +#   http://www.apache.org/licenses/LICENSE-2.0
 +# 
 +# Unless required by applicable law or agreed to in writing,
 +# software distributed under the License is distributed on an
 +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 +# KIND, either express or implied.  See the License for the
 +# specific language governing permissions and limitations
 +# under the License.
 +
 +# php cartridge node
 +node /php/ inherits base {
-   $docroot = "/var/www/"
++  $docroot = "/var/www/www"
 +  $syslog="/var/log/apache2/error.log"
 +  $samlalias="/var/www/"
 +
 +  require java
 +  class {'agent':
 +    type => 'php',
 +  }
 +  class {'php':}
 +  
 +  #install stratos_base before java before php before agent
 +  Class['stratos_base'] -> Class['java'] -> Class['php'] ~> Class['agent']
 +}