mirror of
https://git.eworm.de/cgit/routeros-scripts
synced 2025-07-27 14:24:50 +02:00
email-backup: wait for file
This commit is contained in:
parent
ff5cdc3019
commit
8cbb053686
1 changed files with 3 additions and 0 deletions
|
@ -17,6 +17,7 @@
|
||||||
:global CharacterReplace;
|
:global CharacterReplace;
|
||||||
:global DeviceInfo;
|
:global DeviceInfo;
|
||||||
:global LogPrintExit;
|
:global LogPrintExit;
|
||||||
|
:global WaitForFile;
|
||||||
|
|
||||||
:if ($BackupSendBinary != true && \
|
:if ($BackupSendBinary != true && \
|
||||||
$BackupSendExport != true) do={
|
$BackupSendExport != true) do={
|
||||||
|
@ -32,6 +33,7 @@
|
||||||
# binary backup
|
# binary backup
|
||||||
:if ($BackupSendBinary = true) do={
|
:if ($BackupSendBinary = true) do={
|
||||||
/ system backup save encryption=aes-sha256 name=$FileName password=$BackupPassword;
|
/ system backup save encryption=aes-sha256 name=$FileName password=$BackupPassword;
|
||||||
|
$WaitForFile ($FileName . ".backup");
|
||||||
:set BackupFile ($FileName . ".backup");
|
:set BackupFile ($FileName . ".backup");
|
||||||
:set Attach ($Attach, $BackupFile);
|
:set Attach ($Attach, $BackupFile);
|
||||||
}
|
}
|
||||||
|
@ -39,6 +41,7 @@
|
||||||
# create configuration export
|
# create configuration export
|
||||||
:if ($BackupSendExport = true) do={
|
:if ($BackupSendExport = true) do={
|
||||||
/ export terse file=$FileName;
|
/ export terse file=$FileName;
|
||||||
|
$WaitForFile ($FileName . ".rsc");
|
||||||
:set ConfigFile ($FileName . ".rsc");
|
:set ConfigFile ($FileName . ".rsc");
|
||||||
:set Attach ($Attach, $ConfigFile);
|
:set Attach ($Attach, $ConfigFile);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue