Skip to content

Instantly share code, notes, and snippets.

View aswinkm-tc's full-sized avatar

Aswin K.M. aswinkm-tc

  • Truecaller
  • Sweden
  • 13:46 (UTC +02:00)
View GitHub Profile
#! /bin/sh
### BEGIN INIT INFO
# Provides: nginx
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: nginx init.d dash script for Ubuntu or other *nix.
# Description: nginx init.d dash script for Ubuntu or other *nix.
### END INIT INFO
#!/bin/bash -e
if [ -z "$1" ]; then
exit 1
fi
# source configuration if it exists
[ -f /etc/aws-ec2-ssh.conf ] && . /etc/aws-ec2-ssh.conf
# Assume a role before contacting AWS IAM to get users and keys.
#!/bin/bash -e
# source configuration if it exists
[ -f /etc/aws-ec2-ssh.conf ] && . /etc/aws-ec2-ssh.conf
# Should we actually do something?
: ${DONOTSYNC:=0}
if [ ${DONOTSYNC} -eq 1 ]
then