grouper-users - Re: [grouper-users] git commands for building docker image
Subject: Grouper Users - Open Discussion List
List archive
- From: Michael Porter <>
- To: "Redman, Chad" <>
- Cc: Cisco ROS <>
- Subject: Re: [grouper-users] git commands for building docker image
- Date: Mon, 21 Sep 2020 11:07:46 -0400
Hi Chad,
Mike Porter
Thanks for the info. As we get more into Grouper, I guess we'll need to look into this deeper. I want to deploy on docker if at all possible, and I certainly want to be able to patch as I see fit.
The build process currently fails, but I don't know enough about what I am doing, so I will not put in a report yet. Looks like something in the dependencies processing is getting messed up. We are stuck behind private IP address space, so could just be a simple proxy issue. Lots of places to configure a proxy to make everything work!
Thanks,
Mike
(302) 831-3747
On Fri, Sep 18, 2020 at 12:38 AM Redman, Chad <> wrote:
The original message didn't get to my inbox, so I'm copy/pasting it from the web archive.
You should consider these as two independent projects. The Grouper build and the Docker image build aren't normally merged into a single project. The code bases are orthogonal to each other, plus they have different tags and branch names which will make it difficult to get the right branches in both projects at the same time.
If you build Grouper as it exists in the repository, it will be a "2.5.0-SNAPSHOT" version. When a release is ready, a Jenkins job will replace the version number in the pom.xml files on the fly, and then publish the packaged jars to Maven repositories. So the Grouper version that the Docker build depends on doesn't even really exist, except as a tag on a specific commit. Anyway, here is what is involved in building both projects.
Grouper:
git clone https://github.com/Internet2/grouper.gitgit checkout GROUPER_2_5_BRANCH(this should automatically associate with the remote branch; i.e. "Branch 'GROUPER_2_5_BRANCH' set up to track remote branch 'GROUPER_2_5_BRANCH' from 'origin'.")
cd groupermvn -f grouper-parent clean install(this will build version 2.5.0-SNAPSHOT of all the relevant jar files; the result of the install phase will copy the jars into your .m2 cache directory, but the implied package step will also put them into */target subdirectories)
Docker
cd ..git clone https://github.internet2.edu/docker/grouper.git grouper-container
cd grouper-containergit checkout 2.5.35(this should automatically associate with the remote branch; i.e. "Branch '2.5.35' set up to track remote branch '2.5.35' from 'origin'.")
docker build --tag=my-grouper/grouper:latest .(will create a docker image my-grouper/grouper:latest)
Note that the docker build won't be using the Grouper jars you just built. It will pull the 2.5.35 versions from a Maven repository.
-Chad
---- Original Message ----Hi,
Anyone know how the series of git commands to pull grouper and docker/grouper together such that I can run maven to build the application and then docker build to make the image? I am having trouble getting the two repositories to work together.
Probably something simple. New to docker, new to git. However, I am uncomfortable running an image I do not know how to build. I'm a little surprised there is not an easily accessible document explaining this.
Right now I have:
git clone https://github.com/Internet2/grouper.git/
cd grouper
git remote add -f docker/grouper https://github.internet2.edu/docker/grouper.git
git merge docker/grouper/master --allow-unrelated-histories
There were some unmerged changes, so I did:
git add README.md
git add .gitignore
git commit
However, I now want to check out 2.5.33. Just checking out 2.5.33 pulls the files for docker/grouper and removes the application directores. Checking out GROUPER_2_5_BRANCH leaves me something kinda 2.5ish I guess. But the Dockerfile has a 2.4.0 version in it, so clearly I have not created something that makes grouper and docker/grouper work correctly.
Thanks,
MikeMike Porter
(302) 831-3747
- [grouper-users] git commands for building docker image, Michael Porter, 09/14/2020
- <Possible follow-up(s)>
- Re: [grouper-users] git commands for building docker image, Redman, Chad, 09/18/2020
- Re: [grouper-users] git commands for building docker image, Michael Porter, 09/21/2020
- Re: [grouper-users] git commands for building docker image, Redman, Chad, 09/23/2020
- Re: [grouper-users] git commands for building docker image, Michael Porter, 09/21/2020
Archive powered by MHonArc 2.6.19.