rizaldntr/storage-service-website-action
Automate the deployment of static websites to AWS Storage Service (S3) with customizable caching, file handling, and AWS credentials integration.
View on GitHubTrust Signals
- Scorecard Score
- not yet scored
- Maintenance Recency
- Stale
- License
- None
Inputs
| name | description | required | default |
|---|---|---|---|
| aws-access-key-id | Your AWS Access Key ID, used for authenticating the action to access the S3 bucket. | yes | — |
| aws-secret-access-key | Your AWS Secret Access Key, which works together with the Access Key ID for authentication. | yes | — |
| aws-session-token | An optional session token for AWS temporary credentials, if you're using a session-based approach (e.g., STS). | no | — |
| aws-region | The AWS region where your S3 bucket is located (e.g., us-east-1, eu-west-2). | yes | — |
| bucket | The target AWS S3 bucket name where the website will be deployed. | yes | — |
| folder | The local folder path that contains the static website files to be uploaded. | yes | — |
| exclude | Optional patterns or specific file names to exclude from the deployment (e.g., logs or test files). | no | — |
| object-rules | Optional YAML configuration that defines cache-control and content-type rules for specific file patterns. Example configuration: ``` - pattern: '_next/*' cache-control: 'max-age=31536000, immutable' - pattern: 'assets/*' cache-control: 'max-age=86400' - pattern: 'images/*' cache-control: 'max-age=86400' ``` This allows you to define different cache behaviors for specific file types or directories. | no | — |
| default-cache-control | The default `Cache-Control` header to apply to all files unless otherwise specified. This controls how long the file is cached by browsers. Default is 'max-age=2592000' (30 days). | no | max-age=2592000 |
| html-cache-control | The `Cache-Control` value specifically for HTML files, used to define how often these should be refreshed. Default is 'max-age=600' (10 minutes). | no | max-age=600 |
| image-cache-control | The `Cache-Control` value specifically for image files (e.g., PNG, JPG), allowing you to set longer caching periods. Default is 'max-age=864000' (10 days). | no | max-age=864000 |
| pdf-cache-control | The `Cache-Control` value for PDF files. Default is 'max-age=2592000' (30 days). | no | max-age=2592000 |
| remove-html-extension | Set to 'true' if you want to remove the '.html' extension from URLs when serving the website (e.g., `/about` instead of `/about.html`). | no | false |
| duplicate-html-with-no-extension | Set to 'true' to generate both `.html` files and copies without the `.html` extension, allowing both URL formats to work. Default is 'false'. | no | false |
Outputs
no outputs