Skip to content

Instantly share code, notes, and snippets.

# How get just the file name from the glob and not the path?
- name: "Copy newly built jar file"
copy: src={{ item }}
dest={{ push_dir }}/
owner={{ cf_user }}
group={{ cf_group }}
mode=640
with_fileglob:
- "{{ WORKSPACE }}/target/*.jar"
@neilhwatson
neilhwatson / urltest.pl
Last active January 12, 2016 01:00
URL test script
#!/usr/bin/perl
=pod
=head1 SYNOPSIS
Test the contents of a URL using Mojo::UserAgent.
=cut
body common control
{
custom::
bundlesequence => { "custom", };
!custom::
bundlesequence => { "main", };
}
bundle agent main
{
@neilhwatson
neilhwatson / efl.cf
Created July 29, 2015 13:52
autorun file
bo dy file control {
inputs => {
@{efl_inputs.files},
"list_backup.cf",
};
}
bundle common efl_inputs {
meta:
'tags' slist => { 'autorun' };
CFE policy:
body common control
{
bundlesequence => { holder, test_datastate_mustache };
}
bundle common holder
{
classes:
@neilhwatson
neilhwatson / gist:4b01b0c86c84cba6eef7
Created July 15, 2015 12:29
data processing for rlinder
neil@ettin ~/.cfagent/inputs $ cat rlinder.cf
body common control
{
bundlesequence => {
"main",
};
}
bundle agent main
{
Why is the number prefix in the class not printed?
neil@ettin ~/.cfagent/inputs $ cat yaml.yaml
- bundle: efl_test_simple
class: 1003_efl_test
ifelapsed: 1
parameter: ../1003/15_efl_test_simple.yaml
promisee: efl development
promiser: Testing main bundle order
- bundle: efl_test_simple
@neilhwatson
neilhwatson / gist:a3f4a26ad8cf27d62307
Last active August 29, 2015 14:22
A serverspec example that should ssh to a remote host but connects to localhost instead.
newatson@ltipc682:~/src/serverspec/test$ find
.
./spec
./spec/atlspf01
./spec/atlspf01/sample_spec.rb
./spec/spec_helper.rb
./Rakefile
./.rspec
newatson@ltipc682:~/src/serverspec/test$ cat Rakefile
body common control
{
bundlesequence => {
"main",
};
}
bundle agent main
{
methods:
@neilhwatson
neilhwatson / gist:da3176a83d397600bfca
Last active August 29, 2015 14:22
merging containers to get a single list
body common control
{
bundlesequence => {
"main",
};
}
bundle agent main
{
methods: