mirror of
https://github.com/eworm-de/routeros-scripts.git
synced 2026-07-05 17:01:38 +00:00
Compare commits
67 commits
0b87310301
...
b5e6b9cb55
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b5e6b9cb55 | ||
|
|
3e34f2d88a | ||
|
|
38802c16f2 | ||
|
|
a4a5c09e2a | ||
|
|
73dccfeb28 | ||
|
|
ef18e98b9b | ||
|
|
b5444cf2fd | ||
|
|
91479a1e4c | ||
|
|
02d763ca02 | ||
|
|
51a228e897 | ||
|
|
b0ad0c3dbd | ||
|
|
cddf7417f5 | ||
|
|
0bb63d4465 | ||
|
|
ed5092b0c7 | ||
|
|
6ea74adcef | ||
|
|
7fb5c8936d | ||
|
|
9848e6a4b2 | ||
|
|
1ba2dce274 | ||
|
|
76f84bd525 | ||
|
|
1a19eefd07 | ||
|
|
01467ce142 | ||
|
|
9ca4a8ef5d | ||
|
|
837a3a22fd | ||
|
|
a4d084d0e0 | ||
|
|
f31ec1f411 | ||
|
|
f49f931b51 | ||
|
|
35e029afca | ||
|
|
76463098b9 | ||
|
|
8213cf54ca | ||
|
|
ba4846b912 | ||
|
|
f8440e3e77 | ||
|
|
a8ef2a967e | ||
|
|
f5a88be0dc | ||
|
|
0a24236008 | ||
|
|
49cd55ed68 | ||
|
|
31dd558e34 | ||
|
|
3a0a9f1129 | ||
|
|
f0573ef876 | ||
|
|
b8c2c29cbb | ||
|
|
f478123a77 | ||
|
|
d2607d8fc3 | ||
|
|
8eb4fa17de | ||
|
|
19aae0a877 | ||
|
|
924c8137a9 | ||
|
|
77e7874ab8 | ||
|
|
b8da69650b | ||
|
|
9a5fc63a3a | ||
|
|
99f129b631 | ||
|
|
5d62609761 | ||
|
|
b3f7df8d9c | ||
|
|
4aaae00e53 | ||
|
|
cfcb69d26a | ||
|
|
a7ad11d4fd | ||
|
|
fde9f2db71 | ||
|
|
83a485619a | ||
|
|
6810a60546 | ||
|
|
fa077e96b8 | ||
|
|
2436932dff | ||
|
|
41057fb80a | ||
|
|
7398b34cc7 | ||
|
|
f7b147dc55 | ||
|
|
244027c90b | ||
|
|
d52feb86f6 | ||
|
|
65d6044793 | ||
|
|
9056e6d10c | ||
|
|
e3d217732c | ||
|
|
ca1dc1e23a |
4 changed files with 4 additions and 22 deletions
|
|
@ -37,8 +37,7 @@ Also make sure the device has correct time configured, best is to set up
|
|||
the ntp client.
|
||||
|
||||
Then edit `global-config-overlay`, add `EmailGeneralTo` with a valid
|
||||
recipient address. Optionally add `EmailServerCertificate` if you have
|
||||
certificate verification enabled. Finally reload the configuration.
|
||||
recipient address. Finally reload the configuration.
|
||||
|
||||
> ℹ️ **Info**: Copy relevant configuration from
|
||||
> [`global-config`](../../global-config.rsc) (the one without `-overlay`) to
|
||||
|
|
|
|||
|
|
@ -31,7 +31,6 @@
|
|||
:global EmailGeneralCc "";
|
||||
#:global EmailGeneralTo "mail@example.com";
|
||||
#:global EmailGeneralCc "another@example.com,third@example.com";
|
||||
:global EmailServerCertificate "";
|
||||
|
||||
# You can send Telegram notifications. Register a bot
|
||||
# and add the token and chat ids here, then install the module:
|
||||
|
|
|
|||
|
|
@ -109,13 +109,11 @@
|
|||
:local UseFor [ :tostr $2 ];
|
||||
|
||||
:global CertificateDownload;
|
||||
:global EitherOr;
|
||||
:global LogPrint;
|
||||
:global ParseKeyValueStore;
|
||||
|
||||
:if ([ :len $UseFor ] = 0) do={
|
||||
$LogPrint warning $0 ("The intended use is undefined!");
|
||||
:set UseFor "undefined";
|
||||
}
|
||||
:set UseFor [ $EitherOr $UseFor "undefined" ];
|
||||
|
||||
:if ([ /system/resource/get free-hdd-space ] < 8388608 && \
|
||||
[ /certificate/settings/get crl-download ] = true && \
|
||||
|
|
@ -188,11 +186,7 @@
|
|||
$LogPrint warning $0 ("Failed downloading certificate with CommonName '" . $CommonName . \
|
||||
"' from repository! Trying fallback to mkcert.org...");
|
||||
:do {
|
||||
:local CertSettings [ /certificate/settings/get ];
|
||||
:if ([ :len [ /certificate/find where common-name="ISRG Root X1" ] ] = 0 && \
|
||||
!((($CertSettings->"builtin-trust-store") ~ "fetch" || \
|
||||
($CertSettings->"builtin-trust-store") = "all") && \
|
||||
[ :len [ /certificate/builtin/find where common-name="ISRG Root X1" ] ] > 0)) do={
|
||||
:if ([ :len [ /certificate/find where common-name="ISRG Root X1" ] ] = 0) do={
|
||||
$LogPrint error $0 ("Required certificate is not available.");
|
||||
:return false;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -37,9 +37,7 @@
|
|||
# flush e-mail queue
|
||||
:set FlushEmailQueue do={ :onerror Err {
|
||||
:global EmailQueue;
|
||||
:global EmailServerCertificate;
|
||||
|
||||
:global CertificateAvailable;
|
||||
:global EitherOr;
|
||||
:global EMailGenerateFrom;
|
||||
:global FileExists;
|
||||
|
|
@ -92,14 +90,6 @@
|
|||
:return false;
|
||||
}
|
||||
|
||||
:if ([ /tool/e-mail/get certificate-verification ] ~ "^yes" && \
|
||||
[ :len $EmailServerCertificate ] > 0) do={
|
||||
:if ([ $CertificateAvailable $EmailServerCertificate "email" ] = false) do={
|
||||
$LogPrint warning $0 ("Downloading required certificate failed.");
|
||||
:return false;
|
||||
}
|
||||
}
|
||||
|
||||
/system/scheduler/set interval=($QueueLen . "m") comment="Sending..." \
|
||||
[ find where name="_FlushEmailQueue" ];
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue