Commit c134b09c authored by Thomas Boni's avatar Thomas Boni
Browse files

Merge branch '33-remove-named-references-between-jobs' into 'latest'

Resolve "Remove named references between jobs"

Closes #33

See merge request go2scale/hub!13
parents 97e0a64d 0400ed50
Loading
Loading
Loading
Loading
+4 −5
Original line number Diff line number Diff line
# g2s hub
# Go2Scale hub

## Description

**g2s hub** is a collaborative hub of CI & CD
ready to use jobs which helps you to quickly build powerful pipelines for your
projects.
**Go2Scale hub** is a collaborative hub of CI & CD ready to use jobs which
helps you to quickly build powerful pipelines for your projects.

Each jobs of the hub can be used unitary or to create fully customs pipelines.
You can use them for any kind of software and deployment type. Each job can be
customized through configuration.

Check the [documentation](https://hub.go2scale.io).
Check the [documentation](https://hub.go2scale.io) 📚

## How to update the documentation

+15 −4
Original line number Diff line number Diff line
@@ -25,7 +25,7 @@ code using [apiDoc](https://www.apidocjs.com/).

## Job details

* Job name: `documentation`
* Job name: `apidoc`
* Docker image:
[`node`](https://hub.docker.com/r/_/node)
* Default stage: `build`
@@ -37,7 +37,7 @@ code using [apiDoc](https://www.apidocjs.com/).
| ---- | ----------- | ------- |
| `APIDOC_VERSION` | Version of apiDoc to use | `0.24.0` |
| `APIDOC_CONFIG_PATH` | Path to config file or to directory containing config file (apidoc.json or apidoc.config.js) | `.` |
| `APIDOC_OUTPUT_PATH` | Output directory path | `/apidoc_build` |
| `APIDOC_OUTPUT_PATH` | Output directory path | `/documentation_build` |
| `APIDOC_TEMPLATE_PATH` | Path to template folder | `/usr/lib/node_modules/apidoc/template/` |

### Artifacts
@@ -46,9 +46,20 @@ Result of documentation build is [exposed
as](https://docs.gitlab.com/ee/ci/yaml/#artifactsexpose_as) `apiDoc build` in
merge requests.

!!! warning
    Exposition of artifact doesn't work currently because of [this issue from
    Gitlab](https://gitlab.com/gitlab-org/gitlab/-/issues/37129). As soon as
    the issue will be fixed, exposed artifacts will be available in merge
    requests.

## Versions

* **Latest** (current -> `2020-08-07_1`) : `https://jobs.go2scale.io/latest/apidoc.yml`
* **Latest** (current -> `2020-08-09_1`) : `https://jobs.go2scale.io/latest/apidoc.yml`
* **Tag `2020-08-09_1`** : `https://jobs.go2scale.io/2020-08-09_1/apidoc.yml`
    * Rename the job from `documentation` to `apidoc`
    * Update the default output folder to `/documentation_build` in order to
      ensure plug and play compatibility with [pages](/jobs/deployment/pages)
      deployment job. **Note**: output folder can be customized using
      `APIDOC_OUTPUT_PATH` [variable](#variables)
* **Tag `2020-08-07_1`** : `https://jobs.go2scale.io/2020-08-07_1/apidoc.yml`

    * Initial version
+20 −2
Original line number Diff line number Diff line
@@ -33,21 +33,39 @@ Mkdocs](https://squidfunk.github.io/mkdocs-material/) are ready to use.

## Job details

* Job name: `documentation`
* Job name: `mkdocs`
* Docker image:
[`squidfunk/mkdocs-material`](https://hub.docker.com/r/squidfunk/mkdocs-material)
* Default stage: `build`
* When: `always`

### Variables

| Name | Description | Default |
| ---- | ----------- | ------- |
| `MKDOCS_OUTPUT_PATH` | Output directory path | `/ documentation_build` |

### Artifacts

Result of documentation build is [exposed
as](https://docs.gitlab.com/ee/ci/yaml/#artifactsexpose_as) `Documentation` in
merge requests

!!! warning
    Exposition of artifact doesn't work currently because of [this issue from
    Gitlab](https://gitlab.com/gitlab-org/gitlab/-/issues/37129). As soon as
    the issue will be fixed, exposed artifacts will be available in merge
    requests.

## Versions

* **Latest** (current -> `2020-08-05_1`) : `https://jobs.go2scale.io/latest/mkdocs.yml`
* **Latest** (current -> `2020-08-09_1`) : `https://jobs.go2scale.io/latest/mkdocs.yml`
* **Tag `2020-08-09_1`** : `https://jobs.go2scale.io/2020-08-09_1/mkdocs.yml`
    * Rename the job from `documentation` to `mkdocs`
    * Update the default output folder to `/documentation_build` in order to
      ensure plug and play compatibility with [pages](/jobs/deployment/pages)
      deployment job. **Note**: output folder can be customized using
      `MKDOCS_OUTPUT_PATH` [variable](#variables)
* **Tag `2020-08-05_1`** : `https://jobs.go2scale.io/2020-08-05_1/mkdocs.yml`

    !!! warning
+17 −6
Original line number Diff line number Diff line
@@ -8,8 +8,16 @@ from previous job named `documentation`.
## How to use it

!!! note "Requirements"
    * Use a `documentation` job in build 📦 stage to be able to retrieve the
      documentation to publish as artifact. Example: [Mkdocs](/jobs/mkdocs/)

    You have to use a job which build your documentation in a previous stage.
    We recommend you to use a documentation job available on the HUB in [build
    📦 stage](/jobs/#build). They build documentation and publish it as
    artifact in `documentation_build/` folder.

    **Documentation jobs list:**

    * [ApiDoc](/jobs/build/apidoc/)
    * [Mkdocs](/jobs/build/mkdocs/)

1. Choose a version in [version list](#versions)
3. Add the corresponding URL to your `.gitlab-ci.yml` file (see [Getting
@@ -22,7 +30,6 @@ from previous job named `documentation`.

4. If you need to customize the job (stage, variables, ...) 👉 check the [jobs
   customization](/getting-started/#jobs-customization)

5. Well done, your job is ready to work ! 😀


@@ -35,11 +42,15 @@ from previous job named `documentation`.

| Name | Description | Default |
| ---- | ----------- | ------- |
| `PAGES_BUILD_PATH` | Path to folder which contains documentation build | |
| `PAGES_BUILD_PATH` | Path to folder which contains documentation build | `documentation_build/` |

## Versions

* **Latest** (current -> `2020-08-05_1`): `https://jobs.go2scale.io/latest/pages.yml`
* **Latest** (current -> `2020-08-09_1`): `https://jobs.go2scale.io/latest/pages.yml`
* **Tag `2020-08-09_1`** : `https://jobs.go2scale.io/2020-08-09_1/pages.yml`
    * Add possibility to retrieve build artifact from any job in previous stage
    * Add variable `PAGES_BUILD_PATH` to indicate the location of build to
      deploy
    * Return error case when there is nothing to deploy
* **Tag `2020-08-05_1`** : `https://jobs.go2scale.io/2020-08-05_1/pages.yml`

    * Initial version
+2 −2
Original line number Diff line number Diff line
# Job from go2scale hub --> hub.go2scale.io

documentation:
apidoc:
  image:
    name: node:12.18.3-alpine3.12
    entrypoint: [""]
  stage: build
  variables:
    APIDOC_CONFIG_PATH: '.'
    APIDOC_OUTPUT_PATH: 'apidoc_build/'
    APIDOC_OUTPUT_PATH: 'documentation_build/'
    APIDOC_TEMPLATE_PATH: '/usr/local/lib/node_modules/apidoc/template/'
    APIDOC_VERSION: '0.24.0'
  script:
Loading