A Pi 3B+ (stickah.local) shares a Phomemo PM246 to the LAN as a plain CUPS queue, so any machine can print 4x6 labels -- fulfillr-site's shipping labels in particular -- without installing the vendor driver, which is x86-64 only. The role builds the TSPL CUPS driver from source instead. It is Debian, not Fedora, so it lives in its own inventory and playbook (make deploy-labelprint / check-labelprint) and the home.debyl.io roles can never run against it. make bootfs renders its cloud-init first-boot files onto a freshly imaged SD card from the same templates the role uses. The Wi-Fi credentials for the home and rescue networks are in the vault. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
42 lines
1.1 KiB
YAML
42 lines
1.1 KiB
YAML
---
|
|
- name: restart cups
|
|
become: true
|
|
ansible.builtin.systemd:
|
|
name: cups.service
|
|
state: restarted
|
|
|
|
- name: reload udev rules
|
|
become: true
|
|
ansible.builtin.command:
|
|
argv: [udevadm, control, --reload-rules]
|
|
changed_when: true
|
|
notify: trigger udev
|
|
|
|
# --action=add, not the default "change": udev only creates SYMLINK+= entries
|
|
# when a device is added, so a change event reloads the rule and leaves
|
|
# /dev/usb/tspl-label missing until the printer is next replugged or rebooted.
|
|
- name: trigger udev
|
|
become: true
|
|
ansible.builtin.command:
|
|
argv: [udevadm, trigger, --subsystem-match=usbmisc, --action=add]
|
|
changed_when: true
|
|
|
|
- name: reload systemd
|
|
become: true
|
|
ansible.builtin.systemd:
|
|
daemon_reload: true
|
|
|
|
# NetworkManager only reads new keyfiles from disk on request. This does not
|
|
# disturb the live connection.
|
|
- name: reload networkmanager connections
|
|
become: true
|
|
ansible.builtin.command:
|
|
argv: [nmcli, connection, reload]
|
|
changed_when: true
|
|
|
|
- name: reload nftables
|
|
become: true
|
|
ansible.builtin.systemd:
|
|
name: nftables.service
|
|
state: reloaded
|