Skip to content

Commit 78de9da

Browse files
committed
Moved the repository to athenz org (#1)
2 parents 8c1ba38 + 16eee5a commit 78de9da

38 files changed

+343
-870
lines changed

.circleci/config.yml

Lines changed: 0 additions & 161 deletions
This file was deleted.

.github/pull_request_template.md

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,13 @@ _description_with_details_and_reasoning_
1111

1212
### Flags
1313

14-
- [ ] breaks backward compatibility
15-
- [ ] requires a documentation update
16-
- [ ] has untestable code
14+
- [ ] Breaks backward compatibility
15+
- [ ] Requires a documentation update
16+
- [ ] Has untestable code
1717

1818
## Related issue/PR
1919

20-
**Delete if not applicable**
20+
**Delete this section if there are no issues or pull requests that relate to this pull request.**
2121
- Fixes #_issue_
2222
- Closes #_PR_
2323

@@ -26,15 +26,13 @@ _description_with_details_and_reasoning_
2626
## Checklist
2727

2828
- [ ] Followed the guidelines in the CONTRIBUTING document
29-
- [ ] Added prefix `[major]`/`[minor]`/`[patch]`/`[skip]` in the PR title
29+
- [ ] Added prefix `[skip ci]`/`[ci skip]`/`[no ci]`/`[skip actions]`/`[actions skip]` in the PR title if necessary
3030
- [ ] Tested and linted the code
3131
- [ ] Commented the code
3232
- [ ] Made corresponding changes to the documentation
33-
- [ ] Confirmed no dropping in test coverage (by [Codecov](https://codecov.io/gh/yahoojapan/athenz-authorizer/pulls))
3433
- [ ] Passed all pipeline checking
35-
- [ ] Approved by >1 reviewer
3634

3735
## Checklist for maintainer
3836
- [ ] Use `Squash and merge`
39-
- [ ] Double-confirm the merge message has prefix `[major]`/`[minor]`/`[patch]`/`[skip]`
37+
- [ ] Double-confirm the merge message has prefix `[skip ci]`/`[ci skip]`/`[no ci]`/`[skip actions]`/`[actions skip]`
4038
- [ ] Delete the branch after merge
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Github Releases
2+
3+
on:
4+
push:
5+
# Publish semver tags as releases.
6+
tags: [ 'v[0-9]+.[0-9]+.[0-9]+' ]
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
permissions:
12+
contents: write
13+
steps:
14+
- uses: actions/checkout@v3
15+
- uses: ncipollo/release-action@v1
16+
with:
17+
generateReleaseNotes: true

.github/workflows/go-test.yaml

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
name: Go test
2+
3+
# This workflow uses actions that are not certified by GitHub.
4+
# They are provided by a third-party and are governed by
5+
# separate terms of service, privacy policy, and support
6+
# documentation.
7+
8+
on:
9+
schedule:
10+
- cron: '0 10 * * *'
11+
# If any commit message in your push or the HEAD commit of your PR contains the strings
12+
# [skip ci], [ci skip], [no ci], [skip actions], or [actions skip]
13+
# workflows triggered on the push or pull_request events will be skipped.
14+
# https://github.blog/changelog/2021-02-08-github-actions-skip-pull-request-and-push-workflows-with-skip-ci/
15+
push:
16+
branches: [ master ]
17+
# Publish semver tags as releases.
18+
tags: [ 'v[0-9]+.[0-9]+.[0-9]+' ]
19+
# If any commit message in your push or the HEAD commit of your PR contains the strings
20+
# [skip ci], [ci skip], [no ci], [skip actions], or [actions skip]
21+
# workflows triggered on the push or pull_request events will be skipped.
22+
# https://github.blog/changelog/2021-02-08-github-actions-skip-pull-request-and-push-workflows-with-skip-ci/
23+
pull_request:
24+
branches: [ master ]
25+
26+
env:
27+
GOLANG_VERSION: ^1.18
28+
29+
jobs:
30+
build:
31+
runs-on: ubuntu-latest
32+
permissions:
33+
actions: none
34+
checks: none
35+
contents: read
36+
deployments: none
37+
issues: none
38+
discussions: none
39+
packages: none
40+
pull-requests: none
41+
repository-projects: none
42+
security-events: none
43+
statuses: none
44+
45+
steps:
46+
# This action checks-out your repository under $GITHUB_WORKSPACE, so your workflow can access it.
47+
# https://github.com/actions/checkout
48+
-
49+
name: Checkout repository
50+
id: checkout
51+
# You may pin to the exact commit or the version.
52+
# uses: https://github.com/actions/checkout/tags
53+
uses: actions/checkout@v3
54+
55+
# This action sets up a go environment for use in actions by:
56+
# - Optionally downloading and caching a version of Go by version and adding to PATH.
57+
# - Registering problem matchers for error output.
58+
# https://github.com/actions/setup-go
59+
-
60+
name: Setup Golang
61+
id: setup-go
62+
# You may pin to the exact commit or the version.
63+
# uses: https://github.com/actions/setup-go/tags
64+
uses: actions/setup-go@v3
65+
with:
66+
go-version: ${{ env.GOLANG_VERSION }}
67+
68+
# This action allows caching dependencies and build outputs to improve workflow execution time.
69+
# https://github.com/actions/cache
70+
-
71+
name: Cache Go Modules
72+
id: cache-go
73+
uses: actions/cache@v3
74+
with:
75+
path: |
76+
~/.cache/go-build
77+
~/go/pkg/mod
78+
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
79+
restore-keys: |
80+
${{ runner.os }}-go-
81+
82+
# A GitHub Action for golang tests
83+
-
84+
name: Golang Tests
85+
id: go-tests
86+
run: |
87+
go version
88+
rm -rf example
89+
go test -v -race -covermode=atomic -coverprofile=coverage.out ./...
90+
go tool cover -html=coverage.out -o coverage.html

CODE_OF_CONDUCT.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
## Athenz Community Code of Conduct
2+
3+
Athenz follows the [CNCF Code of Conduct](https://github.com/cncf/foundation/blob/master/code-of-conduct.md).
Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -25,22 +25,12 @@ make test
2525
- If your patch is not getting reviewed or you need a specific person to review it, you can @-reply a reviewer asking for a review in the pull request or a comment.
2626
- Add tests relevant to the fixed bug or new feature.
2727
- Update the README.md with details of changes to the interface, this includes new environment variables, exposed ports, useful file locations and container parameters.
28-
- Add prefix `[major]`, `[minor]`, `[patch]` or `[skip]` in the PR title for releasing.
29-
- Please use `Squash and merge` to merge a PR and double-confirm the merging message.
30-
- Merging PR to master will increase the version no. and create a new release automatically.
31-
- The new version no. depends on the commit message prefix when new PRs is merged to master branch.
32-
- Commit message prefix and release tag reference table:
33-
| **Commit Msg Prefix** | **New Version No.** | **Release `latest` Tag** | **Release `nightly` Tag** |
34-
|:---------------------:|:--------------------:|:------------------------:|:-------------------------:|
35-
| `[major] *` | `v1.2.3` => `v2.0.0` |||
36-
| `[minor] *` | `v1.2.3` => `v1.3.0` |||
37-
| `[patch] *` | `v1.2.3` => `v1.2.4` |||
38-
| `[skip] *` ||||
39-
- Other prefixes will cause the pipeline to **FAIL**❌.
28+
- Please use `Squash and merge` to merge a PR.
29+
- Create a git tag to make a release. Docker image with the `latest` tag will also be updated.
4030

4131
## Dependency management
4232

43-
The Athenz authorizer project uses [Go modules](https://golang.org/cmd/go/#hdr-Modules__module_versions__and_more) to manage dependencies on external packages. This requires a working Go environment with version 1.14 or greater installed.
33+
The Athenz authorizer project uses [Go modules](https://golang.org/cmd/go/#hdr-Modules__module_versions__and_more) to manage dependencies on external packages. This requires a working Go environment with version 1.18 or greater installed.
4434

4535
To add or update a new dependency, use the `go get` command:
4636

0 commit comments

Comments
 (0)