Access monitor: mysql -h [host] -u [username] -p
(will prompt for password)
Access database: mysql -h [host] -u [username] -p [database]
(will prompt for password)
Users functions
URL="http://stackoverflow.com/" | |
# store the whole response with the status at the and | |
HTTP_RESPONSE=$(curl --silent --write-out "HTTPSTATUS:%{http_code}" -X POST $URL) | |
# extract the body | |
HTTP_BODY=$(echo $HTTP_RESPONSE | sed -e 's/HTTPSTATUS\:.*//g') | |
# extract the status | |
HTTP_STATUS=$(echo $HTTP_RESPONSE | tr -d '\n' | sed -e 's/.*HTTPSTATUS://') |
import boto3 | |
from boto3.session import Session | |
role_arn = os.environ.get('ASSUME_ROLE') | |
if roleArn: | |
client = boto3.client('sts') | |
assumed_role = client.assume_role(RoleArn=roleArn, RoleSessionName='test') | |
session = Session(aws_access_key_id=assumed_role['Credentials']['AccessKeyId'], | |
aws_secret_access_key=assumed_role['Credentials']['SecretAccessKey'], |
sudo lsof -i:40025 |
# one or the other, NOT both | |
[url "https://github"] | |
insteadOf = git://github | |
# or | |
[url "git@github.com:"] | |
insteadOf = git://github |