Hi Shawn, On 08/28/2018 12:22 AM, Shawn McKinney wrote: > Howdy, > > A couple of issues running fortress builds in jenkins on docker images. The > openldap one is topic of this post. > > Specifically, the problem with how the docker script runs: > > excerpt from: > https://github.com/apache/directory-fortress-core/blob/master/src/docker/openldap-for-apache-fortress-tests/run-tests.sh > > > # configure build.properties > cp build.properties.example build.properties > > # We workaround incorrect starting values by updating existing configs: > sed -i 's/^ldap\.server\.type=.*/ldap.server.type=openldap/' build.properties > sed -i 's/^ldap\.host=.*/ldap.host=localhost/' build.properties > sed -i 's/^ldap\.port=.*/ldap.port='${CONTAINER_PORT}'/' build.properties > sed -i 's/^suffix\.name=.*/suffix.name=example/' build.properties > sed -i 's/^suffix\.dc=.*/suffix.dc=com/' build.properties > sed -i 's/^root\.dn=.*/root.dn=cn=Manager,${suffix}/' build.properties > sed -i 's/^root\.pw=.*/root.pw={SSHA}pSOV2TpCxj2NMACijkcMko4fGrFopctU/' > build.properties > sed -i 's/^cfg\.root\.pw=.*/cfg.root.pw=secret/‘ build.properties > > This is all worked until a month or so ago, when I started refactoring the > properties files, making sure that apacheds specific params were in > build.properties, and openldap specific params in slapd.properties. > > Now, the new problem, a few more properties need to be added, that aren’t in > the build.properties.example, used as the starting point. > > I tried updating the run-tests.sh (docker) script by appending the necessary > props to the end of the build.properties file: > > # a few more directives to seed additional properties: > echo "" >> build.properties > echo "log.admin.user=cn=Manager,cn=log" >> build.properties > echo "log.admin.pw=secret" >> build.properties > echo "min.log.conn=1" >> build.properties > echo "max.log.conn=3" >> build.properties > echo "audits.dn=cn=log" >> build.properties > > From what I can tell, this hasn’t had any effect but I’ll admit to being > ignorant how the jenkins tests bootstrap the docker images. Does it call the > run-tests.sh script, or is there another script somewhere, that must be > changed?
Please have a look into the Jenkin job configuration: https://builds.apache.org/view/D/view/Directory/job/dir-fortress-core-docker-openldap-test/configure It doesn't use the run-tests.sh script at all. All the instructions are duplicated there. I guess I did that, not a nice move, but I don't remember why... Probably the easiest change is to use that script in Jenkins, I'll try.. Btw, when you run the script locally does it succeed? > The best solution would be to change the docker script to use the > slapd.properties.example as the base, which then would reduce the number of > updates that have to be done using sed or echo commands. Sure, just replace the properties file name in the script > Anyway, apologize for the lengthy post. I’ll keep poking around and let > y’all know what I find out. No, all fine, I have to apologize for not looking into the issue earlier...
