Merge branch 'develop'

This commit is contained in:
2022-05-18 22:02:47 +02:00
30 changed files with 627 additions and 775 deletions

View File

@ -6,74 +6,44 @@
* deleting a drive securely via overwriting
## Screenshot
![alt text](https://git.mosad.xyz/localhorst/reHDD/raw/commit/95828afcc2e417b9cb64a4add98ae9c3c7628e84/doc/screenshot.png "Screenshot")
![alt text](https://git.mosad.xyz/localhorst/reHDD/raw/commit/42bc26eac95429e20c0f0d59f684dfec0d600e75/doc/screenshot.png "Screenshot")
## Debian Build Notes
* apt-get install ncurses-dev git make g++
* clone repo
* make release
* `apt-get install ncurses-dev git make g++`
* `make release`
## Create Standalone with Debian 11
Instructions how to create a standalone machine that boots directly to reHDD. This is aimed for production use, like several drives a day shredding.
* Start reHDD after boot without login (as a tty1 shell)
* Start dmesg after boot without login (as a tty2 shell)
* Start htop after boot without login (as a tty3 shell)
* Upload reHDD log every 12h if wanted
### Software requirements
* apt-get install hwinfo smartmontools curl
### Start reHDD after boot without login (as a tty shell)
nano /lib/systemd/system/getty@.service
and replace the [Service] with this:
```
[Service]
WorkingDirectory=/root/reHDD
ExecStart=
ExecStart=-/root/reHDD/reHDD
StandardInput=tty
StandardOutput=tty
Restart=always
RestartSec=1
UtmpIdentifier=tty1
TTYPath=/dev/tty1
TTYReset=yes
TTYVHangup=yes
TTYVTDisallocate=yes
SendSIGHUP=yes
```
systemctl daemon-reload
nano /etc/systemd/system/reHDDSettings.service
```
[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=/usr/bin/bash /root/reHDDSettings.sh
[Install]
WantedBy=multi-user.target
```
nano /root/reHDDSettings.sh
```
#!/bin/bash
dmesg -n 1 #disable overlay if a drive is attached/detached
# remove comment for the following to activate log telemetie
# curl -k -T /root/reHDD/reHDD.log -u "fgggfffgfgfgfg:" -H 'X-Requested-With: XMLHttpRequest' https://schuttercloud.com/public.php/webdav/`echo $(date '+%Y-%m-%d_%H-%M')`_reHDD.log
rm -f /root/reHDD/reHDD.log
```
chmod +x reHDDSettings.sh
* `apt-get install hwinfo smartmontools curl`
Make sure the binary reHDD is in /root/reHDD/
### Installation
Add your system drive in /root/reHDD/ignoreDrives.conf like:
```e102f49d-5ed5-462b-94c5-ef66a4345671```
Get your UUID via blkid /dev/sdX
clone this repo into /root/
systemctl enable reHDDSettings.service
`cd /root/reHDD/`
`make release`
`bash scripts/install_reHDD.bash`
If you want to upload the logs, edit `scripts/reHDDLogUploader.bash` with your nextcloud token
Add your system drive in `/root/reHDD/ignoreDrives.conf` like:
```e102f49d```
Get the first 8 Bytes from your UUID via `blkid /dev/sdX`
`reboot`
## Build docs
`make docs`
open `doc/html/index.html` in browser