diff --git a/src/js/client.js b/src/js/client.js index a1372ec11..5416c602f 100644 --- a/src/js/client.js +++ b/src/js/client.js @@ -1705,7 +1705,7 @@ angular.module('Application').service('Client', ['$http', '$interval', '$timeout if (options.noNullPoints) config.params.noNullPoints = true; - get('/api/v1/cloudron/graphs', config, function (error, data, status) { + get(options.appId ? '/api/v1/apps/' + options.appId + '/graphs' : '/api/v1/cloudron/graphs', config, function (error, data, status) { if (error) return iteratorCallback(error); if (status !== 200) return iteratorCallback(new ClientError(status, data)); diff --git a/src/views/app.js b/src/views/app.js index 1a28bdff5..6a62e9714 100644 --- a/src/views/app.js +++ b/src/views/app.js @@ -773,7 +773,7 @@ angular.module('Application').controller('AppController', ['$scope', '$location' var memoryQuery = 'summarize(sum(collectd.localhost.table-' + appId + '-memory.gauge-rss, collectd.localhost.table-' + appId + '-memory.gauge-swap), "' + timeBucketSize + 'min", "avg")'; - Client.graphs([ memoryQuery ], '-' + timePeriod + 'min', {}, function (error, result) { + Client.graphs([ memoryQuery ], '-' + timePeriod + 'min', { appId: appId }, function (error, result) { if (error) return console.error(error); var currentMemoryLimit = $scope.app.memoryLimit || $scope.app.manifest.memoryLimit || (256 * 1024 * 1024);