|
|
This Wiki holds documentation for the various Corelink server development.
|
|
|
|
|
|
|
|
|
## CI/CD
|
|
|

|
|
|
There are two stages in the current CI pipeline, `build` and `artifact`.
|
|
|
|
|
|
### Build Stage
|
|
|
|
|
|
#### Docker Image Build
|
|
|
We want to provide a docker image for corelink server. We use `kaniko` to build docker-indocker without exposing to the [privilege escalation issue](https://docs.gitlab.com/ee/ci/docker/using_docker_build.html#docker-in-docker-with-tls-enabled-in-the-docker-executor). The `server-docker` job triggers a child pipeline using the yaml file `.build.yml` which builds against the `DockerFile`.
|
|
|
|
|
|
### Artifact Stage
|
|
|
We host a simple zip file with all the files currently contained in the `dev` branch on `server-artifact` branch
|
|
|
|
|
|
|
|
|
### Deploy stage
|
|
|
In the `server-deploy` stage of the pipeline, the corelink server is deployed as npm package in the Gitlab Package Registry in the event of a tagged release. These are deployed at Project-level endpoints. As Group-level and instance-level endpoints are not supported for public access levels.
|
|
|
|
|
|
`Trigger` : Tagged Release
|
|
|
|
|
|
`Package` : npm package
|
|
|
`@corelinkhub/corelink-server`
|
|
|
|
|
|
To install the corelink server, add the following line to the .npmrc file:
|
|
|
|
|
|
<pre style="white-space: pre-wrap; overflow-x: auto;">
|
|
|
<code>
|
|
|
@corelinkhub:registry=https://dev.hsrn.nyu.edu/api/v4/projects/<project_id>/packages/npm/
|
|
|
registry=https://registry.npmjs.org/
|
|
|
</code>
|
|
|
</pre>
|
|
|
|
|
|
`project_id` : The project id of the corelink-server project in Gitlab.
|
|
|
|
|
|
Then to install the package, the following command can be used:
|
|
|
|
|
|
<pre style="white-space: pre-wrap; overflow-x: auto;">
|
|
|
<code>
|
|
|
npm install @corelinkhub/corelink-server
|
|
|
</code>
|
|
|
</pre>
|
|
|
|
|
|
|
|
|
|
|
|
# Next-Steps |
|
|
This Wiki holds documentation for the various Corelink server development. |
|
|
\ No newline at end of file |