refactor into getServiceConfig

This commit is contained in:
Girish Ramakrishnan
2023-08-03 12:52:47 +05:30
parent bbc6ba1a35
commit a4d57e7b08
3 changed files with 10 additions and 7 deletions

View File

@@ -51,8 +51,7 @@ async function start(existingInfra) {
debug('start: re-creating container');
const servicesConfig = await services.getConfig();
const serviceConfig = servicesConfig['sftp'] || {};
const serviceConfig = await services.getServiceConfig('sftp');
const tag = infra.images.sftp.tag;
const memoryLimit = serviceConfig.memoryLimit || exports.DEFAULT_MEMORY_LIMIT;
const memory = await system.getMemoryAllocation(memoryLimit);