Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

push package builded in Gitlab CI.Runner to Nexus repository

In Gitlab issue #19095 it's decided to leverage GL as package repository, but what should i do just now, until it's not done, for task: "try that Gitlab instead Jenkins+Nexus". From which place can I push package to Nexus?

  1. from gitlab-ci.yml
  2. using uploaded package from Runner using artifacts parameter gitlab-ci.yml https://about.gitlab.com/2015/11/22/gitlab-8-2-released/
  3. from Docker image using Maven may be
  4. via webhook
  5. using release tag?
like image 650
Riorita Avatar asked Aug 23 '16 10:08

Riorita


People also ask

What is the difference between Nexus and GitLab?

GitLab can be classified as a tool in the "Code Collaboration & Version Control" category, while Sonatype Nexus is grouped under "Java Build Tools". GitLab and Sonatype Nexus are both open source tools.

What is GitLab CI Multi runner?

GitLab Runner is the open source project that is used to run your CI/CD jobs and send the results back to GitLab.


1 Answers

The best answer I think you're going to find is that you need to write it into your gitlab yml script

NEXUS_USERNAME=admin 
NEXUS_PASSWORD=admin123 
NEXUS_SERVER=server.com/yourserver
NEXUS_REPOSITORY=raw 
echo "Sending backup to server"

curl -v -u ${NEXUS_USERNAME}:${NEXUS_PASSWORD} --upload-file ${UPLOAD_FILE} http://${NEXUS_SERVER}/repository/${NEXUS_REPOSITORY}/${UPLOAD_FILE}
like image 162
David Hunsicker Avatar answered Oct 25 '22 06:10

David Hunsicker