From ca7d58ff0e616d9bb1ebb81a70fa783a8fe8f55a Mon Sep 17 00:00:00 2001 From: atef Date: Fri, 30 Jun 2023 10:26:04 +0200 Subject: [PATCH] Fix the run scripts --- csharp/App/SaliMax/run (Salimax 0001).sh | 4 +-- csharp/App/SaliMax/run (Salimax0003).sh | 34 +++++++++++++++++++ .../SaliMax/run (SalimnaxProto Meiringen).sh | 7 ++-- 3 files changed, 39 insertions(+), 6 deletions(-) create mode 100644 csharp/App/SaliMax/run (Salimax0003).sh diff --git a/csharp/App/SaliMax/run (Salimax 0001).sh b/csharp/App/SaliMax/run (Salimax 0001).sh index a138c3067..2091f5208 100755 --- a/csharp/App/SaliMax/run (Salimax 0001).sh +++ b/csharp/App/SaliMax/run (Salimax 0001).sh @@ -2,7 +2,7 @@ dotnet_version='net6.0' salimax_ip= '10.2.3.104' -username='ie-entwicklung@' +username='ie-entwicklung' set -e @@ -11,7 +11,7 @@ echo -e "\n============================ Build ============================\n" dotnet publish \ ./SaliMax.csproj \ -c Release \ - -r linux-x64 + -r linux-x64 echo -e "\n============================ Deploy ============================\n" diff --git a/csharp/App/SaliMax/run (Salimax0003).sh b/csharp/App/SaliMax/run (Salimax0003).sh new file mode 100644 index 000000000..ba6f5b68c --- /dev/null +++ b/csharp/App/SaliMax/run (Salimax0003).sh @@ -0,0 +1,34 @@ +#!/bin/bash + +dotnet_version='net6.0' +salimax_ip='10.2.4.33' +username='ie-entwicklung' + +set -e + +echo -e "\n============================ Build ============================\n" + +dotnet publish \ + ./SaliMax.csproj \ + -p:PublishTrimmed=false \ + -c Release \ + -r linux-x64 + +echo -e "\n============================ Deploy ============================\n" + +rsync -v \ + ./bin/Release/$dotnet_version/linux-x64/publish/* \ + ie-entwicklung@10.2.4.33:~/salimax + +echo -e "\n============================ Restart Salimax sevice ============================\n" + +ssh -tt \ + ie-entwicklung@10.2.4.33 \ + sudo systemctl restart salimax.service + + +echo -e "\n============================ Print service output ============================\n" + +ssh -tt \ + ie-entwicklung@10.2.4.33 \ + journalctl -f -u salimax.service \ No newline at end of file diff --git a/csharp/App/SaliMax/run (SalimnaxProto Meiringen).sh b/csharp/App/SaliMax/run (SalimnaxProto Meiringen).sh index b9c4614cb..f41f8ee9b 100755 --- a/csharp/App/SaliMax/run (SalimnaxProto Meiringen).sh +++ b/csharp/App/SaliMax/run (SalimnaxProto Meiringen).sh @@ -1,9 +1,8 @@ #!/bin/bash - dotnet_version='net6.0' -salimax_ip= '10.2.3.115' -username='ie-entwicklung@' +salimax_ip='10.2.3.115' +username='ie-entwicklung' set -e @@ -13,7 +12,7 @@ dotnet publish \ ./SaliMax.csproj \ -p:PublishTrimmed=false \ -c Release \ - -r linux-x64 + -r linux-x64 echo -e "\n============================ Deploy ============================\n"