Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add jenkinsfile and openshift template #3380

Merged
merged 1 commit into from
Dec 21, 2016
Merged

Conversation

csrwng
Copy link

@csrwng csrwng commented Dec 13, 2016

This PR creates a Jenkinsfile at the root of the docs repository. This enables the Jenkins GitHub Organization plugin to automatically instantiate a pipeline for this repository and run builds on PRs.

It also adds an OpenShift template that can be used to build and run the doc repository for a given GIT_URI and GIT_REF.

@csrwng
Copy link
Author

csrwng commented Dec 13, 2016

@bparees ptal

The s2i builder repo can be found here:
https://github.com/csrwng/openshift-docs-s2i

@bparees
Copy link
Contributor

bparees commented Dec 14, 2016

lgtm. @openshift/team-documentation we're trying to add some PR automation logic to build/preview docs PRs using the new openshift ci cluster, who do we need to talk to about getting this reviewed/merged?

@vikram-redhat
Copy link
Contributor

@bparees - best to liaise with @nhr for this but please keep me and @adellape in the loop as well.

@nhr
Copy link
Member

nhr commented Dec 14, 2016

I think I understand the goal but it would still be good to have a conversation about it. Also, I am a little confused because at no point in the Jenkinsfile is there any mention of AsciiBinder, which would be the tool to use for invoking a docs build...

@bparees
Copy link
Contributor

bparees commented Dec 14, 2016

that's in the s2i builder image @csrwng created: https://github.com/csrwng/openshift-docs-s2i/blob/master/s2i/bin/assemble#L11

the jenkinsfile isn't doing the docs build directly, it's invoking an s2i build.

@csrwng
Copy link
Author

csrwng commented Dec 14, 2016

Updated to have preview details go to index.html

@nhr
Copy link
Member

nhr commented Dec 14, 2016

Understood, thanks for clarifying. In talking w/ @csrwng I noted a change that needs to be made to the builder image (add a JRE to support DITAA image generation) but this PR looks good.

@vikram-redhat and @adellape - from your perspective, this work creates an automatic test pass, similar to what happens with Travis, on an OpenShift cluster for new docs PRs. From GitHub you will be able to follow a link to the URL where the PR changes have been applied to the docs (this is a master-branch-only build of the docs repo for each distro). The test will not "pass" until you have approved the changes in Jenkins. Approval == clicking a button that says "this looks right". Note, however, that even if you don't approve the test through Jenkins you can still merge the PR, so this augments the PR approval workflow by automating a test build of the changes, but doesn't require you to approve the new instance in order to merge the change.

@csrwng
Copy link
Author

csrwng commented Dec 14, 2016

The s2i builder has been updated with a JRE and is now generating ditaa diagrams.

@nhr
Copy link
Member

nhr commented Dec 14, 2016

Once we get an ACK from @vikram-redhat or @adellape we can merge this.

@adellape
Copy link
Contributor

👍 I like this.

@vikram-redhat
Copy link
Contributor

Thanks @nhr and @csrwng @bparees . @adellape and I discussed this today.

IIUC, this will add an extra step to the docs team's process for merging, verifying and following up of PRs. However, we do see the benefit of it by allowing us to make sure, especially for larger changes, that the books build ok and the changes haven't broken anything.

I guess we won't know till we try it and if it becomes bothersome, we can revert it.

@aheslin - FYI.

@csrwng
Copy link
Author

csrwng commented Dec 14, 2016

Just fyi ... this is only the first step in enabling this flow. We still need to set up the ci server to listen on PRs and do the builds.

@stevekuznetsov fyi

@bparees
Copy link
Contributor

bparees commented Dec 14, 2016

IIUC, this will add an extra step to the docs team's process for merging, verifying and following up of PRs.

to be clear, you can do whatever you want with it. you're more than welcome to ignore the additional messages that will appear in the PR, we just wanted to

  1. provide PR contributors and reviewers with an easy way to view the rendered content without having to clone+build the change themselves
  2. do some dogfooding around openshift pipelines.

@stevekuznetsov
Copy link

Just fyi ... this is only the first step in enabling this flow. We still need to set up the ci server to listen on PRs and do the builds.

Do you want me to take that work on, or do you have bandwidth? I can give you a project on the cluster.

@csrwng
Copy link
Author

csrwng commented Dec 15, 2016 via email

@csrwng
Copy link
Author

csrwng commented Dec 15, 2016

Per @stevekuznetsov - Added a timeout for approval (2 days)
Per @bparees - Updated to use more generic asciibinder builder - (still need to have one pushed to the openshift namespace on dockerhub).

@csrwng
Copy link
Author

csrwng commented Dec 21, 2016

@nhr is this ready for merge?

@nhr
Copy link
Member

nhr commented Dec 21, 2016

Indeed it is!

@nhr nhr merged commit b29b93a into openshift:master Dec 21, 2016
@csrwng csrwng deleted the add-jenkinsfile branch January 19, 2017 16:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants