Commit Graph

515 Commits

Author SHA1 Message Date
Uwe Seimet
ec42fd9215 Added more device shortcuts to rasctl 2021-09-03 12:53:27 +02:00
Uwe Seimet
e18934d545 Fixed filepath handling 2021-09-03 12:28:39 +02:00
Uwe Seimet
51e807f365 Fixed error handling 2021-09-03 12:21:50 +02:00
Uwe Seimet
169566a0ff Check for attached device for INSERT, EJECT, PROTECT, UNPROTECT 2021-09-02 22:23:25 +02:00
Uwe Seimet
0cbe287665 Remove file from the list of files in use when ejected with a SCSI command 2021-09-02 21:10:55 +02:00
Uwe Seimet
56ee6838b6 Fixed typo 2021-09-02 19:34:23 +02:00
Uwe Seimet
e61ff2dd31 Accept daynaport as legacy type 2021-09-02 18:59:49 +02:00
Uwe Seimet
c0dd442a13 Updated interface comment 2021-09-02 18:56:28 +02:00
Daniel Markstedt
ef6cde56b9
Fix issue where reserved ids were not reserved again when restarting rascsi-service from within the web ui (#226)
* Translate code commends into English, removing redundant ones

* - Translated all remaining Japanese code comments in src/raspberrypi/ to English, with the exception of cfilesystem.cpp|h
- Removed some redundant comments where the context is obvious from the
  code
  - Fixed a few typos and mistakes

* - Store only file path and name to configuration csv
- Strip known non-file path strings when reading configuration csv (backwards compatibility)
- Validate SCSI ID before attempting to attach a device

* Add comment and TODO

* Partial translation of cfilesystem.h

* Move csv read/write logic into file_cmd.py

* Load default.csv on rascsi-web startup

* Add rudimentary error handling to config loading/saving

* Implement a delete configuration csv file feature. Also rename the delete_image method to delete_file and made it take the full file patch as argument to be consistent with other file operation methods.

* Catch the exception when attempting to exclude SCSI id that is already in use from a list of valid SCSI ids

* Fix error handling when failing to open a csv file for read or write

* Run detach_all() only after succeeding to open a file for reading

* Make use of the new 'rasctl -r' command to reserve IDs on the backend side as well.

* Make sure reserved SCSI IDs gets reserved again when restarting rascsi-service from within the web ui
2021-09-02 18:51:18 +02:00
Uwe Seimet
b9dabe7f7b Set/Display patch version 2021-09-02 14:39:59 +02:00
Uwe Seimet
b8d817799a Re-added folder to gitignore 2021-09-01 18:24:10 +02:00
Uwe Seimet
7b84972b4d Fixed detach, which did not remove the filename from the filenames set 2021-09-01 18:20:41 +02:00
Uwe Seimet
4084ef07a1 Removed unused variable 2021-09-01 12:32:04 +02:00
Uwe Seimet
60eeef525a Move string to integer conversion to rasutil 2021-09-01 10:42:06 +02:00
Uwe Seimet
da764200af Improved string to integer conversion 2021-09-01 10:36:34 +02:00
Uwe Seimet
ee98e68d1e Updated string to integer conversions 2021-09-01 10:27:30 +02:00
Daniel Markstedt
bee8fa0d34
Make use of the newly introduced 'rasctl -r' to have the webui reserve ids on the backend side upon startup (#224)
* Translate code commends into English, removing redundant ones

* - Translated all remaining Japanese code comments in src/raspberrypi/ to English, with the exception of cfilesystem.cpp|h
- Removed some redundant comments where the context is obvious from the
  code
  - Fixed a few typos and mistakes

* - Store only file path and name to configuration csv
- Strip known non-file path strings when reading configuration csv (backwards compatibility)
- Validate SCSI ID before attempting to attach a device

* Add comment and TODO

* Partial translation of cfilesystem.h

* Move csv read/write logic into file_cmd.py

* Load default.csv on rascsi-web startup

* Add rudimentary error handling to config loading/saving

* Implement a delete configuration csv file feature. Also rename the delete_image method to delete_file and made it take the full file patch as argument to be consistent with other file operation methods.

* Catch the exception when attempting to exclude SCSI id that is already in use from a list of valid SCSI ids

* Fix error handling when failing to open a csv file for read or write

* Run detach_all() only after succeeding to open a file for reading

* Make use of the new 'rasctl -r' command to reserve IDs on the backend side as well.
2021-09-01 10:09:02 +02:00
Uwe Seimet
dea9642c92 Logging update 2021-08-31 22:16:52 +02:00
Uwe Seimet
b7ba01f97f Re-ordered logging 2021-08-31 21:34:02 +02:00
Uwe Seimet
9472c5e334 rasctl output update 2021-08-31 20:37:33 +02:00
Uwe Seimet
5e7183a637 Added support for reserved IDs 2021-08-31 20:17:23 +02:00
Daniel Markstedt
65cf69c022
Feature configurable reserved id for rascsi-web (#223)
* Translate code commends into English, removing redundant ones

* - Translated all remaining Japanese code comments in src/raspberrypi/ to English, with the exception of cfilesystem.cpp|h
- Removed some redundant comments where the context is obvious from the
  code
  - Fixed a few typos and mistakes

* - Store only file path and name to configuration csv
- Strip known non-file path strings when reading configuration csv (backwards compatibility)
- Validate SCSI ID before attempting to attach a device

* Add comment and TODO

* Partial translation of cfilesystem.h

* Move csv read/write logic into file_cmd.py

* Load default.csv on rascsi-web startup

* Add rudimentary error handling to config loading/saving

* Implement a delete configuration csv file feature. Also rename the delete_image method to delete_file and made it take the full file patch as argument to be consistent with other file operation methods.

* Catch the exception when attempting to exclude SCSI id that is already in use from a list of valid SCSI ids

* Fix error handling when failing to open a csv file for read or write

* Run detach_all() only after succeeding to open a file for reading

* Make the reserved SCSI id configurable through an argument to start.sh; make the rascsi-web service reserve 7 by default to maintain current behavior.

* Make it possible to reserve multiple scsi ids in the web ui
2021-08-31 20:01:30 +02:00
Uwe Seimet
21a7dad7da Restore files in use if dry-run fails 2021-08-31 18:47:58 +02:00
Uwe Seimet
560997134f Fixed typos 2021-08-31 18:21:44 +02:00
Uwe Seimet
44d6696636 Comment update 2021-08-31 18:18:59 +02:00
Uwe Seimet
b83b76e9f3 Extract detaching all devices, add parameter list support 2021-08-31 18:11:41 +02:00
Uwe Seimet
5a6c83c21c Updated error message 2021-08-31 09:08:25 +02:00
Uwe Seimet
302df888da Protecting/unprotecing a non-ready medium is considered not possible 2021-08-30 22:13:01 +02:00
Daniel Markstedt
45e10480f5
Fixed unnecessary detach_all() when config file isn't read (#221)
* Translate code commends into English, removing redundant ones

* - Translated all remaining Japanese code comments in src/raspberrypi/ to English, with the exception of cfilesystem.cpp|h
- Removed some redundant comments where the context is obvious from the
  code
  - Fixed a few typos and mistakes

* - Store only file path and name to configuration csv
- Strip known non-file path strings when reading configuration csv (backwards compatibility)
- Validate SCSI ID before attempting to attach a device

* Add comment and TODO

* Partial translation of cfilesystem.h

* Move csv read/write logic into file_cmd.py

* Load default.csv on rascsi-web startup

* Add rudimentary error handling to config loading/saving

* Implement a delete configuration csv file feature. Also rename the delete_image method to delete_file and made it take the full file patch as argument to be consistent with other file operation methods.

* Catch the exception when attempting to exclude SCSI id that is already in use from a list of valid SCSI ids

* Fix error handling when failing to open a csv file for read or write

* Run detach_all() only after succeeding to open a file for reading
2021-08-30 20:56:40 +02:00
Uwe Seimet
6c5fae6304 Allow empty device list 2021-08-30 20:44:16 +02:00
Uwe Seimet
83389cd06f Added missing return statement 2021-08-30 18:42:19 +02:00
Uwe Seimet
4ab91e90fc Improved error handling 2021-08-30 18:41:02 +02:00
Uwe Seimet
0cb350f9c9 Comment update 2021-08-30 18:39:06 +02:00
Uwe Seimet
4008ac1f71 Updated list handling of protobuf interface 2021-08-30 18:30:59 +02:00
Uwe Seimet
5bf66a99a1 Added number of supported LUNs to protobuf interface 2021-08-30 15:47:56 +02:00
Uwe Seimet
2bec655b0c Updated error messages and exception handling 2021-08-30 15:36:11 +02:00
Uwe Seimet
b67ac954f2 Options -h and -v do not require to be the root user (fixes issue #166) 2021-08-30 15:21:40 +02:00
Uwe Seimet
76bd7bd882 Removed goto 2021-08-30 14:39:26 +02:00
Uwe Seimet
11f9e9cfa2 Updated GetEventStatusNotification 2021-08-30 14:25:44 +02:00
Uwe Seimet
ff84b139d1 Comment update 2021-08-30 14:23:18 +02:00
Uwe Seimet
29b0a7e839 Comment update 2021-08-30 14:22:52 +02:00
Uwe Seimet
47b43cd832 Updated logging 2021-08-30 14:21:49 +02:00
Uwe Seimet
eb0eced1ef Removed TODO 2021-08-30 13:56:22 +02:00
Uwe Seimet
3814c242a3 Refactoring 2021-08-30 13:44:25 +02:00
Uwe Seimet
5880ddc05d Renaming 2021-08-30 13:29:50 +02:00
Uwe Seimet
4859c17ee3 Removed duplicate code 2021-08-30 13:11:17 +02:00
Uwe Seimet
d46013934a Renaming 2021-08-30 13:01:06 +02:00
Uwe Seimet
2edac296a6 Renaming 2021-08-30 12:54:49 +02:00
Uwe Seimet
399c560aa9 Logging update 2021-08-30 12:09:02 +02:00
Uwe Seimet
6f9c5a543c Data type updated, use #pragma once 2021-08-30 12:04:57 +02:00