meshcloud / collie-cli Goto Github PK
View Code? Open in Web Editor NEWBuild and Deploy modular landing zones with collie on AWS, Azure & GCP
Home Page: https://collie.cloudfoundation.org
License: Apache License 2.0
Build and Deploy modular landing zones with collie on AWS, Azure & GCP
Home Page: https://collie.cloudfoundation.org
License: Apache License 2.0
When analyzing my cloud costs, I would like to know which tags are used in order to map costs to corresponding cost centers etc. It's great that this is possible with Collie, but the functionality is a bit hidden.
My proposal would be to add this info to the Options section of the collie tenant costs command, where it says "Defines the output format." Just add: "Use csv/json/yaml to view tags.
Some users might have multiple profiles for the AWS CLI, and we currently always use the default (because we do not specify an explicit profile). This might be problematic when a user has the management account configured as an additional profile.
I would appreciate to have a homebrew entry for collie (at some point): https://docs.brew.sh/Adding-Software-to-Homebrew
I had the following cli interaction
collie tenant list
...
# returned me subscriptions from another AAD tenant as I wanted to look at
85 entries. GCP: 47, AWS: 10, Azure: 28
# I figure out my az is logged into the wrong tenant, alright I'll fix this
az login --tenant other.example.com
collie tenant list
...
85 entries. GCP: 47, AWS: 10, Azure: 28
# returns the same list as before, no tenants from other.example.com are returned
Now, I know why collie gives me the cached list but this is not transparent anywhere in the output.
We have a couple of options
I'm kind of leaning towards the 3rd option for it offers the lowest complexity and explicit cache control is always a good idea. So maybe my interaction could look like this instead
collie tenant list
...
# returned me subscriptions from another AAD tenant as I wanted to look at
85 entries. GCP: 47, AWS: 10, Azure: 28 (78.12s - entries retrieved from cloud)
# I figure out my az is logged into the wrong tenant, alright I'll fix this
az login --tenant other.example.com
collie tenant list
...
85 entries. GCP: 47, AWS: 10, Azure: 28 (0.01s - entries retrieved from cache)
# okay, I need to refresh
collie tenant list --refresh
...
85 entries. GCP: 47, AWS: 10, Azure: 46 (90.12s - entries retrieved from cloud)
When executing collie cache
i get no output. I would expect some help to appear
Within #49 we discovered that error handling doesn't work properly when on a version below 2.0. You can clearly see the difference between the two documentations as well:
1.x -> https://docs.aws.amazon.com/cli/latest/topic/return-codes.html
2.x -> https://awscli.amazonaws.com/v2/documentation/api/latest/topic/return-codes.html
To prevent this from happening again, users should update to AWS CLI 2.0 and Collie should exit with an error.
The loading animation that is present when making calls to the Cloud CLIs uses tty.hideCursor()
. If this is the case, the terminal no longer has a cursor, which is frustrating when wanting to do more commands.
Implementation hint: it seems that Deno can detect when a program is terminated: https://deno.land/[email protected]/examples/os_signals
Using collie v0.3.0
ERROR TypeError: policy.policy.bindings is not iterableoud-dev_0 --include-inherited --all --output json
at GcpMeshAdapter.getRoleAssignmentsForTenant (file://$deno$/bundle.js:18139:49)
at async GcpMeshAdapter.attachTenantRoleAssignments (file://$deno$/bundle.js:18126:37)
at async Promise.all (index 1)
at async MultiMeshAdapter.attachTenantRoleAssignments (file://$deno$/bundle.js:18044:9)
at async CachingMeshAdapterDecorator.attachTenantRoleAssignments (file://$deno$/bundle.js:18586:13)
at async Command.listIamAction [as fn] (file://$deno$/bundle.js:19197:5)
Also attaching a screenshot as it seems the loader/spinner output displayed while the command is running is only partially overwritten by the error message (see the breakup of red to white text)
GCP cost collection is currently not supported as their CLI does not offer any cost export via gcloud
CLI. This issue will be used to track progress on this and/or figure out any other methods of retrieving GCP costs.
(Was found by @mweber-mc)
ERROR Could not parse JSON for command 'az tag list --subscription 8f25c6cb-7398-4054-8f25-3f950f7b0234'
ERROR Could not parse JSON as an error with code 1 was given. The following stderr is given: ERROR: AADSTS700082: The refresh token has expired due to inactivity. The token was issued on 2021-07-21T09:03:57.2770411Z and was inactive for 12:00:00.
Trace ID: b7d4e636-cd69-4894-a248-f6045adb2301
Correlation ID: 85028f2e-e16c-4818-954d-4d92ec0e374a
Timestamp: 2021-07-22 13:29:52Z
To re-authenticate, please run az login
. If the problem persists, please contact your tenant administrator.
ERROR SyntaxError: Unexpected end of JSON input
at JSON.parse ()
at parseJsonStdoutWithLog (file://$deno$/bundle.js:17082:21)
at BasicAzureCliFacade.listTags (file://$deno$/bundle.js:18314:16)
at async AutoInstallAzureCliModuleDecorator.wrapCallWithInstallInterception (file://$deno$/bundle.js:18551:20)
at async AutoInstallAzureCliModuleDecorator.listTags (file://$deno$/bundle.js:18535:16)
at async file://$deno$/bundle.js:18407:20
at async RetryingAzureCliFacadeDecorator.retryable (file://$deno$/bundle.js:18422:20)
at async RetryingAzureCliFacadeDecorator.listTags (file://$deno$/bundle.js:18406:16)
at async file://$deno$/bundle.js:18015:26
at async Promise.all (index 0)
I ran collie tenant iam
on our production GCP org and hit the following issue
22:18 $ ./run.sh tenant iam
Check file:///Users/jrudolph/dev/mc/collie-cli/src/main.ts
WARNING This CLI does not support AWS Role Assignment analysis at the moment. Please keep an eye out for further development on this.
ERROR Error: Found unknown principalType for GCP: deleted
at GcpMeshAdapter.toPrincipalType (file:///Users/jrudolph/dev/mc/collie-cli/src/gcp/gcp-mesh-adapter.ts:118:15)
at GcpMeshAdapter.getRoleAssignmentsForTenant (file:///Users/jrudolph/dev/mc/collie-cli/src/gcp/gcp-mesh-adapter.ts:93:33)
Another error message from the same spot is ERROR Error: Found unknown principalType for GCP: domain
.
development
.To make users aware that a new Collie release is available with e.g. an important bug fix or a new exciting feature, we need some kind of system that can notify those users.
Implementation Hint:
It seems that Cliffy has some kind of support for upgrading CLIs: https://cliffy.io/command/#%E2%9D%AF-upgrade-command
The following happened when trying to collect IAM information across GCP tenants when missing a right for one of the tenants:
ERROR: (gcloud.projects.get-ancestors-iam-policy) User is not permitted to access IAM policy for one or more of the ancestors
Instead, Collie CLI tells me:
INFO You are not logged in into GCP CLI. Please disconnect GCP with "Collie config --disconnect GCP or login into GCP CLI."
This is wrong information and we should check more explicitly if it's really a "not logged in" situation.
Implementation hint:
When receiving result code 1
from gcloud
, we have to detect if it's really a "not logged in" error. If not, we should throw something like "An unknown error occurred for tenant XYZ: " + result.stderr
so it's clearly visible what went wrong. As a bonus, it would also be great to know for which tenant this issue occurred (GCP does not include this information in the response)
Hey guys i have successfully installed collie
❯ collie
INFO No configuration file found. I will create one for you :)
INFO ... searching for installed cloud CLIs
I see you already have these cloud CLIs installed: AWS, Azure.
Do you want to connect these to Collie? [y,N]:
y
INFO Saved your configuration here: /Users/simonbein/.config/collie-cli/config.json. Have fun using Collie!
However when I run collie config
it returns the following
❯ collie config
error: TypeError: Cannot read property 'showHelp' of undefined
at changeConfig (file://$deno$/bundle.js:17635:17)
at file://$deno$/bundle.js:17621:9
/Users/simonbein/.config/collie-cli/config.json looks like this
{
"connected": {
"AWS": true,
"GCP": false,
"Azure": true
},
"cache": {
"evictionDelayHrs": 24
},
"azure": {
"parentManagementGroups": []
}
}
Is your feature request related to a problem? Please describe.
As @tfelix found out, it looks absolutely horrible to offboard users in AWS. We could automate this and also do it simultaneously for the other cloud platforms too.
Reach of the feature request
Platforms operators working with AWS (haven't checked Azure & GCP, but it cannot be easy)
Impact of the feature request
Without a nice automation, you have to write a fairly long script for deleting a user including the user's various properties such as keys, CLI profiles, and more.
How would a solution look like?
collie user offboard [email protected]
Take inspiration from: https://github.com/meshcloud/infrastructure/pull/35
(It's a closed repo from meshcloud)
(optional) Implementation Hints
Have a look at the mentioned PR above.
In #72 I described an interaction I had with collie where I thought it was returning me Azure subscriptions from a "poisoned" cache built from a faulty az login
I had running against a wrong AAD tenant.
Since then I've found out that doing an az login --tenant meshcloud.io
appears to not (!) filter the subscriptions returned from az account list
. This is a problem because it makes collie tenant list
behave semantically differently on different cloud platforms.
gcloud projects list
will only return projects from the GCP organization I'm currently logged in toaz account list
will return info from different AAD tenantsFor me this is a problem because it makes collie commands querying azure (e.g. collie tenant iam
) really slow because it churns through many AAD tenants, most of them where it does not have enough permission to retrieve useful data.
Is your feature request related to a problem? Please describe.
I would love to deprovision tenants using Collie as this is a huge pain in the ass by doing it manually in the UI. In my example, this problem goes for AWS, but it might be just as painful for the other platforms as well.
Reach of the feature request
Platform Operators and Project Owners responsible for deleting accounts
Impact of the feature request
Deleting faster could result in a better user experience and even in potential cost savings by deprovisioning unused resources ASAP.
How would a solution look like?
collie tenant delete <identifier>
Not sure how the identifier part would work exactly though. Especially if you have duplicate identifiers across multiple platforms.
(optional) Implementation Hints
Check if the cloud CLIs allow for deletion. It might be that this is not possible.
The following error occurs when running collie tenant list
ERROR Error:
An error occurred (TooManyRequestsException) when calling the ListTagsForResource operation (reached max retries: 2): AWS Organizations can't complete your request because another request is already in progress. Try again later.
at AwsCliFacade.checkForErrors (file://$deno$/bundle.js:17686:19)
at AwsCliFacade.listTags (file://$deno$/bundle.js:17646:14)
at async file://$deno$/bundle.js:17701:26
at async Promise.all (index 40)
at async Promise.all (index 0)
at async MultiMeshAdapter.getMeshTenants (file://$deno$/bundle.js:17833:17)
at async CachingMeshAdapterDecorator.getMeshTenants (file://$deno$/bundle.js:18173:29)
at async Command.listTenantAction [as fn] (file://$deno$/bundle.js:18622:24)
at async Command.execute (file://$deno$/bundle.js:7117:13)
at async Command.parse (file://$deno$/bundle.js:7058:24)
We might need to do some chunking of requests to prevent too many requests from firing at once.
When some error occur when doing a csv export of the tenant costs, the CSV headers are not set correctly, because warnings like "no management group selected for azure" or" gcp is not supported" are shown in the first rows and used as headers. Those warnings should be shown as console output instead and shouldn't be part of the CSV export.
We currently do not support AWS for retrieving IAM information. This has the following two reasons:
As of now, the OS X binaries are not signed. For some users, this results in a warning that the application is insecure and it has to be moved to the bin.
By signing our OS X binaries, this situation will no longer occur and it will increase the security of Collie for OS X users.
I've just setup collie cli on a new machine and was surprised by the time it takes to run a simple collie --help
or collie tenant --help
. I have all three cloud provider CLIs installed on my machine, and running the --help
commands is something I do quite often when working with a new tool.
Here's some output from my machine.
time collie --help
...
real 0m3.965s
user 0m2.099s
sys 0m0.629s
time collie tenant --help
...
real 0m2.732s
user 0m1.725s
sys 0m0.440s
While it's running my terminal (macOS standard terminal) shows me that it's running python 3.7, so I think there's some auto-detection of provider CLI going on, even though I have a valid collie config already. Interestingly also collie --version
is "slow".
18:30 $ collie config list
┌───────┬──────┬───────┐
│ AWS │ GCP │ Azure │
├───────┼──────┼───────┤
│ false │ true │ true │
└───────┴──────┴───────┘
1 entry.
✔ ~
18:30 $ time collie --version
0.3.0
real 0m2.710s
user 0m1.724s
sys 0m0.429s
Extracted this part from #67
It seems the loader/spinner output displayed while the command is running is only partially overwritten by an error message occurring during the run (see the breakup of red to white text).
I've had a quick look at the code that I though would be responsible for it, but couldn't spot anything "obviously" wrong, i.e. it seems to explicitly handle exceptions from running commands
collie-cli/src/process/loader-shell-runner.ts
Lines 19 to 29 in 6fec4d0
This probably needs a more thorough investigation.
We are currently capable of analyzing tags on a global level, but it would also be nice to analyze the underlying tag values of one single tag. Take the environment
tag for example; I would like to know what values are used and by what percentage. This would allow me to identify inconsistencies and see what % of cloud tenants are using a particular environment. The command could work like
collie analyze-tag-values --tag environment
->
Analyzed 92 tenants
The environment tag has the following values:
-- production (12%)
-- test (20%)
-- development (64%)
-- dev (4%) <-- found inconsistency
To be aware of which users have access to a tenant, and with what role, it would be great if Collie could collect this information per tenant and display it in the CLI.
I logged into az and gcloud and ran collie tenant list --debug
.
The result is:
DEBUG listProjects: {"code":0,"stderr":"","stdout":"[\n {\n \"createTime\": \"2021-06-23T07:12:19.599Z\",\n \"labels\": {\n \"mesh-customer\": \"managed-customer\",\n \"mesh-project\": \"test-dev\",\n \"meshstack_cident\":
...
\"type\": \"organization\"\n },\n \"projectId\": \"meshstack-root\",\n \"projectNumber\": \"864000543001\"\n }\n]\n"}
ERROR SyntaxError: Unexpected end of JSON input-a93c-c9e95d079a13
at JSON.parse (<anonymous>)
at BasicAzureCliFacade.listTags (file://$deno$/bundle.js:17995:21)
at async AutoInstallAzureCliModuleDecorator.wrapCallWithInstallInterception (file://$deno$/bundle.js:18189:20)
at async AutoInstallAzureCliModuleDecorator.listTags (file://$deno$/bundle.js:18178:16)
at async file://$deno$/bundle.js:18049:20
at async RetryingAzureCliFacadeDecorator.retryable (file://$deno$/bundle.js:18059:20)
at async RetryingAzureCliFacadeDecorator.listTags (file://$deno$/bundle.js:18048:16)
at async file://$deno$/bundle.js:17852:26
at async Promise.all (index 1)
at async Promise.all (index 0)
ERROR Could not parse JSON:
SyntaxError: Unexpected end of JSON input
at JSON.parse ()
at parseJsonWithLog (file://$deno$/bundle.js:15910:21)
at BasicAzureCliFacade.listTags (file://$deno$/bundle.js:17175:16)
at async AutoInstallAzureCliModuleDecorator.wrapCallWithInstallInterception (file://$deno$/bundle.js:17420:20)
at async AutoInstallAzureCliModuleDecorator.listTags (file://$deno$/bundle.js:17404:16)
at async file://$deno$/bundle.js:17268:20
at async RetryingAzureCliFacadeDecorator.retryable (file://$deno$/bundle.js:17283:20)
at async RetryingAzureCliFacadeDecorator.listTags (file://$deno$/bundle.js:17267:16)
at async file://$deno$/bundle.js:16868:26
at async Promise.all (index 0)
Running on MacOS and connected to Azure and AWS
To better lay out the vision of the Collie project, a Philosophy section in the README would be great.
Is your feature request related to a problem? Please describe.
As a platform operator I would like to write tags to the cloud from Collie so I can fix any incompliances, e.g. some tenants are missing a cost center tag.
Reach of the feature request
Platform operators using tags or those that forgot to standardize some tags.
Impact of the feature request
We currently offer the analyze-tags
command which is helpful to identify gaps, but if I want to fix the issue, I still have to hop into the actual cloud platforms.
How would a solution look like?
collie tags set-missing --tags cost_center
would go into a mode where it ask per tenant that misses that tag:
What should the value be of cost_center
? The user can type in the value and Collie will submit the result to the cloud platform.
(optional) Implementation Hints
Any hints that could help implementation?
Make sure to write the result to the cache.
Make sure to rename collie tenant analyze-tags
to collie tags analyze-missing
.
Try to catch exceptions for incompliant tags ,e.g. GCP has a lot of requirements.
Is your feature request related to a problem? Please describe.
Collie ships new updates regularly, this is cool :-) But I have to "work" to get them.
Can you support a collie upgrade
command like deno upgrade
?
Reach of the feature request
me
Impact of the feature request
Saves me time, I can use more awesome collie stuff
How would a solution look like?
see below
(optional) Implementation Hints
Cliffy seems to have that builtin 😍 https://cliffy.io/command/index.html#%E2%9D%AF-upgrade-command
I have a subscription with a space in the name ("A B C"). Collie chokes on this
22:20 $ ./run.sh tenant iam
WARNING This CLI does not support AWS Role Assignment analysis at the moment. Please keep an eye out for further development on this.
ERROR Error: Error executing Azure CLI: - Subscription 'A' not recognized.d --all --output json
UnrecognizedArgumentError: unrecognized arguments: B C
Try this: 'az role assignment list --role a_role'
Still stuck? Run 'az --help' to view all commands or go to 'https://docs.microsoft.com/en-us/cli/azure/reference-index?view=azure-cli-latest' to learn more
at BasicAzureCliFacade.checkForErrors (file:///Users/jrudolph/dev/mc/collie-cli/src/azure/basic-azure-cli-facade.ts:196:13)
at BasicAzureCliFacade.getRoleAssignments (file:///Users/jrudolph/dev/mc/collie-cli/src/azure/basic-azure-cli-facade.ts:177:10)
at async AutoInstallAzureCliModuleDecorator.wrapCallWithInstallInterception (file:///Users/jrudolph/dev/mc/collie-cli/src/azure/auto-install-azure-cli-module-decorator.ts:75:14)
at async AutoInstallAzureCliModuleDecorator.getRoleAssignments (file:///Users/jrudolph/dev/mc/collie-cli/src/azure/auto-install-azure-cli-module-decorator.ts:66:12)
at async file:///Users/jrudolph/dev/mc/collie-cli/src/azure/retrying-azure-cli-facade-decorator.ts:71:14
I suppose this is due to the way the ShellRunner
accepts a single string and then does a const commands = commandStr.split(" ");
before invoking the Deno.run API and thus building an incorrect argument array
There should be a way to detect if the same currency is added up during cost collection. The fetched currency symbol should also be saved in order to display it in the tenant cost overview at the end.
This should be done for Azure and AWS as these are the platforms that currently support cost collection.
It would be nice to filter via tags on tenants & costs. E.g. show me the costs all tenants made with CostCenter=1234.
Is your feature request related to a problem? Please describe.
Currently working with tenant-related data poses some problems, it is split into costs and regular tenant listing, its hard to decide what information to display where. What should be done if more information is added gradually like users? Using different invocation commands is confusing.
Impact of the feature request
Hard to use collie
How would a solution look like?
A better approach would be to have a unified structure where the user can decide by himself what information he wants to display. Something like:
collie tenants list --show platform platformTenantName costs tags
if not given only a default set of information is shown (can be equal to the current collie tenant list
)
Every public cloud provider offers the possibility to set alerts that warn you about costs. Sadly a lot of people don't do it and have bad surprises at the end of the month. Also REALLY annoying you have to set alerts for every tenant individually 🤪. How cool would it be for an enterprise architect to set alerts globally or only for sandbox environments? BTW I think this also would be amazing for a single cloud even to set alerts on multiple tenants at once.
Hey guys,
I have successfully installed collie, however when I run collie tenant list
it returns the following error
❯ collie tenant list
ERROR Could not parse JSON: ounts --output json
ERROR SyntaxError: Unexpected end of JSON input
at JSON.parse (<anonymous>)
at parseJsonWithLog (file://$deno$/bundle.js:17093:21)
at AwsCliFacade.listAccounts (file://$deno$/bundle.js:17675:32)
at async AwsMeshAdapter.getMeshTenants (file://$deno$/bundle.js:17736:26)
at async Promise.all (index 0)
at async MultiMeshAdapter.getMeshTenants (file://$deno$/bundle.js:17931:17)
at async CachingMeshAdapterDecorator.getMeshTenants (file://$deno$/bundle.js:18292:29)
at async Command.listTenantAction [as fn] (file://$deno$/bundle.js:18775:24)
at async Command.execute (file://$deno$/bundle.js:7117:13)
at async Command.parse (file://$deno$/bundle.js:7058:24)
When running tenant costs ...
the command crashes when the program encounters at least one Azure subscription of the type Sponsorship subscription
. See the following logs as an example:
DEBUG getCostInformation: {"code":0,"stderr":"Command group 'consumption' is in preview. It may be changed/removed in a future release.\n","stdout":"[]\n"}
DEBUG Fetched 0 cost infos from Azure
DEBUG Quering Azure for tenant Microsoft Azure Sponsorship: {"from":"2021-05-01T00:00:00.000Z","to":"2021-05-31T23:59:59.000Z"}
DEBUG getCostInformation: {"code":1,"stderr":"Command group 'consumption' is in preview. It may be changed/removed in a future release.\n(422) Cost Management supports only Enterprise Agreement, Web direct and Microsoft Customer Agreement offer types. Subscription <sub-id> is not associated with a valid offer type.Cost Management supports only Enterprise Agreement, Web direct and Microsoft Customer Agreement offer types. Subscription <sub-id> is not associated with a valid offer type. (Request ID: 6e7bad96-a511-48fa-86fd-cf4569b26e70)\n","stdout":""}
ERROR SyntaxError: Unexpected end of JSON input
at JSON.parse (<anonymous>)
at BasicAzureCliFacade.getCostInformation (file:///Users/---/dev/mc/collie/src/azure/basic-azure-cli-facade.ts:86:17)
at async AutoInstallAzureCliModuleDecorator.wrapCallWithInstallInterception (file:///Users/---/dev/mc/collie/src/azure/auto-install-azure-cli-module-decorator.ts:56:14)
at async AutoInstallAzureCliModuleDecorator.getCostInformation (file:///Users/---/dev/mc/collie/src/azure/auto-install-azure-cli-module-decorator.ts:43:12)
at async RetryingAzureCliFacadeDecorator.getCostInformation (file:///Users/---/dev/mc/collie/src/azure/retrying-azure-cli-facade-decorator.ts:38:14)
at async AzureMeshAdapter.getTenantCostsForWindow (file:///Users/---/dev/mc/collie/src/azure/azure-mesh-adapter.ts:71:28)
at async AzureMeshAdapter.listTenantCosts (file:///Users/---/dev/mc/collie/src/azure/azure-mesh-adapter.ts:51:24)
at async Promise.all (index 0)
at async MultiMeshAdapter.listTenantCosts (file:///Users/---/dev/mc/collie/src/mesh/multi-mesh-adapter.ts:26:13)
at async Command.listTenantsCostAction [as fn] (file:///Users/---/dev/mc/collie/src/commands/tenant.command.ts:113:26)
✘-1 ~/dev/mc/collie/src [develop|✚ 4…2]
While the error is not wrong, the program should continue and print a warning that this subscription could not be processed.
Is your feature request related to a problem? Please describe.
We should remove the blue color of log statements of level INFO
. They look unreadable in a PowerShell console
Reach of the feature request
Windows users making use of PowerShell with the
Impact of the feature request
log.info() statements are not visible.
How would a solution look like?
Either change the color to something less used as a background (purple?) or just remove the color altogether.
(optional) Implementation Hints
denoland/std#1077 -> Changing the color is currently not possible
It's a minor nitpick but I just tried to run collie tenant cost
and had to learn that it's collie tenant cost
s instead.
So we have
I don't have a strong preference and am not sure this needs to be harmonized at all, just wanted to point out this happened. Other tools for example do it like this
# List all pods in ps output format.
kubectl get pods
# List all pods in ps output format with more information (such as node name).
kubectl get pods -o wide
# List a single replication controller with specified NAME in ps output format.
kubectl get replicationcontroller web
Right now we have the possibility to set a management group in the config, and by doing so, the cost query will be faster.
It is in fact possible to see management groups & which one is the root management group by using the following commands:
az account management-group list
az account management-group show --name "<id>"
I sometimes find myself aborting a collie command that has a long runtime, e.g. when running collie tenant cost
and I noticed I had specified the wrong time window.
Every time I do this and while queries are still running I'm getting "random" error messages instead of a clean exit.
[jrudolph@localhost ~]$ collie tenant list
^CERROR Could not parse JSON: nts --output json
ERROR SyntaxError: Unexpected end of JSON input
at JSON.parse (<anonymous>)
at parseJsonWithLog (file://$deno$/bundle.js:17093:21)
In the face of a SIGINT I think a "well-behaved" collie should
Currently, we are checking on different levels if the collie command gets piped. @tfelix recommends doing it once on startup to prevent any errors from occurring when the stdout is busy.
@JohannesRudolph suggests: we could build an abstraction over tools like fmt so we have a "ttyAware" fmt module that exposes the same API as fmt but NOPs all formatting calls in case the stdout is not a tty.
Is your feature request related to a problem? Please describe.
We recently introduced a feature to pick an AWS profile that Collie will use for doing CLI calls. But @SimonTheLeg made a good remark where he explained that some AWS devs will be used to doing so using the EXPORT AWS_PROFILE=...
method.
Reach of the feature request
AWS developers using EXPORT AWS_PROFILE
for picking profiles
Impact of the feature request
They might be confused about what exact profile is used. Especially if they first run EXPORT AWS_PROFILE
and then collie tenant list
where Collie might use a different profile.
How would a solution look like?
At best, Collie would have to detect EXPORT AWS_PROFILE
, and use that profile instead of the one configured using collie config aws
.
Steps taken:
collie cache clear
collie tenant costs --from 2021-01-01 --to 2021-03-31
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.