ExpressJS Session Store via Amazon S3
Adam Schodde Version
0.1
npm install connect-s3Store
prefix
: (optional) Prefex of the sessionsaccessKeyId
: Amazon S3 Access KeysecretAccessKey
: Amazon S3 Secret Access Keyssl
: true|false (enabling ssl to Amazon S3)region
: us-east-1|us-west-1|etc.. Amazon S3 RegionbucketName
: Amazon S3 Bucket containing|will contain the sessionsttl
: How long to store sessions in S3 in seconds
var S3Store = require('connect-s3Store')(express);
...
app.use(express.session({
secret: 'someSecret',
cookie: {
httpOnly: false,
secure: true
},
store: new S3Store({
//prefix:
accessKeyId: '',
secretAccessKey: '',
ssl: true,
region: 'us-east-1',
bucketName: '',
ttl: 86400 // 1 day
})
});
Copyright(c) 2013 Adam Schodde sparky1010+github@gmail.com