bitrise-io/step-agent-go

Name: step-agent-go

Owner: Bitrise

Description: step agent rewrite in go

Created: 2014-07-08 06:14:34.0

Updated: 2015-05-04 16:38:46.0

Pushed: 2015-05-04 16:38:46.0

Homepage: null

Size: 4188

Language: Go

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

step-agent-go

step agent rewrite in go

Purpose of this tool

This tool is meant to be a “command receiver”, designed to perform StepLib steps on a remote host, mostly through SSH.

How it works

To make it easier to send complex parameters for the remote command and to simplify the control of Environment Variable expansion in paths and parameters (meaning: easier control over where the Environment Variable expansion happens, on the host or on the remote end) this tool expects all of it's inputs in Base64 encoded form.

Environment variable pairs are specified the following way (the key and value of a pair is separated with a dot, and key-value pairs are separated with a comma):

key1-base64-encoded.value1-base64-encoded,key2-base64-encoded.value2-base64-encoded

For example to run a script on the remote end, where the script is located at ${HOME}/my_script.sh (HOME: the home folder path on the remote end) with two environment variable pairs specified for the script, for example MYVAR1=first and MYVAR2=second, you can call this tool:

step_agent_osx -steppath="JHtIT01FfS9teV9zY3JpcHQuc2g=" -stepenvs=TVlWQVIx.Zmlyc3Q=,TVlWQVIy.c2Vjb25k
Release:

To create a new release:

  1. bump version in version.go
  2. commit
  3. run $ bash release_test.sh
  4. if prints an error fix it, and run it again while you get an error
  5. tag the new release in git

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.