From 0614c15e3ed8b8482febaf6113a7f53ef006df18 Mon Sep 17 00:00:00 2001 From: Disassembler Date: Fri, 10 Apr 2020 20:19:53 +0200 Subject: [PATCH] Fix start-autostarted / stop-all --- etc/init.d/spoc | 2 +- usr/bin/spoc-app | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/etc/init.d/spoc b/etc/init.d/spoc index dbd78f0..c248117 100755 --- a/etc/init.d/spoc +++ b/etc/init.d/spoc @@ -8,7 +8,7 @@ depend() { } start() { - /usr/bin/spoc-app autostart + /usr/bin/spoc-app start-autostarted } stop() { diff --git a/usr/bin/spoc-app b/usr/bin/spoc-app index 8285b9e..22c56ce 100755 --- a/usr/bin/spoc-app +++ b/usr/bin/spoc-app @@ -20,7 +20,7 @@ def listing(list_type): apps = repo_online.get_apps() elif list_type == 'updates': online_apps = repo_online.get_apps() - apps = [a for a,d in repo_local.get_apps() if a in online_apps and parse_version(online_apps[a]['version']) > parse_version(d['version'])] + apps = [a for a,d in repo_local.get_apps().items() if a in online_apps and parse_version(online_apps[a]['version']) > parse_version(d['version'])] elif list_type == 'published': apps = repo_publish.get_apps() for app in apps: @@ -101,13 +101,13 @@ def autostart(app_name, value): def start_autostarted(): # Start all applications (resp. their containers) which are set to be autoostarted on boot - apps = [App(a) for a,d in repo_local.get_apps() if d['autostart']] + apps = [App(a) for a,d in repo_local.get_apps().items() if d['autostart']] for app in apps: app.start() def stop_all(): # Stop all applications (resp. their containers) - apps = [App(a) for a,d in repo_local.get_apps()] + apps = [App(a) for a,d in repo_local.get_apps().items()] for app in apps: app.stop()