A simple example storing several Git repositories in a Helix server along with Perforce content.
If running Windows there are a couple of extra steps that must be done before getting started on this. Firstly git must be configured to not automatically convert the line endings to Windows format when cloning the repositry. Secondly docker must also be set to automatically convert Windows paths. Within the coommand prompt this is being run within, run these commands:
git config --global core.autocrlf true
set COMPOSE_CONVERT_WINDOWS_PATHS=1
You will need docker
and docker-compose
to run this demo. You can get Docker here for Mac or Windows.
- Clone the demo:
git clone https://github.com/p4paul/jenkins-demo.git
- Change into the cloned directory:
cd jenkins-demo
- Bring up the instances:
docker-compose up
- Wait for the machines to start...
- Jenkins: http://localhost:3080
- Helix Swarm: http://localhost:5080 (admin:admin)
- Helix TeamHub: http://localhost:6080 (admin:admin)
- Helix Core: P4PORT=localhost:4000 (admin:admin)
Login to Jenkins with user 'admin', password 'admin'.
Git is running https on port 4443; for example, to clone use:
git -c http.sslVerify=false clone https://admin:admin@localhost:4443/plugins/p4-plugin
(the -c http.sslVerify=false
is needed as the demo does not use a Certificate)
Perforce is on port 4000 with user 'admin' and no password set. For example, to list repos use:
p4 -u admin -p localhost:4000 repos
This demonstrates how to uses a Stream to combine Git imported repositories and Helix
Streams in a single project. The project is based on the Jenkins p4-plugin
and
demonstrates how sync graph content and pin it to a tag.
Just build the Jenkins job graph-hybrid-demo
.
This demonstrates how to trigger a Jenkins Job containing git content synced from a
Helis graph. The Jenkins job docker-trigger-demo
is pre-configured, however you will
need to push git content into Perforce and run an initial build.
- Clone the docker plugin to a local directory
git clone https://github.com/jenkinsci/docker-plugin.git
- Change directory
cd docker-plugin
- Add remote
git remote add helix https://localhost:4443/plugins/docker-plugin.git
- Push repo
git push -u helix master
- Build Jenkins job
docker-trigger-demo
(this should pass) - Trigger Jenkins job by make a change to the local git repo, commit and push.