sftp: prefix the id with app- and volume-

this helps the backend identify the type of mount
This commit is contained in:
Girish Ramakrishnan
2021-09-25 23:27:25 -07:00
parent 8553b57982
commit d4edd771b5
3 changed files with 15 additions and 8 deletions

View File

@@ -240,7 +240,7 @@ function initializeExpressSync() {
router.post('/api/v1/apps/:id/clone', json, token, routes.apps.load, authorizeAdmin, routes.apps.clone);
router.get ('/api/v1/apps/:id/download', token, routes.apps.load, authorizeOperator, routes.apps.downloadFile);
router.post('/api/v1/apps/:id/upload', json, token, multipart, routes.apps.load, authorizeOperator, routes.apps.uploadFile);
router.use ('/api/v1/apps/:id/files/*', token, routes.apps.load, authorizeOperator, routes.filemanager.proxy);
router.use ('/api/v1/apps/:id/files/*', token, routes.apps.load, authorizeOperator, routes.filemanager.proxyAppData);
router.get ('/api/v1/apps/:id/exec', token, routes.apps.load, authorizeOperator, routes.apps.exec);
// websocket cannot do bearer authentication
@@ -317,7 +317,7 @@ function initializeExpressSync() {
router.get ('/api/v1/volumes/:id', token, authorizeAdmin, routes.volumes.load, routes.volumes.get);
router.del ('/api/v1/volumes/:id', token, authorizeAdmin, routes.volumes.load, routes.volumes.del);
router.get ('/api/v1/volumes/:id/status', token, authorizeAdmin, routes.volumes.load, routes.volumes.getStatus);
router.use ('/api/v1/volumes/:id/files/*', token, authorizeAdmin, routes.filemanager.proxy);
router.use ('/api/v1/volumes/:id/files/*', token, authorizeAdmin, routes.filemanager.proxyVolumeData);
// service routes
router.get ('/api/v1/services', token, authorizeAdmin, routes.services.list);