deprecated: This information is now in https://github.com/crosscloudci/crosscloudci/blob/master/CNCFCI_GITLAB_CONFIGURATION.md
The goal is to call the new project's ci scripts from gitlabs ci configuration file
- Make crosscloudci/-configuration project -- copy an existing -configuration project (see testproj-configuration: https://github.com/crosscloudci/testproj-configuration/blob/master/cncfci.yml which is for the testproj example: https://github.com/crosscloudci/testproj)
- Edit .gitlab-ci.yml to include curl commands and scripts for getting build status, deploys, and tests e.g. envoy-configuration (see https://github.com/crosscloudci/testproj-configuration/blob/master/.gitlab-ci.yml)
- Optional: write a ci proxy plugin for your ci tool and submit a pull request (see https://github.com/crosscloudci/ex_ci_proxy/blob/master/README.md)
You need to have admin permissions to do this
In Gitlab you need to complete the following steps.
- Create a new group
- Create a new project
- Set up mirroring (steps and menu items in gitlab)
- Botuser needs to be in user permissions
- Add member
- master
- Impersonate bot user
- Admin
- Search for bot, click on bot user
- Impersonate
- Admin
- Settings
- Repository
- Pull from remote repository
- Select mirror, add https repo address, select bot user
- Repository
- Project
- Should see that the code is pulled down
- Stop impersonating
- Botuser needs to be in user permissions
- Set up project variables (steps and menu items in gitlab)
- Settings
- Pipeline trigger
- add trigger
- copy token
- put in environment.rb
- Pipelines
- Custom ci config path
- e.g. https://raw.githubusercontent.com/crosscloudci/envoy-configuration/master/.gitlab-ci.yml
- Add cloud variable
- CLOUD
- e.g. aws
- ARCH
- GEMFURY
- TOKEN
- token from earlier pipeline trigger step
- Settings
- Enable runners (steps and menu items in gitlab)
- Admin
- Runners
- Select token
- Select envoy
- Select token
- Runners
- Admin
- Add to dashboard yml (steps and menu items in gitlab)
- Cncf configuration
- Integration branch
- Add to cross-cloud.yml
- Duplicate a project
- Find logo image e.g. https://d33wubrfki0l68.cloudfront.net/77bb2db951dc11d54851e79e0ca09e3a02b276fa/9c0b7/img/envoy-logo.svg
- Add to cncf artwork repo
- Link to cross cloud artwork repo
- Update the project names e.g. to envoy
- Charts are the repo that we get the helm charts from
- Change timeout for how long your build takes
- Integration branch
- Cncf configuration
- Review pipelines
- Pipelines
- manually add new to the url (this is a workaround)
- Select master
- Select stable (e.g. v1.7.0)
- Both should be running
- Pipelines
- add the new project into the enviroment.rb
- Clone the project
git clone yourprojectname
- e.g. git clone https://github.com/envoyproxy/envoy.git
- Make a note of any ci instructions including scripts for building and publishing images
- e.g. the .circleci/config.yml file outlines lots of shell scripts that refer to a docker dependencies image and build image
- Replicate the builds
- e.g. use docker to replicate a build image using the previously viewed ci
- you probably want to pin your image
- update the script not to push
- images will be local after build
- publish to gitlab directory
-
Create a script that builds head
-
Create a script that builds stable
- Add a sleep to the .gitlab-ci.yml script
- ssh [email protected]
- Click on compile job
- If .gitlab-ci.yml does not refresh:
- Go to pipelines
- Copy/cut the gitlab.yml and save an empty url
- Paste the url in again and save it