Control Folding@Home activity based on Swedish hourly electricity pricing.
Folding@Home clients are available for Linux, Mac and Windows. The script is only tested on Ubuntu but will likely work with minor tweaks on other Linux distributions and MacOS.
Python 3.6+
pip install -r requirements.txt
- Set
area
applicable to your location. Choose one of the supported Swedish regions. - Set
price_threshold
as the maximum spot price you are willing to pay. Folding@Home will pause if spot price exceeds this value. - Set Folding@Home socket
address
andport
. - Set Folding@Home
config_files
andslots
. Commands will be sent to the union of all slots found in config files and explicitly declared slots.
$ sudo touch /var/log/cron/fah-power-control.log
$ sudo chmod 777 /var/log/cron/fah-power-control.log
$ crontab -e
# m h dom mon dow command
0 * * * * /path/to/envs/bin/python /path/to/fah-power-control.py >> /var/log/cron/fah-power-control.log 2>&1