Skip to content
Snippets Groups Projects
Commit 288bf3e3 authored by Alejandro Lopez Gestoso's avatar Alejandro Lopez Gestoso
Browse files

Updated documentation

parent 1d45d840
No related branches found
No related tags found
No related merge requests found
......@@ -14,8 +14,8 @@ It also provides two [scripts](./scripts) that must be uploaded to the apt serve
This script will be called from the gitlab CI jobs *update_repo_tag* and *update_repo_rdep*. It must be located at ~/repo_scripts folder in the package server. It will be executed in the package server.
It has two arguments:
- The first argument is the name of the .deb file to be uploaded. Usually iri-<package_name>-dev.
- The second is the Ubuntu distribution.
- The first argument is the name of the .deb file to be uploaded. Usually iri-<package_name>-dev.
- The second is the Ubuntu distribution.
It tries to upload the .deb file for 10 times each 5 seconds. On success, it shows the list of packages on the server and deletes the .deb file.
......@@ -24,4 +24,85 @@ It tries to upload the .deb file for 10 times each 5 seconds. On success, it sho
This script will be called from the gitlab CI job *modify_rdepends_ci*. It must be located at ~/repo_scripts folder in the package server. It will be executed in the docker.
It has one argument:
- The target package name
- The target package name.
Using apt-cache command, It will get the reverse dependencies of the target package and, for each dependency, it will get its gitlab path, last version and dependencies to generate a gitlab CI yml file. This file will be located at folder .rdepends_ci/ with name rdepends_ci.yml. This file will have a dummy job (just to launch a dummy job when a package doesn't have any reverse dependency and not modify the pipeline) and a job for each reverse dependency. The template of this job is the following one:
```yaml
iri-<package_name>-dev:
stage: rdepends
variables:
FROM_RDEPENDS_CI: "true"
TAG_VERSION: "<last_version>+1"
trigger:
strategy: depend
project: <gitlab_project_path>
branch: "<last_version>"
needs: [iri-<dependency_name>-dev]
```
## Packaging CI
The packaging CI pipeline is defined in packaging-ci.yml. That pipeline is composed by the following jobs:
- **Build_package_tag**: Job that reads the package dependencies from variable *CPACK_DEBIAN_PACKAGE_DEPENDS* from *CMakeLists.txt* file. It generates the package .deb file.
- Stage: build.
- Condition: The commit is a version tag (x.y.z) and the user is not the rdepends token.
- Artifacts: The package .deb file.
- Needs: No one.
- **Update_repo_tag**: Job that tries to upload the package .deb file. It calls update_repo script.
- Stage: update_package.
- Condition: The commit is a version tag (x.y.z) and the user is not the rdepends token.
- Artifacts: No one.
- Needs: No one.
- **modify_rdepends_ci**: Job that creates a new branch update_rdepends, generates *.rdepends_ci/rdepends_ci.yml* file and pushes it. It gets the package gitlab url information from *CPACK_DEBIAN_PACKAGE_HOMEPAGE*. It calls reverse_dependency script.
- Stage: update_reverse_dependencies.
- Condition: The commit is a version tag (x.y.z) and the user is not the rdepends token.
- Artifacts: No one.
- Needs: No one.
- **cleanup_branch_on_failure2**: Job that removes update_rdepends branch.
- Stage: update_reverse_dependencies.
- Condition: The commit is a version tag (x.y.z) and the user is not the rdepends token. In case of failure.
- Artifacts: No one.
- Needs: modify_rdepends_ci.
- **trigger_rdepends_ci**: Job that triggers *.rdepends_ci/rdepends_ci.yml*.
- Stage: update_reverse_dependencies.
- Condition: The commit is in branch update_rdepends.
- Artifacts: No one.
- Needs: No one.
- **cleanup_branch**: Job that removes update_rdepends branch.
- Stage: update_reverse_dependencies.
- Condition: The commit is in branch update_rdepends.
- Artifacts: No one.
- Needs: trigger_rdepends_ci.
- **cleanup_branch_on_failure**: Job that removes update_rdepends branch.
- Stage: update_reverse_dependencies.
- Condition: The commit is in branch update_rdepends. In case of failure.
- Artifacts: No one.
- Needs: trigger_rdepends_ci.
- **generate_new_tag**: Job that generates the new tag. It gets the package gitlab url information from *CPACK_DEBIAN_PACKAGE_HOMEPAGE*.
- Stage: update_reverse_dependencies.
- Condition: If variable *FROM_RDEPENDS_CI* is set to true.
- Artifacts: No one.
- Needs: No one.
- **build_package_rdep**: Job that reads the package dependencies from variable *CPACK_DEBIAN_PACKAGE_DEPENDS* from *CMakeLists.txt* file. It generates the package .deb file.
- Stage: update_reverse_dependencies.
- Condition: If variable *FROM_RDEPENDS_CI* is set to true.
- Artifacts: The package .deb file.
- Needs: generate_new_tag.
- **update_repo_rdep**: Job that tries to upload the package .deb file. It calls update_repo script.
- Stage: update_reverse_dependencies.
- Condition: If variable *FROM_RDEPENDS_CI* is set to true.
- Artifacts: No one.
- Needs: build_package_rdep.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment