1
我使用快遞服務器來代理從亞馬遜s3下載的文件。我該如何在頭文件中保存文件名,或者在頭文件中設置文件名信息,這樣當用戶下載文件名時,不只是說s3.jpeg,而是正確地說test.jpg?如何使用pkgcloud管道使用s3文件下載時保存文件名
app.get("/s3", function(req, res) {
var client;
client = require('pkgcloud').storage.createClient({
provider: "amazon",
key: "test",
keyId: "test"
});
return client.download({
container: 'test',
remote: 'test.jpg'
}).pipe(res);
});