@emulators/aws 0.4.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +75 -0
- package/dist/fonts/favicon.ico +0 -0
- package/dist/index.js +554 -90
- package/dist/index.js.map +1 -1
- package/package.json +8 -3
package/README.md
ADDED
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
# @emulators/aws
|
|
2
|
+
|
|
3
|
+
S3, SQS, IAM, and STS emulation with AWS SDK-compatible S3 paths and query-style SQS/IAM/STS endpoints. All responses use AWS-compatible XML.
|
|
4
|
+
|
|
5
|
+
Part of [emulate](https://github.com/vercel-labs/emulate) — local drop-in replacement services for CI and no-network sandboxes.
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npm install @emulators/aws
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Endpoints
|
|
14
|
+
|
|
15
|
+
### S3
|
|
16
|
+
|
|
17
|
+
S3 routes use root paths matching the real AWS S3 wire format, so the official AWS SDK works out of the box with `forcePathStyle: true`. Legacy `/s3/` prefixed paths are also supported for backward compatibility.
|
|
18
|
+
|
|
19
|
+
- `GET /` — list all buckets
|
|
20
|
+
- `PUT /:bucket` — create bucket
|
|
21
|
+
- `DELETE /:bucket` — delete bucket
|
|
22
|
+
- `HEAD /:bucket` — check existence
|
|
23
|
+
- `GET /:bucket` — list objects (prefix, delimiter, max-keys, continuation-token, start-after)
|
|
24
|
+
- `POST /:bucket` — presigned POST upload (browser-style multipart form with policy validation)
|
|
25
|
+
- `PUT /:bucket/:key` — put object (supports copy via `x-amz-copy-source`)
|
|
26
|
+
- `GET /:bucket/:key` — get object
|
|
27
|
+
- `HEAD /:bucket/:key` — head object
|
|
28
|
+
- `DELETE /:bucket/:key` — delete object
|
|
29
|
+
|
|
30
|
+
### SQS
|
|
31
|
+
All operations via `POST /sqs/` with `Action` parameter:
|
|
32
|
+
- `CreateQueue`, `ListQueues`, `GetQueueUrl`, `GetQueueAttributes`
|
|
33
|
+
- `SendMessage`, `ReceiveMessage`, `DeleteMessage`
|
|
34
|
+
- `PurgeQueue`, `DeleteQueue`
|
|
35
|
+
|
|
36
|
+
### IAM
|
|
37
|
+
All operations via `POST /iam/` with `Action` parameter:
|
|
38
|
+
- `CreateUser`, `GetUser`, `ListUsers`, `DeleteUser`
|
|
39
|
+
- `CreateAccessKey`, `ListAccessKeys`, `DeleteAccessKey`
|
|
40
|
+
- `CreateRole`, `GetRole`, `ListRoles`, `DeleteRole`
|
|
41
|
+
|
|
42
|
+
### STS
|
|
43
|
+
All operations via `POST /sts/` with `Action` parameter:
|
|
44
|
+
- `GetCallerIdentity`, `AssumeRole`
|
|
45
|
+
|
|
46
|
+
## Auth
|
|
47
|
+
|
|
48
|
+
Bearer tokens or IAM access key credentials. Default key pair always seeded: `AKIAIOSFODNN7EXAMPLE` / `wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY`.
|
|
49
|
+
|
|
50
|
+
## Seed Configuration
|
|
51
|
+
|
|
52
|
+
```yaml
|
|
53
|
+
aws:
|
|
54
|
+
region: us-east-1
|
|
55
|
+
s3:
|
|
56
|
+
buckets:
|
|
57
|
+
- name: my-app-bucket
|
|
58
|
+
- name: my-app-uploads
|
|
59
|
+
sqs:
|
|
60
|
+
queues:
|
|
61
|
+
- name: my-app-events
|
|
62
|
+
- name: my-app-dlq
|
|
63
|
+
iam:
|
|
64
|
+
users:
|
|
65
|
+
- user_name: developer
|
|
66
|
+
create_access_key: true
|
|
67
|
+
roles:
|
|
68
|
+
- role_name: lambda-execution-role
|
|
69
|
+
description: Role for Lambda function execution
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
## Links
|
|
73
|
+
|
|
74
|
+
- [Full documentation](https://emulate.dev/aws)
|
|
75
|
+
- [GitHub](https://github.com/vercel-labs/emulate)
|
|
Binary file
|