Documentation
¶
Overview ¶
Package s3presigner provides an S3 presigned URL generator for file uploads. It implements the livetemplate.Presigner interface for direct client-to-S3 uploads.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type S3Config ¶
type S3Config struct {
Bucket string
Region string
AccessKeyID string
SecretAccessKey string
Endpoint string // Custom endpoint for MinIO/LocalStack
Expiry time.Duration // Default: 15 minutes
KeyPrefix string // Optional prefix prepended to S3 key
}
S3Config configures AWS S3 presigned upload behavior.
type S3Presigner ¶
type S3Presigner struct {
// contains filtered or unexported fields
}
S3Presigner generates presigned PUT URLs for S3 uploads. It implements the livetemplate.Presigner interface.
func NewS3Presigner ¶
func NewS3Presigner(cfg S3Config) (*S3Presigner, error)
NewS3Presigner creates a new S3 presigner with the given configuration.
func (*S3Presigner) Presign ¶
func (p *S3Presigner) Presign(entry *livetemplate.UploadEntry) (livetemplate.UploadMeta, error)
Presign generates a presigned PUT URL for uploading directly to S3.
Click to show internal directories.
Click to hide internal directories.