[FOLIO-2303] documentation for setting up deployment of feature branches Created: 08/Oct/19 Updated: 03/Jun/20 Resolved: 18/Oct/19 |
|
| Status: | Closed |
| Project: | FOLIO |
| Components: | None |
| Affects versions: | None |
| Fix versions: | None |
| Type: | New Feature | Priority: | P2 |
| Reporter: | Jakub Skoczen | Assignee: | Ian Hardy |
| Resolution: | Done | Votes: | 0 |
| Labels: | platform-backlog | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original estimate: | Not Specified | ||
| Issue links: |
|
||||||||
| Sprint: | CP: sprint 74 | ||||||||
| Story Points: | 2 | ||||||||
| Development Team: | Core: Platform | ||||||||
| Description |
|
Ian Hardy will provide more details.
The published document is at https://dev.folio.org/guides/branch-preview-kubernetes/ |
| Comments |
| Comment by Ian Hardy [ 16/Oct/19 ] |
|
Here's more or less the documentation on publishing backend preview artifacts. There's alittle re-wrting to be done yet on dev.folio.org to fit it in. Publishing backend preview artifactsIt may be desirable to create preview build that includes changes to backend modules that have not been merged into master. To achieve this, open a pull request on the backend module or modules with the publishPreview variable set to true in the main config, and in the docker configuration. A Jenkinsfile for a typical backend module might look like this: buildMvn {
publishModDescriptor = 'yes'
publishAPI = 'yes'
mvnDeploy = 'yes'
runLintRamlCop = 'yes'
publishPreview = 'yes'
doDocker = {
buildJavaDocker {
publishMaster = 'yes'
publishPreview = 'yes'
healthChk = 'yes'
healthChkCmd = 'curl -sS --fail -o /dev/null http://localhost:8081/apidocs/ || exit 1'
}
}
}
Making these changes will achieve the following: Including backend preview artifacts in a platformPreview builds are driven by pull requests against platform-core or platform-complete. To include a preview artifact, update the okapi-install.json file and replace the id of the module you would like to preview with the preview version. The preview version is the module’s regular version number, with the pr and build numbers appended (mod-name-version.pr.build.) For example: ...
{
"id": "mod-users-SNAPSHOT-15.6.1",
"action": "enable"
},...
should be replaced with: ...
{
"id": "mod-users-SNAPSHOT-15.6.1.11.2",
"action": "enable"
},...
Bear in mind that the module descriptor for this preview artifact is not published to the folio-registry, and is only available on okapi-preview.ci.folio.org. |
| Comment by Jakub Skoczen [ 16/Oct/19 ] |
|
Ian Hardy John Malconian Looks pretty good! To complete it we should also extend it with a section explaining how to add NPM branch "artefacts" to the platform-core (and to individual UI modules). I think John mentioned that the approach here is to point to the specific Git branch directly in the package.json and omit using the Nexus NPM repository altogether. Is that the recommended approach? Do we need to confirm with the UI developers (e.g Zak Burke?). If so, John Malconian will you contribute this section or can Ian Hardy handle it? |
| Comment by Zak Burke [ 17/Oct/19 ] |
|
For UI modules, pointing directly to a GitHub branch of the module in the platform's package.json file sounds like the right approach to me. |
| Comment by Ian Hardy [ 18/Oct/19 ] |
|
Opened a PR for dev.folio.org with draft documentation for creating a k8s preview. This will need to be reviewed for accuracy when pr preview is enabled. There are notes on what is needed in the PR: https://github.com/folio-org/folio-org.github.io/pull/478 The generated document associated with that PR is available here. |
| Comment by David Crossley [ 29/Jan/20 ] |
|
Re-opened this because the documentation is not yet finalised. There are some notes above to be incorporated, and notes on the PR. There are some notes in private Slack. There might also be related notes arising from
|