all repos — dbee @ 6bc91d7e907992c8beeea717c98a830b183af97a

Move PostgreSQL backups using S3

🐛 Fix S3 server management
Tim Izzo tim@octree.ch
Fri, 30 Jul 2021 16:29:26 +0200
commit

6bc91d7e907992c8beeea717c98a830b183af97a

parent

ef17c0ff8508c7cd415693ebcd3e97003175e7dd

3 files changed, 3 insertions(+), 3 deletions(-)

jump to
M cmds/s3/add.jscmds/s3/add.js

@@ -21,8 +21,9 @@ default: 443,

}, useSSL: { alias: "s", + type: "boolean", describe: "Use SSL for server connection", - default: true, + default: false, }, bucket: { alias: "b",
M handlers/s3/add.jshandlers/s3/add.js

@@ -2,7 +2,6 @@ const store = require("../../libs/config/store");

const addS3 = params => { const { s3Name, host, accessKey, secretKey, useSSL, port, bucket } = params; - console.log(params); store("s3", s3Name, { host, accessKey, secretKey, useSSL, port, bucket }); console.log(`S3 server ${s3Name} saved in config`); };
M libs/s3/getConfig.jslibs/s3/getConfig.js

@@ -10,7 +10,7 @@ const serversCount = serverNames.length;

if (serversCount === 1) return { ...s3Servers[serverNames[0]], name: serverNames[0] }; - throw new Error(`No S3 server corresponding to '${s3Servers}' in config.`); + throw new Error(`No S3 server corresponding to '${s3Name}' in config.`); }; module.exports = getS3Config;