Maven copy local file to remote server using SSH

Viewed 66851

Can Maven copy local file to a remote server using SSH?

I want to specify location in maven configuration file and to copy that file (or files) to server each time deploy phase is executed.

6 Answers

Why not use the Ant SCP task, which you can run within Maven?

Maven is not a generic tool, it's a tool to make your build process reusable. I suggest to use an embedded antrun build step. In this step, you can do anything using the normal ant syntax which you'd use in build.xml.

Related