@statican S3 bucket for hosting static assets uploaded from
- No parameters are required
fingerprintenables static asset file fingerprinting (and long-lived caching headers)
ignoreignores files from
serializewill serialize smaller files into API Gateway upon deployment
.arc file defines a static bucket:
@app testapp @static fingerprint true ignore .tar.gz tmp user
Locally, if the folder
public/ exists, whenever you run
arc deploy the contents are published to the
staging stack. If you set
arc deploy production the contents of
public/ are deployed to the production stack.
To only deploy static assets from
/public (and not function sources from
/src), you can provide any of
-s flags, i.e.
arc deploy static.
To delete remote static assets on the S3 bucket that do not exist locally, provide the optional
--delete flag, i.e.
arc deploy static --prune.
This is an experimental feature. Serialize static assets directly into API Gateway as mocks.
- Minimize network traffic
- Save on Lambda invocations
- Requires a CloudFormation stack update to deploy which is slower than syncing a file to S3
- Can quickly bloat the generated CloudFormation template to max
Currently supported file types
@app testapp @static serialize true @http get /
arc deploy will serialize