- download Raspberry Pi Imager https://www.raspberrypi.com/software/
- choose PI lite OS 32 or 64 bit
- mount image and create a empty file called ssh
- find IP in your network e.g.
nmap -sP 192.168.1.*
- login with ssh pi@ password: raspberry
from hashlib import sha256 | |
MAX_NONCE = 10000000 | |
def create_sha256(text): | |
return sha256(text.encode("ascii")).hexdigest() | |
def mining(block_number, transactions, prev_hash, difficulty): |
nmap -sP 192.168.1.*
Manuelle Installation
login to the new box
https://gist.github.com/stereosupersonic/43367f3934b6de2354779aa1744b4fcc
def remote_file_exits?(url, limit=10) | |
raise ArgumentError, 'too many HTTP redirects' if limit == 0 | |
uri = URI(url) | |
response = Net::HTTP.get_response(uri) | |
case response | |
when Net::HTTPNotFound then | |
false |
AllCops: | |
Include: | |
- '**/*.rb' | |
- '**/*.rake' | |
- '**/Gemfile' | |
Exclude: | |
- '**/tmp/**/*' | |
- '**/vendor/**/*' | |
- '**/node_modules/**/*' |
open https://static01.nyt.com/images/$(date +"%Y/%m/%d")/nytfrontpage/scan.pdf |
#!/usr/bin/env ruby | |
MAX_RETRY = 3 | |
PATH = "/sys/bus/iio/devices/" | |
TEMP_SENSOR = PATH + "iio\:device#{ARGV[0].to_i}/in_temp_input" | |
HUMIDITY_SENSOR = PATH + "iio\:device#{ARGV[0].to_i}/in_humidityrelative_input" | |
def save_read(sensor) | |
run = 1 | |
while run < MAX_RETRY |
ruby '2.7.1' | |
gem 'rails', github: 'rails/rails' | |
gem 'tzinfo-data', '>= 1.2016.7' # Don't rely on OSX/Linux timezone data | |
# Action Text | |
gem 'actiontext', github: 'basecamp/actiontext', ref: 'okra' | |
gem 'okra', github: 'basecamp/okra' | |
# Drivers |