If you want to do this without needing to run a print agent somewhere, you can use a ProxyBox Zero. https://pbxz.io/ - it enables direct-to-printer comm from your client web app.