This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Delete all services in an ECS Cluster using boto3. | |
Requires listing all services in a cluster, setting their desired tasks to 0, | |
then deleting the service. | |
""" | |
import boto3 | |
CLUSTER_NAME = 'your-cluster-here' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
from requests.auth import HTTPBasicAuth | |
import re | |
from StringIO import StringIO | |
JIRA_URL = 'https://your-jira-url.tld/' | |
JIRA_ACCOUNT = ('jira-username', 'jira-password') | |
# the JIRA project ID (short) | |
JIRA_PROJECT = 'PRO' | |
GITLAB_URL = 'http://your-gitlab-url.tld/' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
INTERVAL=2s | |
queues=$(aws sqs list-queues | jq -r '.QueueUrls[]') | |
queue_url=$(echo "$queues" | egrep "\/$1\$") | |
if [ -z $queue_url ] | |
then | |
>&2 echo "invalid queue name" | |
exit 1 | |
fi | |
declare -a y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Copies all keys from the source Redis host to the destination Redis host. | |
Useful to migrate Redis instances where commands like SLAVEOF and MIGRATE are | |
restricted (e.g. on Amazon ElastiCache). | |
The script scans through the keyspace of the given database number and uses | |
a pipeline of DUMP and RESTORE commands to migrate the keys. | |
Requires Redis 2.8.0 or higher. |