# install
$sudo apt install default-jre graphviz
$ wget -O plantuml.jar http://sourceforge.net/projects/plantuml/files/plantuml.jar/download
# test
$ cat > test.txt <<EOF
@startuml
Alice -> Bob: test
@enduml
This file contains hidden or 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
| ''' | |
| $ pip freeze | grep ruamel.yaml | |
| ruamel.yaml==0.16.10 | |
| ruamel.yaml.clib==0.2.0 | |
| ''' | |
| import base64 | |
| from pathlib import Path | |
| import sys | |
| import ruamel.yaml |
This file contains hidden or 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 paho.mqtt.client as mqtt | |
| import ssl | |
| import sys | |
| import time | |
| MQTT_HOST = sys.argv[1] | |
| MQTT_PORT = int(sys.argv[2]) | |
| MQTT_USERNAME = sys.argv[3] | |
| MQTT_PASSWORD = sys.argv[4] |
This file contains hidden or 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 sys | |
| import boto3 | |
| import troposphere | |
| from troposphere.elasticbeanstalk import ( | |
| ConfigurationTemplate, | |
| OptionSettings, | |
| ) | |
This file contains hidden or 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 boto3 | |
| import sys | |
| import pprint | |
| from dictdiffer import diff | |
| app = sys.argv[1] | |
| env1 = sys.argv[2] | |
| env2 = sys.argv[3] |
This file contains hidden or 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 boto3 | |
| import sys | |
| import pprint | |
| eb_app = sys.argv[1] | |
| eb_env_src = sys.argv[2] | |
| eb_env_dest= sys.argv[3] | |
| client = boto3.client('elasticbeanstalk') |
This file contains hidden or 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
| """ | |
| # Usage Example | |
| terraform state list|grep '-'|python terraform_state_mv.py | |
| """ | |
| import subprocess | |
| import sys | |
$ AWS_PROFILE=enm10k python describe_unattached_aws_security_group.py
sg-***
sg-***
...
NewerOlder