]> git.bundesbrandschatzamt.de Git - emacsconfig.git/commitdiff
more eshell aws yasnippets.
authorAndreas Gerler <baronNOSPAMbundesbrandschatzamt.de>
Wed, 13 Jan 2016 10:47:02 +0000 (11:47 +0100)
committerAndreas Gerler <baronNOSPAMbundesbrandschatzamt.de>
Wed, 13 Jan 2016 10:47:02 +0000 (11:47 +0100)
snippets/eshell-mode/aws-ec2-describe-instance-status [new file with mode: 0644]
snippets/eshell-mode/aws-ec2-get-console-output [new file with mode: 0644]
snippets/eshell-mode/aws-ec2-get-dns-names
snippets/eshell-mode/aws-ec2-get-instance-details
snippets/eshell-mode/aws-ec2-instance-running
snippets/eshell-mode/aws-ec2-start-stop-instance

diff --git a/snippets/eshell-mode/aws-ec2-describe-instance-status b/snippets/eshell-mode/aws-ec2-describe-instance-status
new file mode 100644 (file)
index 0000000..c2f54ca
--- /dev/null
@@ -0,0 +1,5 @@
+# -*- mode: snippet -*-
+# name: aws-ec2-describe-instance-status
+# key: aws-ec2-describe-instance-status
+# --
+aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ${2:--region=${3:$$(yas-choose-value bba-aws-regions)}} ec2 describe-instance-status --instance-ids ${2:`(yank)`} $0
\ No newline at end of file
diff --git a/snippets/eshell-mode/aws-ec2-get-console-output b/snippets/eshell-mode/aws-ec2-get-console-output
new file mode 100644 (file)
index 0000000..50b2e5b
--- /dev/null
@@ -0,0 +1,5 @@
+# -*- mode: snippet -*-
+# name: aws-ec2-get-console-output
+# key: aws-ec2-get-console-output
+# --
+aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ${2:--region=${3:$$(yas-choose-value bba-aws-regions)}} ec2 get-console-output --instance-id ${2:`(yank)`} $0
\ No newline at end of file
index 1548c51794081a3f1a9b0ee8635929f960948115..c604803aaafb9ce15e86aa6e0dc94d1a86010373 100644 (file)
@@ -2,4 +2,4 @@
 # name: aws-ec2-get-dns-names
 # key: aws-ec2-get-dns-names
 # --
-aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ec2 describe-instances --filters "Name=tag:Name,Values=$2" --query "Reservations[].Instances[?State.Name=='running'].[InstanceId, PublicDnsName]" --output ${3:$$(yas-choose-value '("table" "text" "json"))} $0
+aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ${2:--region=${3:$$(yas-choose-value bba-aws-regions)}} ec2 describe-instances --filters "Name=tag:Name,Values=$2" --query "Reservations[].Instances[?State.Name=='running'].[InstanceId, PublicDnsName]" --output ${3:$$(yas-choose-value '("table" "text" "json"))} $0
index 83d6e793edbdc91924116d04afaffbcd109b7b3d..af3d6e345a8538654ffdccb7c4a874202b510a23 100644 (file)
@@ -2,4 +2,4 @@
 # name: aws-ec2-get-instance-details
 # key: aws-ec2-get-instance-details
 # --
-aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ec2 describe-instances --instance-ids ${2:`(yank)`} $0
\ No newline at end of file
+aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ${2:--region=${3:$$(yas-choose-value bba-aws-regions)}} ec2 describe-instances --instance-ids ${2:`(yank)`} $0
\ No newline at end of file
index c12b789b2cff3f54bf553f620271329574fa04dd..3b953aa31ef51e10fce15c8d6755d6de10822551 100644 (file)
@@ -2,4 +2,4 @@
 # name: aws-ec2-instance-running
 # key: aws-ec2-instance-running
 # --
-aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ec2 describe-instances --instance-ids $2 --query "Reservations[].Instances[].[InstanceId, State.Name]" --output ${3:$$(yas-choose-value '("table" "text" "json"))} $0
+aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ${2:--region=${3:$$(yas-choose-value bba-aws-regions)}} ec2 describe-instances --instance-ids $2 --query "Reservations[].Instances[].[InstanceId, State.Name]" --output ${3:$$(yas-choose-value '("table" "text" "json"))} $0
index 8d29414d762541375e217792a6856781c79b6c34..7c63ed5ecaa53fb5bf18f6a89be6e0779ccfac63 100644 (file)
@@ -2,4 +2,4 @@
 # name: aws-ec2-start-stop-instance
 # key: aws-ec2-start_stop-instance
 # --
-aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ec2 ${2:$$(yas-choose-value '("start-instances" "stop-instances"))} --instance-ids ${3:`(yank)`} $0
\ No newline at end of file
+aws --profile=${1:$$(yas-choose-value '("prod" "test"))} ${2:--region=${3:$$(yas-choose-value bba-aws-regions)}} ec2 ${2:$$(yas-choose-value '("start-instances" "stop-instances"))} --instance-ids ${3:`(yank)`} $0
\ No newline at end of file