yum install cups -y yum install foomatic* -y yum install avahi avahi-tools -y
systemctl enable cups systemctl enable avahi-daemon systemctl start cups systemctl start avahi-daemon
after each change in configuration, restart both of them using
systemctl restart cups systemctl restart avahi-daemon
lynx localhost:631 – allow from remote, then from your computer go to prinserver:631 and configure cups via web gui.
If you can’t see the printer from IOS or OSX, check /etc/avahi/services if a proper .service file was created,
if not, use the python generator from here:
https://raw.github.com/tjfontaine/airprint-generate/master/airprint-generate.py
In order to use bonjour/airprint from Windows machines, install first
https://support.apple.com/kb/dl999?locale=en_GB
https://support.apple.com/kb/dl999?locale=en_GB
https://support.apple.com/kb/dl999?locale=en_GB
https://wiki.archlinux.org/index.php/Avahi
https://support.apple.com/kb/dl999?locale=en_GB