Centralize Red Hat configs
authorMathieu Baudier <mbaudier@argeo.org>
Thu, 1 Mar 2012 15:05:20 +0000 (15:05 +0000)
committerMathieu Baudier <mbaudier@argeo.org>
Thu, 1 Mar 2012 15:05:20 +0000 (15:05 +0000)
git-svn-id: https://svn.argeo.org/slc/trunk@5120 4cfe0d0a-d680-48aa-b62c-e0a02a3f76cc

runtime/org.argeo.slc.support.simple/src/main/resources/org/argeo/slc/lib/linux/redhat.xml [new file with mode: 0644]

diff --git a/runtime/org.argeo.slc.support.simple/src/main/resources/org/argeo/slc/lib/linux/redhat.xml b/runtime/org.argeo.slc.support.simple/src/main/resources/org/argeo/slc/lib/linux/redhat.xml
new file mode 100644 (file)
index 0000000..5f0c46d
--- /dev/null
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>\r
+<beans xmlns="http://www.springframework.org/schema/beans"\r
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p"\r
+       xmlns:aop="http://www.springframework.org/schema/aop" xmlns:flow="http://www.argeo.org/schema/slc-flow"\r
+       xsi:schemaLocation="\r
+       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd\r
+       http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.5.xsd\r
+       http://www.argeo.org/schema/slc-flow http://www.argeo.org/schema/slc-flow-0.12.xsd">\r
+\r
+       <bean id="hostManager" class="org.argeo.slc.lib.linux.RedhatHostManager">\r
+               <property name="sshTarget" ref="sshTarget" />\r
+               <property name="host" ref="host" />\r
+       </bean>\r
+\r
+       <bean flow:as-flow="deployConfig" class="org.argeo.slc.core.execution.tasks.MethodCall"\r
+               p:target-ref="hostManager" p:method="deployConfig" />\r
+\r
+       <bean flow:as-flow="system/reboot" p:command="shutdown -r now"\r
+               p:sshTarget-ref="sshTarget" class="org.argeo.slc.jsch.RemoteExec" />\r
+\r
+       <bean flow:as-flow="system/shutdown" p:command="shutdown -h now"\r
+               p:sshTarget-ref="sshTarget" class="org.argeo.slc.jsch.RemoteExec" />\r
+\r
+       <bean flow:as-flow="system/packages/install" class="org.argeo.slc.core.execution.tasks.MethodCall"\r
+               p:target-ref="hostManager" p:method="installPackages" />\r
+\r
+       <bean flow:as-flow="system/packages/update" p:sshTarget-ref="sshTarget"\r
+               class="org.argeo.slc.jsch.RemoteExec">\r
+               <property name="systemCall">\r
+                       <bean class="org.argeo.slc.core.execution.tasks.SystemCall">\r
+                               <property name="cmd" value="yum -y update" />\r
+                       </bean>\r
+               </property>\r
+       </bean>\r
+\r
+       <bean flow:as-flow="system/security/firewall" p:script="osgibundle:/scripts/firewall.sh"\r
+               p:sshTarget-ref="sshTarget" class="org.argeo.slc.jsch.RemoteExec" />\r
+\r
+</beans>
\ No newline at end of file