Skip to content

Commit 8758af9

Browse files
Sync .github dir templates
1 parent ed87f49 commit 8758af9

File tree

6 files changed

+200
-40
lines changed

6 files changed

+200
-40
lines changed

.github/CONTRIBUTING.md

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
Contributor License Agreement
2+
---------------
3+
4+
Follow these steps to make a contribution to any of our open source repositories:
5+
6+
1. Ensure that you have completed our CLA Agreement for [individuals](https://www.cloudfoundry.org/wp-content/uploads/2015/07/CFF_Individual_CLA.pdf) or [corporations](https://www.cloudfoundry.org/wp-content/uploads/2015/07/CFF_Corporate_CLA.pdf).
7+
8+
1. Set your name and email (these should match the information on your submitted CLA)
9+
```
10+
git config --global user.name "Firstname Lastname"
11+
git config --global user.email "[email protected]"
12+
```
13+
14+
1. All contributions must be sent using GitHub pull requests as they create a nice audit trail and structured approach.
15+
16+
The originating github user has to either have a github id on-file with the list of approved users that have signed
17+
the CLA or they can be a public "member" of a GitHub organization for a group that has signed the corporate CLA.
18+
This enables the corporations to manage their users themselves instead of having to tell us when someone joins/leaves an organization. By removing a user from an organization's GitHub account, their new contributions are no longer approved because they are no longer covered under a CLA.
19+
20+
If a contribution is deemed to be covered by an existing CLA, then it is analyzed for engineering quality and product
21+
fit before merging it.
22+
23+
If a contribution is not covered by the CLA, then the automated CLA system notifies the submitter politely that we
24+
cannot identify their CLA and ask them to sign either an individual or corporate CLA. This happens automatically as a
25+
comment on pull requests.
26+
27+
When the project receives a new CLA, it is recorded in the project records, the CLA is added to the database for the
28+
automated system uses, then we manually make the Pull Request as having a CLA on-file.
29+
30+
31+
Initial Setup
32+
---------------
33+
- Install docker
34+
35+
- Add required directories
36+
37+
```bash
38+
# create parent directory
39+
mkdir -p ~/workspace
40+
cd ~/workspace
41+
42+
# clone ci
43+
git clone https://github.com/cloudfoundry/wg-app-platform-runtime-ci.git
44+
45+
# clone repo
46+
git clone https://github.com/cloudfoundry/diego-release.git --recursive
47+
cd diego-release
48+
```
49+
50+
Running Tests
51+
---------------
52+
53+
> [!TIP]
54+
> Running tests for this repo requires a DB flavor. The following scripts will default to mysql DB. Set DB environment variable for alternate DBs. Valid Options: mysql-8.0(or mysql),postgres
55+
56+
- `./scripts/create-docker-container.bash`: This will create a docker container with appropriate mounts. This
57+
script can be used for interactive development with a long running container.
58+
- `./scripts/test-in-docker.bash`: Create docker container and run all tests and setup in a single script.
59+
- `./scripts/test-in-docker.bash <package> <sub-package>`: For running tests under a specific package and/or sub-package
60+
61+
When inside docker container:
62+
63+
- `/repo/scripts/docker/build-binaries.bash`: (REQUIRED) This will build required binaries for running tests.
64+
- `/repo/scripts/docker/test.bash`: This will run all tests in this repo.
65+
- `/repo/scripts/docker/test.bash <package>`: This will only run a package's tests
66+
- `/repo/scripts/docker/test.bash <package> <sub-package>`: This will only run sub-package tests for package
67+
- `/repo/scripts/docker/tests-template.bash`: This will test bosh-spec templates.
68+
- `/repo/scripts/docker/lint.bash`: This will run required linters.
69+
70+
> [!IMPORTANT]
71+
> If you are about to submit a PR, please make sure to run `./scripts/test-in-docker.bash` for MySQL and Postgres to ensure everything is tested in clean container. If you are developing, you can create create a docker container first, then the only required script to run before testing your specific component is `build-binaries.bash`.

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
blank_issues_enabled: false
2+
contact_links:
3+
- name: CloudFoundry slack
4+
url: https://cloudfoundry.slack.com
5+
about: For help or questions about this component, you can reach the maintainers on Slack

.github/ISSUE_TEMPLATE/issue-bug.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Bug
2+
description: Report a defect, such as a bug or regression.
3+
title: "Start the title with a verb (e.g. Change header styles). Use the imperative mood in the title (e.g. Fix, not Fixed or Fixes header styles)"
4+
labels:
5+
- bug
6+
body:
7+
- type: textarea
8+
id: current
9+
attributes:
10+
label: Current behavior
11+
validations:
12+
required: true
13+
- type: markdown
14+
id: current_md
15+
attributes:
16+
value: |
17+
- Explain, in detail, what the current state of the world is
18+
- Include code snippets, log output, and analysis as necessary to explain the whole problem
19+
- Include links to logs, GitHub issues, slack conversations, etc.. to tell us where the problem came from
20+
- Steps to reproduce
21+
- type: textarea
22+
id: desired
23+
attributes:
24+
label: Desired behavior
25+
validations:
26+
required: true
27+
- type: markdown
28+
id: desired_md
29+
attributes:
30+
value: |
31+
- Describe how the problem should be fixed
32+
- Does this require a new bosh release?
33+
- Does it require configuration changes in cf-deployment?
34+
- Do we need to have a special release note?
35+
- Do we need to update repo documentation?
36+
- type: input
37+
id: version
38+
attributes:
39+
label: Affected Version
40+
description: Please enter the version
41+
validations:
42+
required: true
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: Enhance
2+
description: Propose an enhancement or new feature.
3+
title: "Start the title with a verb (e.g. Change header styles). Use the imperative mood in the title (e.g. Fix, not Fixed or Fixes header styles)"
4+
labels:
5+
- enhancement
6+
body:
7+
- type: textarea
8+
id: change
9+
attributes:
10+
label: Proposed Change
11+
validations:
12+
required: true
13+
- type: markdown
14+
id: change_md
15+
attributes:
16+
value: |
17+
Briefly explain why this feature is necessary in the following format
18+
19+
**As a** *developer/operator/whatever*
20+
**I want** *this ability to do X*
21+
**So that** *I can do Y*
22+
23+
- Provide details of where this request is coming from including links, GitHub Issues, etc..
24+
- Provide details of prior work (if applicable) including links to commits, github issues, etc...
25+
- type: textarea
26+
id: acceptance
27+
attributes:
28+
label: Acceptance criteria
29+
validations:
30+
required: true
31+
- type: markdown
32+
id: acceptance_md
33+
attributes:
34+
value: |
35+
Detail the exact work that is required to accept this story in the following format
36+
37+
**Scenario:** *describe scenario*
38+
**Given** *I have some sort of configuration*
39+
**When** *I do X*
40+
**And** *do Y*
41+
**Then** *I see the desired behavior*
42+
43+
- type: textarea
44+
id: related
45+
attributes:
46+
label: Related links
47+
description: Please list related links for this issue
48+
placeholder: |
49+
- [ ] code.cloudfoundry.org/bbs for links
50+
- [x] cloudfoundry/rep#123 for issues/prs

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 21 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,21 @@
1-
Thank you for submitting a pull request to the bbs repository!
2-
3-
We appreciate the contribution. To help us understand the context for your pull request, please fill out this template to the best of your ability.
4-
5-
## Please make sure to complete all of the following steps
6-
7-
1. Check the [Contributing document](https://github.com/cloudfoundry/diego-release/blob/develop/CONTRIBUTING.md) on how to sign the CLA and run tests.
8-
1. Submit your PR to this repo.
9-
1. [**Submit an accompanying PR Review Request**](https://github.com/cloudfoundry/diego-release/issues/new?assignees=&labels=&template=pr-review-request.md&title=%5BBBS+PR+REVIEW%5D%3A) referencing this PR so the Diego Team knows to review your pull request.
10-
* **Note: this PR will not be reviewed unless you submit the [PR Review Request](https://github.com/cloudfoundry/diego-release/issues/new?assignees=&labels=&template=pr-review-request.md&title=%5BBS+BPR+REVIEW%5D%3A)**.
11-
12-
***************************
13-
14-
## Please provide the following information:
15-
16-
### What is this change about?
17-
18-
> _Please describe._
19-
20-
### What problem it is trying to solve?
21-
22-
> _Please describe._
23-
24-
### What is the impact if the change is not made?
25-
26-
> _Please describe._
27-
28-
### How should this change be described in diego-release release notes?
29-
30-
> _Something brief that conveys the change. See [previous release notes](https://github.com/cloudfoundry/diego-release/releases) for examples._
31-
32-
### Please provide any contextual information.
33-
34-
> _Include any links to other PRs, stories, slack discussions, etc._
35-
36-
### Tag your pair, your PM, and/or team!
37-
38-
> _It's helpful to tag someone on your team or your team alias in case we need to follow up later._
39-
40-
Thank you!
1+
- [ ] Read the [Contributing document](../blob/-/.github/CONTRIBUTING.md).
2+
3+
Summary
4+
---------------
5+
<!---
6+
- Briefly explain why this PR is necessary
7+
- Provide details of where this request is coming from including links, GitHub Issues, etc..
8+
- Provide details of prior work (if applicable) including links to commits, github issues, etc...
9+
--->
10+
11+
12+
Backward Compatibility
13+
---------------
14+
Breaking Change? **Yes/No**
15+
<!---
16+
If this is a breaking change, or modifies currently expected behaviors of core functionality
17+
18+
- Has the change been mitigated to be backwards compatible?
19+
- Should this feature be considered experimental for a period of time, and allow operators to opt-in?
20+
- Should this apply immediately to all deployments?
21+
-->

.github/TEMPLATE-README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
2+
> [!IMPORTANT]
3+
> Content in this directory is managed by the CI task `sync-dot-github-dir`.
4+
5+
Changing templates
6+
---------------
7+
These templates are synced from [these shared templates](https://github.com/cloudfoundry/wg-app-platform-runtime-ci/tree/main/shared/github).
8+
Each pipeline will contain a `sync-dot-github-dir-*` job for updating the content of these files.
9+
If you would like to modify these, please change them in the shared group.
10+
It's also possible to override the templates on pipeline's parent directory by introducing a custom
11+
template in `$PARENT_TEMPLATE_DIR/github/FILENAME` or `$PARENT_TEMPLATE_DIR/github/REPO_NAME/FILENAME` in CI repo

0 commit comments

Comments
 (0)