Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
@sls-next/aws-s3
Advanced tools
Instantly deploy and manage your S3 buckets with [Serverless Components](https://github.com/serverless/components). Supports acceleration as well as file & directory uploads.
Readme
Instantly deploy and manage your S3 buckets with Serverless Components. Supports acceleration as well as file & directory uploads.
$ npm install -g serverless
Just create a serverless.yml
file
$ touch serverless.yml
$ touch .env # your AWS api keys
# .env
AWS_ACCESS_KEY_ID=XXX
AWS_SECRET_ACCESS_KEY=XXX
# serverless.yml
myBucket:
component: "@serverless/aws-s3"
inputs:
accelerated: false # default is true. Enables upload acceleartion for the bucket
region: us-east-1
cors:
CORSRules:
- AllowedHeaders:
- "*"
AllowedMethods:
- PUT
- POST
- DELETE
AllowedOrigins:
- http://www.example.com
MaxAgeSeconds: 3000
$ serverless
If you're using this component programmatically within another component, you could also easily upload files and/or directories to your bucket.
const bucket = await this.load("@serverless/aws-s3");
// deploy
await bucket({
accelerated: true
});
// upload directory
await bucket.upload({ dir: "./my-files" });
// upload file
await bucket.upload({ file: "./my-file.txt" });
Cache-control headers can also be set:
// upload directory, setting cache-control headers
await bucket.upload({ dir: "./my-files", cacheControl: "max-age=86400" });
// upload file, setting cache-control header
await bucket.upload({ file: "./my-file.txt", cacheControl: "max-age=86400" });
For a full example on how this component could be used, take a look at how the website component is using it.
Checkout the Serverless Components repo for more information.
FAQs
Instantly deploy and manage your S3 buckets with [Serverless Components](https://github.com/serverless/components). Supports acceleration as well as file & directory uploads.
The npm package @sls-next/aws-s3 receives a total of 33,820 weekly downloads. As such, @sls-next/aws-s3 popularity was classified as popular.
We found that @sls-next/aws-s3 demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.