changeset 18:64eee582fec1

add move logs while restart
author Vadim Filimonov <fffilimonov@yandex.ru>
date Wed, 19 Jun 2024 11:45:10 +0300
parents 3e8c7d089e30
children a90e510ccc4f
files moveLogs.sh restart.sh
diffstat 2 files changed, 11 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/moveLogs.sh	Wed Jun 19 11:45:10 2024 +0300
@@ -0,0 +1,10 @@
+#!/bin/bash -e
+
+. common.sh;
+
+mv $hgaccesslog ${hgaccesslog}".0";
+
+reposLogsDir=${ROOTPWD}"/logs/repos";
+ls $reposLogsDir | while read filename; do
+  mv $reposLogsDir/$filename $reposLogsDir/${filename}".0";
+done;
--- a/restart.sh	Mon Oct 02 12:23:02 2023 +0300
+++ b/restart.sh	Wed Jun 19 11:45:10 2024 +0300
@@ -3,4 +3,5 @@
 cd `dirname $0`;
 
 ./stop.sh
+./moveLogs.sh
 ./start.sh $*