update readme
This commit is contained in:
2 files changed
+7
-2
No files matched your search
@@ -28,9 +28,12 @@ A script to automatically handle the backing up of MongoDB databases and optiona
|
|||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=simple
|
Type=simple
|
||||||
|
User=username
|
||||||
|
Group=admin
|
||||||
Restart=always
|
Restart=always
|
||||||
RestartSec=5
|
RestartSec=46400
|
||||||
ExecStart=/path/to/binary/file
|
WorkingDir=/path/to/project
|
||||||
|
ExecStart=/path/to/project/binary
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
|||||||
@@ -7,6 +7,7 @@ import (
|
|||||||
"log"
|
"log"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"time"
|
"time"
|
||||||
|
"runtime"
|
||||||
|
|
||||||
"github.com/joho/godotenv"
|
"github.com/joho/godotenv"
|
||||||
"strings"
|
"strings"
|
||||||
@@ -16,6 +17,7 @@ const dtFormat string = "2006-01-02 15:04:05 Monday"
|
|||||||
|
|
||||||
func Handle(err error) {
|
func Handle(err error) {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
LogToFile(err.Error())
|
||||||
log.Panic(err.Error())
|
log.Panic(err.Error())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user