|
1 | 1 | # opensciserver |
2 | | -OpenSciServer single repo |
| 2 | + |
| 3 | +This repo will contain all sciserver components such that they can be built and |
| 4 | +vended as a single-versioned unit. This repo is currently incomplete. |
| 5 | + |
| 6 | +## Installation |
| 7 | + |
| 8 | +Prerequisites: |
| 9 | +* A kubernetes cluster with an ingress controller |
| 10 | +* helm installed |
| 11 | +* This repository checked out (until we can vend the built helm charts to an |
| 12 | + appropriate stable web location) |
| 13 | + |
| 14 | +Mainline commits, pull-requests and tagged versions have built artifacts |
| 15 | +available on the github container registry with tags matching the version. to |
| 16 | +install we need to build the helm chart reference the appropriate repo location |
| 17 | +and version of built images: |
| 18 | + |
| 19 | +```sh |
| 20 | +# within this repo |
| 21 | +make helm REPO=ghcr.io/sciserver/opensciserver VTAG=main |
| 22 | +``` |
| 23 | + |
| 24 | +The above will build the helm chart where images are located in the official |
| 25 | +github container registry for opensciserver and we want those built from the |
| 26 | +latest commit to main. This will place the zipped chart under |
| 27 | +`helm/build/sciserver-{VTAG}.tar.gz`, which can be directly specified to helm as |
| 28 | +the chart source (see below). To reference a pull request, simply replace `VTAG` |
| 29 | +as appropriate (`pr-` plus the pull request number): |
| 30 | + |
| 31 | +```sh |
| 32 | +make helm REPO=ghcr.io/sciserver/opensciserver VTAG=pr-6 |
| 33 | +``` |
| 34 | + |
| 35 | +Once the charts are built, we can install using helm. For a development |
| 36 | +installation with no pre-existing requirements and no persistent data, we can |
| 37 | +use options as below: |
| 38 | + |
| 39 | +```sh |
| 40 | +helm -n sciserver \ |
| 41 | + upgrade --install \ |
| 42 | + --set prefix={name} \ |
| 43 | + --set baseDomain={domain-name} \ |
| 44 | + --set logging.api.image.tag=x --set backup.enable=false \ |
| 45 | + --set web.replicaCount=0 --set graphql.replicaCount=0 \ |
| 46 | + --set rendersvc.replicaCount=0 --set logging.api.replicaCount=0 \ |
| 47 | + --set proxy.cidrWhiteList=0.0.0.0/0 \ |
| 48 | + --set dev.nopvc=true \ |
| 49 | + -f helm/sciserver/password-manifest.yaml \ |
| 50 | + {name} helm/build/sciserver-main.tar.gz \ |
| 51 | +``` |
| 52 | + |
| 53 | +Some options above (such as the logging api image tag and the 0 replica count |
| 54 | +specs) are there due to incompleteness of this repo, or needs fixing. |
| 55 | + |
| 56 | +## Building |
| 57 | + |
| 58 | +We coordinate the multi-component builds with a make file at root, which |
| 59 | +contains commands for building individual components and the system as a whole. |
| 60 | +The github ci action demonstrates what is needed to make a complete build and |
| 61 | +upload artifacts, briefly: |
| 62 | + |
| 63 | +```sh |
| 64 | +# make the java components |
| 65 | +make java |
| 66 | + |
| 67 | +# make all images and their dependencies. The default naming scheme is |
| 68 | +# sciserver/component:version where the version is related to the git commit at |
| 69 | +# HEAD. |
| 70 | +make images |
| 71 | +# explicitly set a tag |
| 72 | +make images VTAG={tag} |
| 73 | + |
| 74 | +# make documentation |
| 75 | +make docs |
| 76 | +``` |
| 77 | + |
| 78 | +And so on. |
| 79 | + |
0 commit comments