New repository settings

All repositories in kyma-project and kyma-incubator organizations should be similar in structure, settings, and restrictions. Follow these guidelines to adjust settings of a new repository created in one of these organizations.

NOTE: You have to be an owner of the given organization to create a new repository in it.

Use the repository template

Whenever you create a new repository, use the template from the template-repository. This template contains all necessary configuration files for CODEOWNERS, Kyma stale bot, issue and pull request templates, license, and Code of Conduct.

NOTE: Do not mark the Include all branches checkbox as it will clone all branches from the template-repository to your new repo.

Template

Adjust repository options

Under the repository name, choose the Settings tab. The Options view opens as the default one in the left menu.

  1. Scroll down to the Features section and clear these options:
  • Wikis
  • Restrict editing to users in teams with push access only
  • Projects

Features

Set branch protection rules

Define branch protection rules that include enforcing obligatory review and approval of pull requests (PRs), and define which Prow jobs need to pass successfully before merging PR changes into the main branch.

To see these settings, go to Branches in the left menu, under repository Settings:

Branch protection rules

In Kyma, the protection rules are defined in the Prow config.yaml file generated from rules defined in the prow-config.yaml file and handled by a Prow component called Branch Protector.

If you add a new repository in:

  • kyma-project, you do not need to add a new entry to the Prow config.yaml file as the branch protection is already defined for all repositories within this organization. The only exception is if you want to specify additional rules that are not handled by Prow.
  • kyma-incubator, add a new repository entry to the Prow config.yaml file, under branch-protection.orgs.kyma-incubator.repos. See an example of such an entry for the marketplaces repository.

Update CLA assistant configuration

Ask a kyma-project owner to:

Add a milv file

If you define any governance-related Prow job for the new repository to validate documentation links, you must add a milv.config.yaml file at the root of the repository. See an example of the milv file.

Custom settings

Track all repository changes that deviate from configuration standard described in the guidelines with an issue.