Explorar o código

Fix stop script, add default var expansion for root-folder

Nicolas Meienberger %!s(int64=3) %!d(string=hai) anos
pai
achega
6b1522babb

+ 1 - 1
packages/system-api/src/modules/system/system.controller.ts

@@ -65,7 +65,7 @@ const getMemoryInfo = async (req: Request, res: Response<MemoryData>) => {
   res.status(200).json(result);
   res.status(200).json(result);
 };
 };
 
 
-const getVersion = async (_: Request, res: Response<{ current: string; latest: string }>) => {
+const getVersion = async (req: Request, res: Response<{ current: string; latest: string }>) => {
   let version = TipiCache.get<string>('latestVersion');
   let version = TipiCache.get<string>('latestVersion');
 
 
   if (!version) {
   if (!version) {

+ 2 - 1
scripts/app.sh

@@ -60,7 +60,8 @@ if [ -z ${2+x} ]; then
   exit 1
   exit 1
 else
 else
   app="$2"
   app="$2"
-  root_folder_host="$3"
+  root_folder_host="${3:-$ROOT_FOLDER}"
+
   app_dir="${ROOT_FOLDER}/apps/${app}"
   app_dir="${ROOT_FOLDER}/apps/${app}"
   app_data_dir="${ROOT_FOLDER}/app-data/${app}"
   app_data_dir="${ROOT_FOLDER}/app-data/${app}"