-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
513 lines (470 loc) · 15 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
<!DOCTYPE html>
<html>
<head>
<title>cloud-resource-logger</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" href="assets/CRL.png" type="image/png" />
<style>
body {
font: 400 16px/1.5 'Helvetica Neue', Helvetica, Arial, sans-serif;
color: #111;
background-color: #fdfdfd;
-webkit-text-size-adjust: 100%;
-webkit-font-feature-settings: 'kern' 1;
-moz-font-feature-settings: 'kern' 1;
-o-font-feature-settings: 'kern' 1;
font-feature-settings: 'kern' 1;
font-kerning: normal;
padding: 30px;
}
@media only screen and (max-width: 600px) {
body {
padding: 5px;
}
main {
padding: 0px 20px 20px 20px !important;
}
}
main {
margin: 0px;
max-width: 900px;
border: 1px solid #e1e4e8;
padding: 10px 40px;
padding-bottom: 20px;
border-radius: 2px;
margin-left: auto;
margin-right: auto;
}
hr {
color: #bbb;
background-color: #bbb;
height: 1px;
flex: 0 1 auto;
margin: 1em 0;
padding: 0;
border: none;
}
/**
* Links
*/
a {
color: #0366d6;
text-decoration: none;
}
a:visited {
color: #0366d6;
}
a:hover {
color: #0366d6;
text-decoration: underline;
}
pre {
background-color: #f6f8fa;
border-radius: 3px;
font-size: 85%;
line-height: 1.45;
overflow: auto;
padding: 16px;
}
/**
* Code blocks
*/
code {
background-color: rgba(27, 31, 35, 0.05);
border-radius: 3px;
font-size: 85%;
margin: 0;
word-wrap: break-word;
padding: 0.2em 0.4em;
font-family: SFMono-Regular, Consolas, Liberation Mono, Menlo, Courier,
monospace;
}
pre > code {
background-color: transparent;
border: 0;
display: inline;
line-height: inherit;
margin: 0;
overflow: visible;
padding: 0;
word-wrap: normal;
font-size: 100%;
}
/**
* Blockquotes
*/
blockquote {
margin-left: 30px;
margin-top: 0px;
margin-bottom: 16px;
border-left-width: 3px;
padding: 0 1em;
color: #828282;
border-left: 4px solid #e8e8e8;
padding-left: 15px;
font-size: 18px;
letter-spacing: -1px;
font-style: italic;
}
blockquote * {
font-style: normal !important;
letter-spacing: 0;
color: #6a737d !important;
}
/**
* Tables
*/
table {
border-spacing: 2px;
display: block;
font-size: 14px;
overflow: auto;
width: 100%;
margin-bottom: 16px;
border-spacing: 0;
border-collapse: collapse;
}
td {
padding: 6px 13px;
border: 1px solid #dfe2e5;
}
th {
font-weight: 600;
padding: 6px 13px;
border: 1px solid #dfe2e5;
}
tr {
background-color: #fff;
border-top: 1px solid #c6cbd1;
}
table tr:nth-child(2n) {
background-color: #f6f8fa;
}
/**
* Others
*/
img {
max-width: 100%;
}
p {
line-height: 24px;
font-weight: 400;
font-size: 16px;
color: #24292e;
}
ul {
margin-top: 0;
}
li {
color: #24292e;
font-size: 16px;
font-weight: 400;
line-height: 1.5;
}
li + li {
margin-top: 0.25em;
}
body {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial,
sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol';
color: #24292e;
}
a:visited {
color: #0366d6;
}
h1,
h2,
h3 {
border-bottom: 1px solid #eaecef;
color: #111;
/* Darker */
}
</style>
<style>
pre code.hljs {
display: block;
overflow-x: auto;
padding: 1em
}
code.hljs {
padding: 3px 5px
}
/*!
Theme: GitHub
Description: Light theme as seen on github.com
Author: github.com
Maintainer: @Hirse
Updated: 2021-05-15
Outdated base version: https://github.com/primer/github-syntax-light
Current colors taken from GitHub's CSS
*/
.hljs {
color: #24292e;
background: #ffffff
}
.hljs-doctag,
.hljs-keyword,
.hljs-meta .hljs-keyword,
.hljs-template-tag,
.hljs-template-variable,
.hljs-type,
.hljs-variable.language_ {
/* prettylights-syntax-keyword */
color: #d73a49
}
.hljs-title,
.hljs-title.class_,
.hljs-title.class_.inherited__,
.hljs-title.function_ {
/* prettylights-syntax-entity */
color: #6f42c1
}
.hljs-attr,
.hljs-attribute,
.hljs-literal,
.hljs-meta,
.hljs-number,
.hljs-operator,
.hljs-variable,
.hljs-selector-attr,
.hljs-selector-class,
.hljs-selector-id {
/* prettylights-syntax-constant */
color: #005cc5
}
.hljs-regexp,
.hljs-string,
.hljs-meta .hljs-string {
/* prettylights-syntax-string */
color: #032f62
}
.hljs-built_in,
.hljs-symbol {
/* prettylights-syntax-variable */
color: #e36209
}
.hljs-comment,
.hljs-code,
.hljs-formula {
/* prettylights-syntax-comment */
color: #6a737d
}
.hljs-name,
.hljs-quote,
.hljs-selector-tag,
.hljs-selector-pseudo {
/* prettylights-syntax-entity-tag */
color: #22863a
}
.hljs-subst {
/* prettylights-syntax-storage-modifier-import */
color: #24292e
}
.hljs-section {
/* prettylights-syntax-markup-heading */
color: #005cc5;
font-weight: bold
}
.hljs-bullet {
/* prettylights-syntax-markup-list */
color: #735c0f
}
.hljs-emphasis {
/* prettylights-syntax-markup-italic */
color: #24292e;
font-style: italic
}
.hljs-strong {
/* prettylights-syntax-markup-bold */
color: #24292e;
font-weight: bold
}
.hljs-addition {
/* prettylights-syntax-markup-inserted */
color: #22863a;
background-color: #f0fff4
}
.hljs-deletion {
/* prettylights-syntax-markup-deleted */
color: #b31d28;
background-color: #ffeef0
}
.hljs-char.escape_,
.hljs-link,
.hljs-params,
.hljs-property,
.hljs-punctuation,
.hljs-tag {
/* purposely ignored */
}
</style>
</head>
<body>
<main>
<h1 id="cloud-resource-logger">Cloud-Resource-Logger</h1>
<p><strong>cloud-resource-logger</strong> is a CLI tool for listing AWS resources such as EC2 instances, S3 buckets, Lambda functions, and DynamoDB tables. It prompts for AWS credentials and displays information about the specified resources.</p>
<h2 id="installation">Installation</h2>
<p>To install <code>cloud-resource-logger</code>, you can use npm. For global installation, run:</p>
<pre><code class="hljs bash language-bash">npm install -g cloud-resource-logger</code></pre>
<h2 id="npm-package">NPM Package</h2>
<p>You can find the <code>cloud-resource-logger</code> package on npm at the following link:</p>
<p><a href="https://www.npmjs.com/package/cloud-resource-logger" target="_blank">NPM Package: cloud-resource-logger</a></p>
<h2 id="usage">Usage</h2>
<p>To use <code>cloud-resource-logger</code>, you'll need to provide AWS credentials and specify the service you want to query.</p>
<h3 id="start-environment">Start Environment</h3>
<p>To start the environment and save AWS credentials, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger start</code></pre>
<p>This command will prompt you to enter your AWS credentials and save them for use with subsequent commands.</p>
<h3 id="stop-environment">Stop Environment</h3>
<p>To stop the environment and remove saved AWS credentials, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger stop</code></pre>
<p>This command will remove the saved credentials, ensuring that subsequent commands prompt for credentials again.</p>
<h3 id="list-ec2-instances">List EC2 Instances</h3>
<p>To list all EC2 instances, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service ec2</code></pre>
<h3 id="list-s3-buckets">List S3 Buckets</h3>
<p>To list all S3 buckets, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service s3</code></pre>
<h3 id="list-lambda-functions">List Lambda Functions</h3>
<p>To list all Lambda functions, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service lambda</code></pre>
<h3 id="list-dynamodb-tables">List DynamoDB Tables</h3>
<p>To list all DynamoDB tables, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service dynamodb</code></pre>
<h3 id="list-iam-users-and-policies">List IAM Users and Policies</h3>
<p>To list IAM users and their attached policies, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service iam</code></pre>
<p>This will print all IAM users along with their attached policies.</p>
<h3 id="list-rds-instances">List RDS Instances</h3>
<p>To list RDS instance details, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service rds</code></pre>
<p>This will print information about available RDS instances, clusters, and other related details.</p>
<h3 id="list-ecs-clusters">List ECS Clusters</h3>
<p>To list ECS clusters, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service ecs</code></pre>
<h3 id="list-eks-clusters">List EKS Clusters</h3>
<p>To list EKS clusters, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service eks</code></pre>
<h3 id="list-cloudwatch-alarms">List CloudWatch Alarms</h3>
<p>To list CloudWatch alarms, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service cloudwatch</code></pre>
<h3 id="list-cloudformation-stacks">List CloudFormation Stacks</h3>
<p>To list CloudFormation stacks, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service cloudformation</code></pre>
<h3 id="list-route-53-hosted-zones">List Route 53 Hosted Zones</h3>
<p>To list Route 53 hosted zones, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service route53</code></pre>
<h3 id="list-sns-topics">List SNS Topics</h3>
<p>To list SNS topics, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service sns</code></pre>
<h3 id="list-ses-identities">List SES Identities</h3>
<p>To list SES identities, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service ses</code></pre>
<h3 id="list-load-balancers">List Load Balancers</h3>
<p>To list load balancers, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service elb</code></pre>
<h3 id="list-kinesis-streams">List Kinesis Streams</h3>
<p>To list Kinesis streams, use the following command:</p>
<pre><code class="hljs bash language-bash">cloud-resource-logger list --service kinesis</code></pre>
<h2 id="commands">Commands</h2>
<ul>
<li><p><code>start</code>: Start the environment and save AWS credentials.</p></li>
<li><p><code>stop</code>: Stop the environment and remove saved AWS credentials.</p></li>
<li><p><code>list --service <service></code>: Specify the AWS service you want to query. Valid options are:</p>
<ul>
<li><code>ec2</code> - Lists all EC2 instances.</li>
<li><code>s3</code> - Lists all S3 buckets.</li>
<li><code>lambda</code> - Lists all Lambda functions.</li>
<li><code>dynamodb</code> - Lists all DynamoDB tables.</li>
<li><code>iam</code> - Lists IAM users and their attached policies.</li>
<li><code>rds</code> - Lists RDS instances and clusters.</li>
<li><code>ecs</code> - Lists ECS clusters.</li>
<li><code>eks</code> - Lists EKS clusters.</li>
<li><code>cloudwatch</code> - Lists CloudWatch alarms.</li>
<li><code>cloudformation</code> - Lists CloudFormation stacks.</li>
<li><code>route53</code> - Lists Route 53 hosted zones.</li>
<li><code>sns</code> - Lists SNS topics.</li>
<li><code>ses</code> - Lists SES identities.</li>
<li><code>elb</code> - Lists load balancers.</li>
<li><code>kinesis</code> - Lists Kinesis streams.</li></ul></li>
<li><p><code>help</code>: Show this help message.</p></li>
</ul>
<h2 id="example">Example</h2>
<pre><code class="hljs bash language-bash">$ cloud-resource-logger start
Enter AWS Access Key ID: [Your Access Key ID]
Enter AWS Secret Access Key: [Your Secret Access Key]
Enter AWS Region: [Your AWS Region]
Environment started and AWS credentials saved.
$ cloud-resource-logger list --service ec2
Active EC2 Instances:
[ ... list of instances ... ]
$ cloud-resource-logger list --service s3
S3 Buckets:
[ ... list of buckets ... ]
$ cloud-resource-logger list --service iam
IAM Users and Policies:
[ ... list of <span class="hljs-built_in">users</span> and attached policies ... ]
$ cloud-resource-logger list --service rds
RDS Instances:
[ ... list of RDS instances ... ]
$ cloud-resource-logger list --service ecs
ECS Clusters:
[ ... list of ECS clusters ... ]
$ cloud-resource-logger list --service eks
EKS Clusters:
[ ... list of EKS clusters ... ]
$ cloud-resource-logger list --service cloudwatch
CloudWatch Alarms:
[ ... list of alarms ... ]
$ cloud-resource-logger list --service cloudformation
CloudFormation Stacks:
[ ... list of stacks ... ]
$ cloud-resource-logger list --service route53
Route 53 Hosted Zones:
[ ... list of hosted zones ... ]
$ cloud-resource-logger list --service sns
SNS Topics:
[ ... list of topics ... ]
$ cloud-resource-logger list --service ses
SES Identities:
[ ... list of identities ... ]
$ cloud-resource-logger list --service elb
Load Balancers:
[ ... list of load balancers ... ]
$ cloud-resource-logger list --service kinesis
Kinesis Streams:
[ ... list of streams ... ]
$ cloud-resource-logger stop
Environment stopped and AWS credentials removed.</code></pre>
<h2 id="configuration">Configuration</h2>
<p>You will be prompted to enter the following AWS credentials:</p>
<ul>
<li><strong>AWS Access Key ID</strong></li>
<li><strong>AWS Secret Access Key</strong></li>
<li><strong>AWS Region</strong></li>
</ul>
<p>These credentials are used to authenticate with AWS and fetch the relevant resource information.</p>
<h2 id="contributing">Contributing</h2>
<p>Feel free to contribute to the project by opening issues or submitting pull requests. <a href="/cloud-resource-logger/dist/contributing.html">See contributing guidelines</a></p>
<h2 id="contact">Contact</h2>
<p>For any questions or feedback, please reach out to Prathamesh Inde at <a href="mailto:prathameshinde86@gmail.com">prathameshinde86@gmail.com</a>.</p>
<h2 id="key-sections-included">Key Sections Included</h2>
<ul>
<li><strong>Installation</strong>: How to install the CLI tool.</li>
<li><strong>Usage</strong>: Instructions on how to use the tool with example commands.</li>
<li><strong>Commands</strong>: Detailed description of the available commands and their options.</li>
<li><strong>Example</strong>: Example usage of the commands.</li>
<li><strong>Configuration</strong>: Explanation of what credentials are required.</li>
<li><strong>License</strong>: Information about the license.</li>
<li><strong>Contributing</strong>: Instructions for contributing to the project. <a href="/cloud-resource-logger/dist/contributing.html">See contributing guidelines</a></li>
<li><strong>Contact</strong>: How to contact you for support or feedback.</li>
</ul>
<h2 id="file-structure-and-functionality">File Structure and Functionality</h2>
<p>For a detailed overview of the source code, including the file structure and functionality of each component, refer to the <a href="/cloud-resource-logger/dist/filestructure.html">File Structure</a>.</p>
<hr />
<p>Let me know if there are any further changes you’d like!</p>
<p>Thank you for using <code>cloud-resource-logger</code>!</p>
</main>
</body>
</html>