Package org.jclouds.scriptbuilder.domain

Examples of org.jclouds.scriptbuilder.domain.StatementList


      /**
       * @see InitScript#getRun()
       */
      public Builder run(Statement... run) {
         this.run = new StatementList(checkNotNull(run, "run"));
         return this;
      }
View Full Code Here


      /**
       * @see InitScript#getRun()
       */
      public Builder run(Iterable<Statement> run) {
         this.run = new StatementList(checkNotNull(run, "run"));
         return this;
      }
View Full Code Here

      /**
       * @see InitScript#getInit()
       */
      public Builder init(Statement init) {
         this.init = new StatementList(checkNotNull(init, "init"));
         return this;
      }
View Full Code Here

      /**
       * @see InitScript#getInit()
       */
      public Builder init(Statement... init) {
         this.init = new StatementList(checkNotNull(init, "init"));
         return this;
      }
View Full Code Here

      /**
       * @see InitScript#getInit()
       */
      public Builder init(Iterable<Statement> init) {
         this.init = new StatementList(checkNotNull(init, "init"));
         return this;
      }
View Full Code Here

      Builder<Statement> statements = ImmutableSet.<Statement> builder();
      for (String module : allModules) {
         statements.add(statementMaker.apply(filterKeys(moduleProps, isModuleSubKey(module))));
      }
      StatementList installModules = new StatementList(statements.build());
      return installModules;
   }
View Full Code Here

            .updateExistingGems(bootstrapProperties.updateGems()) //
            .build();

      Statement installChef = InstallChefGems.builder().version(bootstrapProperties.chefVersion().orNull()).build();

      return new StatementList(InstallRuby.builder().build(), installRubyGems, installChef);
   }
View Full Code Here

   public static ScriptBuilder makeInitScriptStatement(String instanceName, String instanceHome, String logDir,
         Map<String, String> exports, StatementList init, StatementList run) {
      Map<String, String> defaultExports = ImmutableMap.of("INSTANCE_NAME", instanceName, "INSTANCE_HOME", instanceHome,
            "LOG_DIR", logDir);
      String exitStatusFile = format("%s/rc", logDir);
      run = new StatementList(ImmutableList.<Statement> builder().add(interpret("rm -f " + exitStatusFile))
            .add(interpret(format("trap 'echo $?>%s' 0 1 2 3 15", exitStatusFile))).addAll(run.delegate()).build());

      CreateRunScript createRunScript = createRunScript(instanceName,
            concat(exports.keySet(), defaultExports.keySet()), "{varl}INSTANCE_HOME{varr}", run);
View Full Code Here

      /**
       * @see InitScript#getRun()
       */
      public Builder run(Statement run) {
         this.run = new StatementList(checkNotNull(run, "run"));
         return this;
      }
View Full Code Here

      /**
       * @see InitScript#getRun()
       */
      public Builder run(Statement... run) {
         this.run = new StatementList(checkNotNull(run, "run"));
         return this;
      }
View Full Code Here

TOP

Related Classes of org.jclouds.scriptbuilder.domain.StatementList

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.