Sha256: 84d0eba5d0dfbc1c752d0b46c70b4dbc91981eb2d36c4f1a2dcf22eb410e17a0

Contents?: true

Size: 922 Bytes

Versions: 57

Compression:

Stored size: 922 Bytes

Contents

#!/bin/bash

#/ NAME
#/     remote -- connects to a remote server
#/
#/ SYNOPSIS
#/     remote hostname ... any ssh args

# figure out the project root under which bin, lib live
shome="$(cd -P -- "$(dirname -- "$0")/.." && pwd -P)"

# load a jason bourne library
source "$shome/libexec/_treadstone" "$@"
get_started

# entry point
function main {
  if [[ "$#" = 0 ]]; then
    logger_fatal "need a hostname or podname"
    exit 1
  fi

  local nm_component="$1"; shift
  local deploy_base="$(ryaml $_AO_HOME/config/deploy.yml deploy_base)"
  if [[ -n "$deploy_base" ]]; then
    local pod_shortcut="$(ryaml $HOME/.getting-started/config/pods.yml pods ${deploy_base}${nm_component} pod)"
    if [[ -n "$pod_shortcut" ]]; then
      nm_component="${deploy_base}${nm_component}"
    fi
  fi

  exec ssh "$nm_component" "$@"
  logger_fatal "could not execute ssh; this is abnormal"
  exit 1
}

require sub "$BASH_SOURCE" "$@"

Version data entries

57 entries across 57 versions & 1 rubygems

Version Path
alpha_omega-1.5.10 libexec/aoh-remote
alpha_omega-1.5.9 libexec/aoh-remote
alpha_omega-1.5.8 libexec/aoh-remote
alpha_omega-1.5.7 libexec/aoh-remote
alpha_omega-1.5.6 libexec/aoh-remote
alpha_omega-1.5.4 libexec/aoh-remote
alpha_omega-1.5.3 libexec/aoh-remote
alpha_omega-1.5.2 libexec/aoh-remote
alpha_omega-1.5.1 libexec/aoh-remote
alpha_omega-1.5.0 libexec/aoh-remote
alpha_omega-1.3.48 libexec/aoh-remote
alpha_omega-1.3.47 libexec/aoh-remote
alpha_omega-1.3.46 libexec/aoh-remote
alpha_omega-1.3.45 libexec/aoh-remote
alpha_omega-1.3.44 libexec/aoh-remote
alpha_omega-1.3.43 libexec/aoh-remote
alpha_omega-1.3.42 libexec/aoh-remote
alpha_omega-1.3.41 libexec/aoh-remote
alpha_omega-1.3.40 libexec/aoh-remote
alpha_omega-1.3.39 libexec/aoh-remote