Add upload backup via FTP/SFTP #11

Open
opened 2021-05-16 18:02:08 +01:00 by rechandler12 · 7 comments
rechandler12 commented 2021-05-16 18:02:08 +01:00 (Migrated from github.com)

Hi!
Could you add uploading file backup via FTP/SFTP protocol? It would required the file name was unique so I suggest to add pattern to the file name like yyyy-MM-dd or yyyy-MM-dd-hh-mm.

Hi! Could you add uploading file backup via FTP/SFTP protocol? It would required the file name was unique so I suggest to add pattern to the file name like `yyyy-MM-dd` or `yyyy-MM-dd-hh-mm`.
beeyev commented 2021-05-16 19:01:10 +01:00 (Migrated from github.com)

Okay, I will (i hope lol) implement this feature in the next release.

Okay, I will (i hope lol) implement this feature in the next release.
rechandler12 commented 2021-05-16 19:02:20 +01:00 (Migrated from github.com)

wow, great! Thanks

wow, great! Thanks
BrandonSk commented 2021-11-11 21:07:59 +00:00 (Migrated from github.com)

Hi,
I added the FTP feature to the script. I do not want to create a separate fork for it and I'm happy to share the code here.
What is the best way to do that?
Cheers,
B.

PS: Nevermind, I made a fork here https://github.com/BrandonSk/Mikrotik-RouterOS-automatic-backup-and-update-With-FTP.
If you like the code, just merge it with the original. Cheers.

PS: As I tried to keep the original functionality intact, but add additional logic, it may not be the most efficient way to do it. I can imagine for future a selection of backup method and adjust the rest of the code accordingly. For me the FTP part works well. I did not test if all possible combinations of email/ftp backup and corresponding logic of the code works as expected.

Hi, I added the FTP feature to the script. I do not want to create a separate fork for it and I'm happy to share the code here. What is the best way to do that? Cheers, B. PS: Nevermind, I made a fork here https://github.com/BrandonSk/Mikrotik-RouterOS-automatic-backup-and-update-With-FTP. If you like the code, just merge it with the original. Cheers. PS: As I tried to keep the original functionality intact, but add additional logic, it may not be the most efficient way to do it. I can imagine for future a selection of backup method and adjust the rest of the code accordingly. For me the FTP part works well. I did not test if all possible combinations of email/ftp backup and corresponding logic of the code works as expected.
beeyev commented 2021-11-13 12:40:35 +00:00 (Migrated from github.com)

Hello @BrandonSk sorry for the delay with answer.
Thank you for implementing this feature, I will take a look and merge your changes.

Hello @BrandonSk sorry for the delay with answer. Thank you for implementing this feature, I will take a look and merge your changes.
BrandonSk commented 2021-11-14 00:57:07 +00:00 (Migrated from github.com)

Hello @BrandonSk sorry for the delay with answer.
Thank you for implementing this feature, I will take a look and merge your changes.

Hi,
no problem.
I made a "v2" of the FTP feature. It now supports SFTP too.
I also made the modifications to the code I suggested above. Now basically you can at the beginning to select if you want to backup to (S)FTP, email, or both. I studied your script and I think the modifications should be fully compatible now.
I would already publish it here, but I just installed Sublime Merge and Sublime Text and I am trying to figure out how to get changes from one to another and then to github :) Hopefully on Sunday I will give you much better solution. Cheers.

> Hello @BrandonSk sorry for the delay with answer. > Thank you for implementing this feature, I will take a look and merge your changes. Hi, no problem. I made a "v2" of the FTP feature. It now supports SFTP too. I also made the modifications to the code I suggested above. Now basically you can at the beginning to select if you want to backup to (S)FTP, email, or both. I studied your script and I think the modifications should be fully compatible now. I would already publish it here, but I just installed Sublime Merge and Sublime Text and I am trying to figure out how to get changes from one to another and then to github :) Hopefully on Sunday I will give you much better solution. Cheers.
TerAnYu commented 2021-11-14 08:26:16 +00:00 (Migrated from github.com)

Пршу прощения что вклиниваюсь, могу дать небольшой набросок, как сделать бэкап всего содержимого корня (очень выручает когда с устройством что-то случается и можно полностью восстановить его функционал, правда это работает только для ftp (не было необходимости отправлять на почту)).
https://github.com/TerAnYu/mikrotik_ftp_backup

I apologize for wedging in, I can give a small sketch of how to make a backup of all the content of the root (it is very helpful when something happens to the device and it is possible to completely restore its functionality, although this only works for ftp (there was no need to send to mail)).
https://github.com/TerAnYu/mikrotik_ftp_backup

Пршу прощения что вклиниваюсь, могу дать небольшой набросок, как сделать бэкап всего содержимого корня (очень выручает когда с устройством что-то случается и можно полностью восстановить его функционал, правда это работает только для ftp (не было необходимости отправлять на почту)). https://github.com/TerAnYu/mikrotik_ftp_backup I apologize for wedging in, I can give a small sketch of how to make a backup of all the content of the root (it is very helpful when something happens to the device and it is possible to completely restore its functionality, although this only works for ftp (there was no need to send to mail)). https://github.com/TerAnYu/mikrotik_ftp_backup
BrandonSk commented 2021-11-14 15:22:28 +00:00 (Migrated from github.com)

Hello all,
I just sent a pull request, so @beeyev you should see that in your repo.
If you want to check it out at my fork, here's the link: https://github.com/BrandonSk/Mikrotik-RouterOS-automatic-backup-and-update-With-FTP/tree/ftp_v2

Cheers,
Branislav.

Hello all, I just sent a pull request, so @beeyev you should see that in your repo. If you want to check it out at my fork, here's the link: https://github.com/BrandonSk/Mikrotik-RouterOS-automatic-backup-and-update-With-FTP/tree/ftp_v2 Cheers, Branislav.
Sign in to join this conversation.
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: darrenofficial/Mikrotik-RouterOS-automatic-backup-and-update#11
No description provided.