73-wagon-ssh远程上传jar等文件并部署

属性值:


        192.168.207.109
        root
        1q2w3e4r5t
        false
        true
        true
        false

添加扩展依赖包:


        
            
                org.apache.maven.wagon
                wagon-ssh
                2.10
            
        

添加插件plugin:


                    org.codehaus.mojo
                    wagon-maven-plugin
                    2.0.2

                    
                        
                            
                                
                                    wagon-ssh
                                    ${ssh.username}
                                    ${ssh.pwd}
                                
                            
                        
                        wagon-ssh
                        scp://${ssh.ip}
                        false
                    
                    
                        
                            ssh-upload-yml
                            package
                            
                                upload
                            
                            
                                ${ssh.yml.skip}
                                target/classes
                                ${ssh.path}
                                *.yml
                            
                        
                        
                            ssh-upload-lib
                            package
                            
                                upload
                            
                            
                                ${ssh.lib.skip}
                                target
                                ${ssh.path}
                                lib/*
                            
                        
                        
                            ssh-upload-run
                            package
                            
                                upload
                            
                            
                                ${ssh.run.skip}
                                target
                                ${ssh.path}
                                ${project.build.finalName}.jar
                            
                        
                        
                            ssh-exec
                            package
                            
                                sshexec
                            
                            
                                ${ssh.exec.skip}
                                true
                                
                                    mv ${ssh.path}/${project.build.finalName}.jar ${ssh.path}/run.jar
                                
                            
                        
                    
                

你可能感兴趣的:(maven)