SickHub / docker-cups-airprint

A standalone CUPS and Avahi (mDNS/Bonjour) server, exposing local printers on AirPrint for iOS devices
GNU General Public License v3.0
162 stars 38 forks source link

broken pipe - cannot assign requested address #75

Closed HackXIt closed 1 year ago

HackXIt commented 1 year ago

I'm trying to deploy the image in portainer swarm environment. I've configured a macvlan network and it should be getting a valid address.

However, when running the service, I get this log with a bunch of errors due to it being unable to start the HTTP server:

D [30/Sep/2023:19:09:26 +0000] [Client 33] PUT /admin/conf/cupsd.conf HTTP/1.1
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Active clients and dirty files", busy="Active clients and dirty files"
D [30/Sep/2023:19:09:26 +0000] [Client 33] Read: status=200, state=9
D [30/Sep/2023:19:09:26 +0000] [Client 33] No authentication data provided.
D [30/Sep/2023:19:09:26 +0000] cupsdIsAuthorized: username=""
localhost - - [30/Sep/2023:19:09:26 +0000] "PUT /admin/conf/cupsd.conf HTTP/1.1" 401 0 - -
D [30/Sep/2023:19:09:26 +0000] [Client 33] cupsdSendHeader: code=401, type="text/html", auth_type=0
D [30/Sep/2023:19:09:26 +0000] [Client 33] WWW-Authenticate: Basic realm=\"CUPS\", PeerCred, Local trc=\"y\"
D [30/Sep/2023:19:09:26 +0000] [Client 33] Closing connection.
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Active clients and dirty files"
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Active clients and dirty files", busy="Dirty files"
D [30/Sep/2023:19:09:26 +0000] [Client 34] Server address is "/run/cups/cups.sock".
D [30/Sep/2023:19:09:26 +0000] [Client 34] Accepted from localhost (Domain)
D [30/Sep/2023:19:09:26 +0000] [Client 34] Waiting for request.
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Active clients and dirty files", busy="Active clients and dirty files"
D [30/Sep/2023:19:09:26 +0000] [Client 35] Server address is "/run/cups/cups.sock".
D [30/Sep/2023:19:09:26 +0000] [Client 35] Accepted from localhost (Domain)
D [30/Sep/2023:19:09:26 +0000] [Client 35] Waiting for request.
D [30/Sep/2023:19:09:26 +0000] [Client 34] HTTP_STATE_WAITING Closing for error 32 (Broken pipe)
D [30/Sep/2023:19:09:26 +0000] [Client 34] Closing connection.
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Active clients and dirty files"
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Active clients and dirty files", busy="Dirty files"
D [30/Sep/2023:19:09:26 +0000] [Client 36] Server address is "/run/cups/cups.sock".
D [30/Sep/2023:19:09:26 +0000] [Client 36] Accepted from localhost (Domain)
D [30/Sep/2023:19:09:26 +0000] [Client 36] Waiting for request.
D [30/Sep/2023:19:09:26 +0000] [Client 35] HTTP_STATE_WAITING Closing for error 32 (Broken pipe)
D [30/Sep/2023:19:09:26 +0000] [Client 35] Closing connection.
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Active clients and dirty files"
D [30/Sep/2023:19:09:26 +0000] [Client 36] PUT /admin/conf/cupsd.conf HTTP/1.1
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Active clients and dirty files", busy="Dirty files"
D [30/Sep/2023:19:09:26 +0000] [Client 36] Read: status=200, state=9
D [30/Sep/2023:19:09:26 +0000] [Client 36] Authorized as root using PeerCred.
D [30/Sep/2023:19:09:26 +0000] cupsdIsAuthorized: username="root"
D [30/Sep/2023:19:09:26 +0000] [Client 36] AppArmor not in use.
D [30/Sep/2023:19:09:26 +0000] [Client 36] Read: status=100, state=9
I [30/Sep/2023:19:09:26 +0000] [Client 36] Installing config file "/etc/cups/cupsd.conf"...
localhost - root [30/Sep/2023:19:09:26 +0000] "PUT /admin/conf/cupsd.conf HTTP/1.1" 201 4726 - -
D [30/Sep/2023:19:09:26 +0000] [Client 36] cupsdSendHeader: code=201, type="(null)", auth_type=0
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Active clients and dirty files"
D [30/Sep/2023:19:09:26 +0000] [Client 36] Closing connection.
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Dirty files"
I [30/Sep/2023:19:09:26 +0000] Generating printcap /run/cups/printcap...
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Not busy", busy="Dirty files"
I [30/Sep/2023:19:09:26 +0000] Listening to [v1.::1]:631 (IPv6)
I [30/Sep/2023:19:09:26 +0000] Listening to 127.0.0.1:631 (IPv4)
I [30/Sep/2023:19:09:26 +0000] Listening to /run/cups/cups.sock (Domain)
I [30/Sep/2023:19:09:26 +0000] Remote access is disabled.
D [30/Sep/2023:19:09:26 +0000] Added auto ServerAlias airprint-bridge
I [30/Sep/2023:19:09:26 +0000] Loaded configuration file "/etc/cups/cupsd.conf"
D [30/Sep/2023:19:09:26 +0000] Using keychain "/etc/cups/ssl" for server name "airprint-bridge".
I [30/Sep/2023:19:09:26 +0000] Configured for up to 100 clients.
I [30/Sep/2023:19:09:26 +0000] Allowing up to 100 client connections per host.
I [30/Sep/2023:19:09:26 +0000] Using policy "default" as the default.
D [30/Sep/2023:19:09:26 +0000] cupsdMarkDirty(--p--)
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Not busy"
I [30/Sep/2023:19:09:26 +0000] Partial reload complete.
E [30/Sep/2023:19:09:26 +0000] Unable to open listen socket for address [v1.::1]:631 - Cannot assign requested address.
I [30/Sep/2023:19:09:26 +0000] Listening to 127.0.0.1:631 on fd 4...
I [30/Sep/2023:19:09:26 +0000] Listening to /run/cups/cups.sock on fd 5...
I [30/Sep/2023:19:09:26 +0000] Resuming new connection processing...
D [30/Sep/2023:19:09:26 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Dirty files"
D [30/Sep/2023:19:09:26 +0000] Discarding unused server-restarted event...
--> adding printers
CUPS_LPADMIN_PRINTER1 = 
--> CUPS configured
===========================================================
The dockerized CUPS instance is now ready for use! The web
interface is available here:
URL:       http://10.1.0.224:631/ or http://airprint-bridge:631/
Username:  "admin"
Password:  41rpr1nt
===========================================================
D [30/Sep/2023:19:09:34 +0000] cupsdSetBusyState: newbusy="Active clients and dirty files", busy="Dirty files"
D [30/Sep/2023:19:09:34 +0000] [Client 37] Server address is "127.0.0.1".
D [30/Sep/2023:19:09:34 +0000] [Client 37] Accepted from localhost:43158 (IPv4)
D [30/Sep/2023:19:09:34 +0000] [Client 37] Waiting for request.
D [30/Sep/2023:19:09:34 +0000] cupsdAddCert: Adding certificate for PID 0
D [30/Sep/2023:19:09:34 +0000] [Client 37] Connection now encrypted.
D [30/Sep/2023:19:09:34 +0000] [Client 37] HEAD /printers/ HTTP/1.1
D [30/Sep/2023:19:09:34 +0000] cupsdSetBusyState: newbusy="Active clients and dirty files", busy="Active clients and dirty files"
D [30/Sep/2023:19:09:34 +0000] [Client 37] Read: status=200, state=4
D [30/Sep/2023:19:09:34 +0000] [Client 37] No authentication data provided.
D [30/Sep/2023:19:09:34 +0000] [Client 37] cupsdSendHeader: code=200, type="(null)", auth_type=0
localhost - - [30/Sep/2023:19:09:34 +0000] "HEAD /printers/ HTTP/1.1" 200 0 - -
D [30/Sep/2023:19:09:34 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Active clients and dirty files"
D [30/Sep/2023:19:09:34 +0000] [Client 37] HTTP_STATE_WAITING Closing for error 32 (Broken pipe)
D [30/Sep/2023:19:09:34 +0000] [Client 37] Closing connection.
D [30/Sep/2023:19:09:34 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Dirty files"
D [30/Sep/2023:19:09:34 +0000] [Client 37] Waiting for socket close.
D [30/Sep/2023:19:09:34 +0000] [Client 37] Closing on EOF.
D [30/Sep/2023:19:09:34 +0000] [Client 37] Closing connection.
D [30/Sep/2023:19:09:34 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Dirty files"
D [30/Sep/2023:19:09:34 +0000] cupsdSetBusyState: newbusy="Active clients and dirty files", busy="Dirty files"
D [30/Sep/2023:19:09:34 +0000] [Client 38] Server address is "/run/cups/cups.sock".
D [30/Sep/2023:19:09:34 +0000] [Client 38] Accepted from localhost (Domain)
D [30/Sep/2023:19:09:34 +0000] [Client 38] Waiting for request.
D [30/Sep/2023:19:09:34 +0000] [Client 38] HTTP_STATE_WAITING Closing for error 32 (Broken pipe)
D [30/Sep/2023:19:09:34 +0000] [Client 38] Closing connection.
D [30/Sep/2023:19:09:34 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Active clients and dirty files"

This is my compose file:

version: '3.0'

networks:
  home_macvlan_machine-city:                         # Name of macvlan network
    external: true

services:
  airprint-bridge:
    container_name: airprint-bridge
    image: drpsychick/airprint-bridge
    hostname: ${HOSTNAME}
    #cap_add:
    #- NET_ADMIN
    networks:
      home_macvlan_machine-city:
        ipv4_address: ${CUPS_IP}
    #ports:
    #  - "137:137/udp"
    #  - "139:139/tcp"
    #  - "445:445/tcp"
    #  - "631:631/tcp"
    #  - "5353:5353/udp"
    environment:
      - CUPS_ADMIN_USER=${CUPS_ADMIN_USER:-"admin"}
      - CUPS_ADMIN_PASSWORD=${CUPS_ADMIN_PASSWORD:-"secr3t"}
      - CUPS_WEBINTERFACE=${CUPS_WEBINTERFACE:-"yes"}
      - CUPS_SHARE_PRINTERS=${CUPS_SHARE_PRINTERS:-"yes"}
      - CUPS_REMOTE_ADMIN=${CUPS_REMOTE_ADMIN:-"yes"} # allow admin from non local source
      - CUPS_ACCESS_LOGLEVEL=${CUPS_ACCESS_LOGLEVEL:-"all"} # all, access, config, see `man cupsd.conf`
      - CUPS_LOGLEVEL=${CUPS_LOGLEVEL:-"debug"} # error, warn, info, debug, debug2 see `man cupsd.conf`
      - CUPS_ENV_DEBUG=${CUPS_ENV_DEBUG:-"no"} # debug startup script and activate CUPS debug logging
      #- CUPS_IP=${CUPS_IP:-$(hostname -i)} # no need to set this usually
      #- CUPS_HOSTNAME=${CUPS_HOSTNAME:-$(hostname -f)} # no need to set this usually -> allows accessing cups via name: https://cups.domain:631/
      # pass the server cert/key via env in one line each, i.e. CUPS_SSL_CERT=---- BEGIN CERT ...\none\nline\nseparated\nby\nbackslash\nnewline
      #- CUPS_SSL_CERT=${CUPS_SSL_CERT:-""}
      #- CUPS_SSL_KEY=${CUPS_SSL_KEY:-""}
      # avahi configuration options
      - AVAHI_INTERFACES=${AVAHI_INTERFACES:-"eth0"}
      - AVAHI_IPV6=${AVAHI_IPV6:-"no"}
      - AVAHI_REFLECTOR=${AVAHI_REFLECTOR:-"no"}
      - AVAHI_REFLECT_IPV=${AVAHI_REFLECT_IPV:-"no"}
    ipc: shareable
    restart: unless-stopped
    deploy:
      placement:
        constraints: [node.hostname == machine-city]

Can anyone help with this?

HackXIt commented 1 year ago

I'm even getting this issue without the macvlan network, so I'm clearly missing something

DrPsychick commented 1 year ago

One thing to point out is that dashes (-) in yaml might not be supported: https://stackoverflow.com/questions/57586664/using-dash-as-part-of-key-name-in-parameters

for fun with YAML: https://noyaml.com

HackXIt commented 1 year ago

Which key are you referring to?

The one for the network? That appears to work, even on my other stacks, without problems. When connecting to the container, I can also see the network interface.

Funny link though

DrPsychick commented 1 year ago

ok, then it seems unrelated. What I do notice is Listening to 127.0.0.1:631 (IPv4) which means cups is not listening on the public IP. You could check if your cups.conf has Listen *:631 which should be the case when enabling remote admin: https://github.com/SickHub/docker-cups-airprint/blob/c7558a68a89fdf39577eb1197bcd62d2ca4ee378/start-cups.sh#L41

maybe it also gives some more clues when enabling debug logs: CUPS_ENV_DEBUG. That said, I would set the ENVs explicitly or leave them out. ${CUPS_ADMIN_USER:-"admin"} just means it sets "admin" if the variable is not set or defined which is already part of the startup script.

HackXIt commented 1 year ago

It does listen on all interfaces, and I am not using any cups.conf, so it should be default settings for everything.

That said, I did enable CUPS_ENV_DEBUG now to see what happens: _cups-airprint-bridge_airprint-bridge.1.kn56a7gwmaz50qv591w1e2fnm_logs(1).txt

I did notice something odd at the beginning:

++ hostname -i
+ CUPS_IP=10.1.0.224
++ hostname -f
+ CUPS_HOSTNAME=airprint-bridge
declare -x AVAHI_INTERFACES="\"\""
declare -x AVAHI_IPV6="\"no\""
declare -x AVAHI_REFLECTOR="\"no\""
declare -x AVAHI_REFLECT_IPV="\"no\""
declare -x CUPS_ACCESS_LOGLEVEL="\"all\""
declare -x CUPS_ADMIN_PASSWORD="41rpr1nt"
declare -x CUPS_ADMIN_USER="\"admin\""
+ CUPS_ADMIN_USER='"admin"'
+ CUPS_ADMIN_PASSWORD=41rpr1nt
+ CUPS_WEBINTERFACE='"yes"'
+ CUPS_SHARE_PRINTERS='"yes"'
+ CUPS_REMOTE_ADMIN='"yes"'
+ CUPS_ACCESS_LOGLEVEL='"all"'
+ CUPS_LOGLEVEL='"debug"'
+ CUPS_SSL_CERT=
+ CUPS_SSL_KEY=
+ AVAHI_INTERFACES='""'
+ AVAHI_FRIENDLY_DESC=:-no
+ AVAHI_IPV6='"no"'
+ AVAHI_REFLECTOR='"no"'
+ AVAHI_REFLECT_IPV='"no"'
+ '[' yes = yes ']'
+ export -n
declare -x CUPS_ENV_DEBUG="yes"
declare -x CUPS_IP="10.1.0.224"
declare -x CUPS_LOGLEVEL="\"debug\""
declare -x CUPS_LPADMIN_PRINTER1=""
declare -x CUPS_REMOTE_ADMIN="\"yes\""
declare -x CUPS_SHARE_PRINTERS="\"yes\""
declare -x CUPS_WEBINTERFACE="\"yes\""
declare -x DEBIAN_FRONTEND="noninteractive"
declare -x HOME="/root"
declare -x HOSTNAME="airprint-bridge"
declare -x OLDPWD
declare -x PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
declare -x PWD="/"
declare -x SHLVL="1"
declare -x TZ="GMT"
+ printf %s 41rpr1nt
+ LC_ALL=C
+ grep -q '[^ -~]\+'
++ grep -ci '"admin"' /etc/shadow
+ '[' 0 -eq 0 ']'
++ mkpasswd 41rpr1nt
+ useradd '"admin"' --system -g lpadmin --no-create-home --password '$y$j9T$q20XHtGV/Lr64qCPRvsFL.$AxFUMNjXUOZcGIgWvzZP7t86W9hJ202geIFqQsN99z8'
+ [[ 0 -ne 0 ]]
+ sed -i 's/^.*AccessLog .*/AccessLog stderr/' /etc/cups/cups-files.conf
+ sed -i 's/^.*ErrorLog .*/ErrorLog stderr/' /etc/cups/cups-files.conf
+ sed -i 's/^.*PageLog .*/PageLog stderr/' /etc/cups/cups-files.conf
++ grep '^Listen \*:631' /etc/cups/cupsd.conf
+ '[' yes = '"yes"' -a -z '' ']'
+ '[' -n '' -a -n '' ']'
+ mv /usr/bin/smbspool /usr/bin/smbspool.orig
+ echo '#!/bin/sh
cat <&0| /usr/bin/smbspool.orig $DEVICE_URI "$1" "$2" "$3" "$4" "$5"
exit 0
'
+ chmod +x /usr/bin/smbspool
+ '[' -n '""' ']'
+ sed -i 's/^.*allow-interfaces=.*/allow-interfaces=""/' /etc/avahi/avahi-daemon.conf
+ sed -i 's/^.*use-ipv6=.*/use-ipv6="no"/' /etc/avahi/avahi-daemon.conf
+ sed -i 's/^.*publish-aaaa-on-ipv4=.*/publish-aaaa-on-ipv4="no"/' /etc/avahi/avahi-daemon.conf
+ sed -i 's/^.*enable\-reflector=.*/enable\-reflector\="no"/' /etc/avahi/avahi-daemon.conf
+ sed -i 's/^.*reflect\-ipv=.*/reflect\-ipv\="no"/' /etc/avahi/avahi-daemon.conf
+ sed -i 's/^.*enable-dbus=.*/enable-dbus=no/' /etc/avahi/avahi-daemon.conf
+ /opt/airprint/printer-update.sh
      
1
+ true
+ /usr/sbin/avahi-daemon -c
Setting up watches.
Watches established.
      
5
+ /usr/sbin/avahi-daemon
Found user 'avahi' (UID 105) and group 'avahi' (GID 112).
Successfully dropped root privileges.
avahi-daemon 0.8 starting up.
Successfully called chroot().
Successfully dropped remaining capabilities.
No service file found in /etc/avahi/services.
Network interface enumeration completed.
Server startup complete. Host name is airprint-bridge.local. Local service cookie is 2732563847.
+ cupsctl -h localhost:631 --share-printers
+ /usr/sbin/cupsd -f
      
2
+ echo -n .
      
1
E [02/Oct/2023:21:08:54 +0000] Unable to open listen socket for address [v1.::1]:631 - Cannot assign requested address.
+ cupsctl -h localhost:631 --share-printers
localhost - - [02/Oct/2023:21:08:55 +0000] "PUT /admin/conf/cupsd.conf HTTP/1.1" 401 0 - -
localhost - root [02/Oct/2023:21:08:55 +0000] "PUT /admin/conf/cupsd.conf HTTP/1.1" 201 4805 - -
+ cupsctl --debug-logging
E [02/Oct/2023:21:08:55 +0000] Unable to communicate with avahi-daemon: Daemon not running
localhost - - [02/Oct/2023:21:08:55 +0000] "PUT /admin/conf/cupsd.conf HTTP/1.1" 401 0 - -
localhost - root [02/Oct/2023:21:08:55 +0000] "PUT /admin/conf/cupsd.conf HTTP/1.1" 201 4759 - -
I [02/Oct/2023:21:08:55 +0000] Listening to 0.0.0.0:631 (IPv4)
I [02/Oct/2023:21:08:55 +0000] Listening to [v1.::]:631 (IPv6)
I [02/Oct/2023:21:08:55 +0000] Listening to /run/cups/cups.sock (Domain)
+ echo '--> CUPS ready'
.--> CUPS ready
+ '[' yes = yes ']'
+ cupsctl --debug-logging
I [02/Oct/2023:21:08:55 +0000] Remote access is enabled.
D [02/Oct/2023:21:08:55 +0000] Added auto ServerAlias airprint-bridge
I [02/Oct/2023:21:08:55 +0000] Loaded configuration file "/etc/cups/cupsd.conf"
D [02/Oct/2023:21:08:55 +0000] Using keychain "/etc/cups/ssl" for server name "airprint-bridge".
I [02/Oct/2023:21:08:55 +0000] Configured for up to 100 clients.
I [02/Oct/2023:21:08:55 +0000] Allowing up to 100 client connections per host.
I [02/Oct/2023:21:08:55 +0000] Using policy "default" as the default.
D [02/Oct/2023:21:08:55 +0000] cupsdMarkDirty(--p--)
D [02/Oct/2023:21:08:55 +0000] cupsdSetBusyState: newbusy="Dirty files", busy="Not busy"
I [02/Oct/2023:21:08:55 +0000] Partial reload complete.
I [02/Oct/2023:21:08:55 +0000] Listening to 0.0.0.0:631 on fd 4...
I [02/Oct/2023:21:08:55 +0000] Listening to [v1.::]:631 on fd 5...
I [02/Oct/2023:21:08:55 +0000] Listening to /run/cups/cups.sock on fd 6...
I [02/Oct/2023:21:08:55 +0000] Resuming new connection processing...

Here are the environment variables I'm using and weirdly, it uses a wrong IP address as seen in the Log: (it uses the correct one, I had an error in my macvlan subnet. The main Problem is the listening interfaces config as it somehow always tries to use the loopback interface but the remote admin thing doesn't work) grafik

HackXIt commented 1 year ago

Ok, I think it's due to the cups.config... the default is not 0.0.0.0:631 but instead localhost:631.. obviously, that doesn't work.

So, allthough I have enabled remote admin, it still does not configure it the way you described and inside cupsd.config in the container I only see Listen localhost:631

HackXIt commented 1 year ago

This is my interface in the container:

root@a5ec1f004b32:/# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
61: eth0@if2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default 
    link/ether 02:42:0a:01:00:e8 brd ff:ff:ff:ff:ff:ff link-netnsid 0
    inet 10.1.0.232/24 brd 10.1.0.255 scope global eth0
       valid_lft forever preferred_lft forever

I am trying to mount cupsd.conf in the compose file now:

    volumes:
      - /home/dietpi/airprint-bridge/cupsd.conf:/etc/cups/cupds.conf

But all I'm getting now is this:

+ sleep 1
+ cupsctl -h localhost:631 --share-printers
localhost - - [02/Oct/2023:22:50:20 +0000] "PUT /admin/conf/cupsd.conf HTTP/1.1" 401 0 - -
E [02/Oct/2023:22:50:20 +0000] Unable to finalize "/etc/cups/cupsd.conf": Device or resource busy
localhost - root [02/Oct/2023:22:50:20 +0000] "PUT /admin/conf/cupsd.conf HTTP/1.1" 500 4579 - -
+ echo -n .


I really can't figure out how I can mount the cupsd.conf into the container from the host with the file being accessible afterwards.

HackXIt commented 1 year ago

I also tried this:

volumes:
      - type: bind
        source: /home/dietpi/airprint-bridge/cupsd.conf
        target: /etc/cups/cupsd.conf
        read_only: false

But it still results in the above error of the resource being busy... Just HOW can I get this file in the container or otherwise set the listening interfaces to ALL? The default somehow does not work and I'm utterly confused now.

HackXIt commented 1 year ago

I think I fixed it. for some reason the environment variables in the compose file did not actually make it to the actual container.. I also made sure to use AVAHI_INTERFACES="eth0@if2". I can now access everything.