Create a new Role from a Policy with the following permissions:
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
| #!/bin/sh | |
| # | |
| # service-name Service Name and brief description | |
| # | |
| # chkconfig: 2345 96 06 | |
| # description: Service Name and brief description | |
| # processname: service-name | |
| ########################################################################### | |
| # Modify the below variables do determine how the service is run |
| case $- in | |
| *i*) | |
| # If $BASH is not defined then we're already in a Bash shell | |
| if [ -z "$BASH" ]; then | |
| BASH_BIN=$(command -v bash) | |
| # Ensure Bash is installed on the system, then switch shells | |
| if [ -x "$BASH_BIN" ]; then | |
| export SHELL="$BASH_BIN" | |
| exec "$BASH_BIN" | |
| fi |
| alias vi='vim' | |
| alias sudo='sudo ' | |
| alias which='type -a' | |
| alias path='echo -e ${PATH//:/\\n}' | |
| alias libpath='echo -e ${LD_LIBRARY_PATH//:/\\n}' | |
| alias du='du -kh' | |
| alias df='df -kTh' | |
| alias ..='cd ..' | |
| alias ...='cd ../..' |
| #include <dirent.h> | |
| #include <iterator> | |
| #include <cstdlib> | |
| #include <cstring> | |
| #include <sstream> | |
| #include <iostream> | |
| #include <stdlib.h> | |
| #include <string> | |
| #include <sys/stat.h> | |
| #include <syslog.h> |
| #!/usr/bin/env bash | |
| # Install Homebrew | |
| /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" | |
| # Install Homebase CLI | |
| mkdir -p /usr/local/opt | |
| git clone https://bitbucket.sparkcentral.ninja/scm/int/homebase-cli.git /usr/local/opt/homebase-cli | |
| ln -s /usr/local/opt/homebase-cli/bin/homebase-cli /usr/local/bin/homebase-cli |
The code for this service has been moved to this GitHub repository.
| # HOST="1.tcp.ngrok.io" PORT=12345 python server.py | |
| import os | |
| import socket | |
| from pyngrok import ngrok | |
| host = os.environ.get("HOST") | |
| port = int(os.environ.get("PORT")) |
| import os | |
| from http.server import HTTPServer, BaseHTTPRequestHandler | |
| from pyngrok import ngrok | |
| port = os.environ.get("PORT", "80") | |
| server_address = ("", port) | |
| httpd = HTTPServer(server_address, BaseHTTPRequestHandler) |