Start G-code
G90 ; use absolute coordinates
M83 ; extruder relative mode
M140 S{first_layer_bed_temperature[0]} ; set final bed temp
M104 S{first_layer_temperature[0]} ; set final nozzle temp
G28 ; home all axis
| # copy from a to b | |
| sudo sgdisk -R /dev/sdb /dev/sda | |
| # randomize guid | |
| sudo sgdisk -G /dev/sdb | |
| # inform the kernel or reboot | |
| sudo partprobe /dev/sdb | |
| sudo proxmox-boot-tool format /dev/sdb --force | |
| sudo proxmox-boot-tool init /dev/sdb |
| import argparse | |
| import os | |
| import sys | |
| import zoneinfo | |
| from datetime import datetime | |
| import shutil | |
| import pandas as pd | |
| from pyicloud import PyiCloudService | |
| from pyicloud.exceptions import PyiCloudAPIResponseException |
Start G-code
G90 ; use absolute coordinates
M83 ; extruder relative mode
M140 S{first_layer_bed_temperature[0]} ; set final bed temp
M104 S{first_layer_temperature[0]} ; set final nozzle temp
G28 ; home all axis
curl -H "X-Forwarded-For: 1.2.3.4" https://example.com
doesn't work for cloudflare proxied domain if it is specifically removed.
We may be still able to "workaround" it by connecting directly to the server.
curl -H "X-Forwarded-For: 1.2.3.4" --resolve example.com:443:$SERVER_IP https://example.com
| import CloudFlare | |
| import requests | |
| myip = requests.get('https://api.ipify.org').content.decode('utf8') | |
| cf = CloudFlare.CloudFlare(token='<TOKEN>') | |
| zones = cf.zones.get(params={'name': '<DOMAIN>'}) | |
| if not zones: | |
| raise Exception("zone not found") |
| dns_cloudflare_api_token = <CLOUDFLARE-API-TOKEN> |
| # /etc/rsyslog.d/homeassistant.conf on client | |
| # Enabling logging in HA | |
| # logger: | |
| # logs: | |
| # homeassistant.components.http.ban: warning | |
| if ($programname == 'homeassistant' and $msg contains 'Login attempt or request with invalid authentication') then { | |
| $ActionQueueFileName fwdRule1 | |
| $ActionQueueMaxDiskSpace 1g |
| # 134 = 16 * 8 + 6, i.e. facility = local0 and severity = info | |
| echo "<134>1 - $HOSTNAME $PROGRAMNAME - - hello world" | nc -u -w 0 $DEST 514 |
| G91 ;Relative positioning | |
| G1 E-2 F2700 ;Retract a bit | |
| G1 E-2 Z0.2 F2400 ;Retract and raise Z | |
| G1 X5 Y5 F3000 ;Wipe out | |
| G1 Z10 ;Raise Z more | |
| G90 ;Absolute positionning | |
| G1 X0 Y0 ;Present print | |
| M106 S0 ;Turn-off fan | |
| M104 S0 ;Turn-off hotend | |
| M140 S0 ;Turn-off bed |
sudo rm -rf /run/systemd-journal-gatewayd.sock
sudo touch /run/systemd-journal-gatewayd.sock
sudo reboot
vim /lib/systemd/system/systemd-journal-gatewayd.socket
[Socket]