def findItem(key){
def defval='some value'
someMap.each{k,v->
if(k.startsWith(key)){
return v
}
| import java.security.*; | |
| def len=256 | |
| if(args.length>0){ | |
| len = Integer.parseInt(args[0]) | |
| } | |
| byte[] sharedKey = new byte[len] | |
| new SecureRandom().nextBytes(sharedKey) |
| @Grab('org.jasypt:jasypt:1.9.3') | |
| import org.jasypt.registry.AlgorithmRegistry | |
| @Grab('org.bouncycastle:bcprov-jdk15on:1.70') | |
| import org.bouncycastle.jce.provider.BouncyCastleProvider | |
| import java.security.Security | |
| Security.addProvider(new BouncyCastleProvider()); | |
| Set digestAlgos = AlgorithmRegistry.getAllDigestAlgorithms(); | |
| Set pbeAlgos = AlgorithmRegistry.getAllPBEAlgorithms(); |
Create a file logback.groovy as above.
Launch rundeck with the following jvm system property: logging.config=<path to logback.groovy>
for example:
java -Xmx4g -Dlogging.config=pwd/server/config/logback.groovy -jar rundeck-3.0.20-20190408.war
Goals:
Data passing: Workflow steps can export data values that are made available to subsequent steps. Data capture: Step logger system can filter/process output log events to extract useful data values and use the data passing feature to pass them along.
Tasks:
Data Passing:
| FROM ubuntu:16.04 | |
| RUN apt-get -y update && \ | |
| apt-get -y install openjdk-8-jdk apt-transport-https curl openssh-client uuid-runtime | |
| ENV RDECK_BASE=/var/lib/rundeck | |
| RUN mkdir $RDECK_BASE | |
| RUN echo "deb https://rundeck.bintray.com/rundeck-deb /" | tee -a /etc/apt/sources.list |
| [~/devel/test-g255] 💩 ls | |
| grails-2.5.5 grails-2.5.5.zip | |
| [~/devel/test-g255] 🍺 which grails | |
| /Users/greg/devel/test-g255/grails-2.5.5/bin/grails | |
| [~/devel/test-g255] 🍺 grails create-app --stacktrace | |
| | Configuring classpath | |
| :: problems summary :: | |
| :::: WARNINGS | |
| module not found: org.codehaus.groovy#groovy-all;2.4.4 | |
| ==== grailsPlugins: tried |
| @Grapes( | |
| @Grab(group='org.rundeck', module='rundeck-api-java-client', version='13.1') | |
| ) | |
| import org.rundeck.api.*; | |
| def rundeck = RundeckClient.builder().url(args[0]).login(args[1],args[2]).build() | |
| //def rundeck = RundeckClient.builder().url(args[0]).token(args[1]).build() | |
| def project=args[3] | |
| def jobs = rundeck.getJobs(project) |
| | Failure: edit page(domain.scheduledExecution.JobEditSpec) | |
| | java.lang.VerifyError: Bad <init> method call from inside of a branch | |
| Exception Details: | |
| Location: | |
| geb/navigator/SearchContextBasedBasicLocator.<init>(Lorg/openqa/selenium/SearchContext;Lgeb/navigator/factory/NavigatorFactory;)V @91: invokespecial | |
| Reason: | |
| Error exists in the bytecode | |
| Bytecode: | |
| 0000000: b800 214e 05bd 0004 5903 04bd 0004 5903 | |
| 0000010: 2b53 b800 2753 5904 2c53 5910 ff12 02b8 |