How to publish maven packages using ssh access?

I am using pgp keys for:
1.signature
2.authorization (gpg-agent → ssh)

how to use this to publish packages?