We have a Liferay7 project and need to deploy project to remote server by jenkins. I did the following items:
Jenkins installed
Checkout from git repository
Build with Gradle 3.0
After that i need to deploy jar files to X.X.X.X server. What is the best practices for that? Should i deploy project with Ant or Gradle?
Related
Hi have requirement to Continous deployment using Jenkins and below are the steps to achieve.
1.Jenkins job download the artifact from Nexus and place it in a remote server
2.Unzip the artifact present in the remote server.
3.Perform Gradle task in remote server
You could try using Ansible maybe https://docs.ansible.com/ansible/latest/modules/copy_module.html
If it is Windows:
https://docs.ansible.com/ansible/latest/modules/win_unzip_module.html
You have modules for every situation:
https://docs.ansible.com/ansible/latest/modules/modules_by_category.html
You could do it with Jenkins, scripting the code, and probably storing the login in the Jenkins credentials.
I am trying to implement the CI/CD pipeline using Jenkins , docker and ansible in my AWS EC2 machine. I am panning to create a declarative pipeline for building all my CI/CD pipeline stages. And I am using one SVN private repository in my on-premise server.
When I am using svn chekcout command in checkout stage , to where the SVN project is chekouting? Where is the physical location of SVN project in my EC2 ?
Your pipeline will checkout your repo in the job’s workspace directory. Check the below location on the node where you are executing your pipeline.
JENKINS_HOME/workspace/{pipeline}
How can I use maven in an 'undeploy' fashion to remove an artefact deployed to the nexus staging repo?
I currently execute the a command like below for deployment:
deploy:deploy-file -Durl=${bamboo.ArtefactsNexusUrl} -DrepositoryId=${bamboo.nexusRepoId} -DgroupId=${bamboo.GroupId} -DartifactId=${bamboo.ArtefactName} -Dversion=${bamboo.inject.VERSION} -Dfile=${bamboo.ArtefactName}-${bamboo.inject.VERSION}.${bamboo.ArtefactExtension} -Dpackaging=${bamboo.ArtefactExtension}
You can drop the whole staging repository with the Nexus Staging Maven Plugin or via the Nexus user interface. Check out the documentation in the book.
I am trying to automate deployment proceeses using Jenkins. I am trying to deploy some config files and some EAR files to remote VM. Normally I would open a Remote Desktop connection and deploy manually.
Is there a way FROM JENKINS through scripting or plugin where I can deploy files to a remote VM?
You can use this framework which automates the management and deployment of files on remote VM's running in a VMWare environment.
Just install RI on your Jenkins server and add batch steps to execute the RI executable with a XML configuration that should do what you want.
Jenkins is running in a windows machine.
Slave is a mac building iPhone apps. (using ssh)
This configuration building successfully.
If I archive the artifact (e.g. Output/.) it saves in the master (windows machine).
But when I try to run any bat command to copy files in the post build steps, it runs in the slave machine.
How can I run command in the master (Windows), in the post build steps? Or there is other ways to do it?
I want to upload the build artifact to a server accessible only from the windows (master) machine. How can I do that?
How to tell Jenkins, to take the build artifacts from the slave and run some command (copy files) on those files in the master.
Use the Publish Over FTP Plugin. Create an ftp in master and using Publish Over FTP Plugin, copy the build artifacts to master machine.
Thanks,
Manu