seek-oss / aec Goto Github PK
View Code? Open in Web Editor NEWAWS EC2 CLI - easily work with ec2 instances via the cli 🐶
License: MIT License
AWS EC2 CLI - easily work with ec2 instances via the cli 🐶
License: MIT License
Some users expect the AEC --profile
to be the same as the AWS profile located in ~/.aws/config
users shouldn't have to clone the repo to install the example config, there should be a CLI command that does this
it should also be possible to install a shared repo with config into ~/.aec/
The positional argument args
isn't used and confuses users:
Usage: ec2 describe [-h] [--name NAME] [--profile PROFILE] [args [args ...]]
List EC2 instances in the region
positional arguments:
args -
optional arguments:
-h, --help show this help message and exit
--name NAME Filter to hosts with this Name tag (default: -)
--profile PROFILE Profile in the config file to use (default: 'default')
....
Configuration values can currently be specified in one of the following places:
additional_tags
region
ami
To provide greater flexibility, allow any configuration value to be specified at any level, with lower levels taking precedence.
and cache the list
Installing:
» pipx install aec-cli
installed package aec-cli 0.9.0, Python 3.9.5
These apps are now globally available
- aec
done! ✨ 🌟 ✨
Running the configure example
:
» aec configure example
Traceback (most recent call last):
File "/<HOME>/.local/bin/aec", line 8, in <module>
sys.exit(main())
File "/<HOME>/.local/pipx/venvs/aec-cli/lib/python3.9/site-packages/aec/main.py", line 129, in main
result = cli.dispatch(build_parser(), args)
File "/<HOME>/.local/pipx/venvs/aec-cli/lib/python3.9/site-packages/aec/util/cli.py", line 87, in dispatch
return call_me(**vars(pargs))
File "/<HOME>/.local/pipx/venvs/aec-cli/lib/python3.9/site-packages/aec/util/configure.py", line 11, in example
with resources.path("aec", "config-example") as example_path:
File "/usr/local/Cellar/[email protected]/3.9.5/Frameworks/Python.framework/Versions/3.9/lib/python3.9/contextlib.py", line 117, in __enter__
return next(self.gen)
File "/usr/local/Cellar/[email protected]/3.9.5/Frameworks/Python.framework/Versions/3.9/lib/python3.9/importlib/resources.py", line 175, in _path_from_reader
opener_reader = reader.open_resource(norm_resource)
File "<frozen importlib._bootstrap_external>", line 1060, in open_resource
IsADirectoryError: [Errno 21] Is a directory: '/<HOME>/.local/pipx/venvs/aec-cli/lib/python3.9/site-packages/aec/config-example'
Sometimes the output of ec2 describe
wraps because of long instance names.
Would be nice to have a format cli option
eg: docker using gotemplate to reformat output and truncate the Name to 25 chars
docker stats --format "table {{printf \"%.25s\" .Name}}\t{{.CPUPerc}}\t{{.MemUsage}}\t{{.NetIO}}\t{{.BlockIO}}"
I am using aec via a bash script, which because of a configuration error executed aec ec2 terminate "$instanceId"
with an empty $instanceId
.
This had the rather unfortunate effect of terminating all of the ec2 instances visible to my role in the selected region. Looking at ec2.py
it looks like the empty name
argument was passed through to describe which happily returned all of the instances which where then deleted.
I think that terminate (and probably start and stop) should probably refuse to operate on more than one instance at a time, or alternatively guard against an empty name filter.
ec2 describe
needs the region. Having to configure this for every potential account/region combination in addition to ~/.aws/config seems redundant.
Instead just use the already configured region in ~/.aws/config or environment variables.
At the moment additional_tags applies to all profiles
Dependabot can't evaluate your Python dependency files.
As a result, Dependabot couldn't check whether any of your dependencies are out-of-date.
The error Dependabot encountered was:
InstallationError("Invalid requirement: '[email protected]' (from line 1 of /home/dependabot/dependabot-updater/dependabot_tmp_dir/requirements.node.dev.txt)")
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.