Skip to content

Commit

Permalink
first commit
Browse files Browse the repository at this point in the history
  • Loading branch information
ahonor committed Jul 12, 2017
0 parents commit 635996e
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 0 deletions.
14 changes: 14 additions & 0 deletions contents/run-script
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/usr/bin/env bash
#
# Fail immediately on error or undefined variables
set -eu
# Create a temp file for the script text
declare -r SCRIPT=$(mktemp -t "local-script.XXXX")
trap 'rm "$SCRIPT"' EXIT; # remove temp file on exit
# Write the script text to the temp file.
cat > "$SCRIPT" <<< "$RD_CONFIG_SCRIPT"
# Make the script executable
chmod +x "$SCRIPT"
# Execute the script with arguments
exec "$SCRIPT" "${RD_CONFIG_ARGUMENTS:-}"
# Done
26 changes: 26 additions & 0 deletions plugin.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: nixy-local-script
rundeckPluginVersion: 1.2
author: (C) Alex Honor
date: 07/11/2017
version: 1.0.0
providers:
- name: nixy-local-script-step
service: WorkflowNodeStep
title: 'Local Script'
description: Run a script locally on the server per node
plugin-type: script
script-interpreter: /usr/bin/env bash
script-file: run-script
script-args:
config:
- name: script
title: Script
type: String
required: true
renderingOptions:
displayType: CODE
codeSyntaxMode: shell
- name: arguments
title: Arguments
type: String
required: false
Binary file added resources/icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 635996e

Please sign in to comment.