diff --git a/.github/config.yml b/.github/config.yml index 82f5c54..b27bc69 100644 --- a/.github/config.yml +++ b/.github/config.yml @@ -1,3 +1,7 @@ +# Copyright 2020 Wayback Archiver. All rights reserved. +# Use of this source code is governed by the MIT license +# that can be found in the LICENSE file. + # Configuration for welcome - https://github.com/behaviorbot/welcome # Configuration for new-issue-welcome - https://github.com/behaviorbot/new-issue-welcome diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 677bc27..e5633c9 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,3 +1,7 @@ +# Copyright 2020 Wayback Archiver. All rights reserved. +# Use of this source code is governed by the MIT license +# that can be found in the LICENSE file. + # To get started with Dependabot version updates, you'll need to specify which # package ecosystems to update and where the package manifests are located. # Please see the documentation for all configuration options: diff --git a/.github/linters/.golangci.yml b/.github/linters/.golangci.yml index f53ce38..6afc608 100644 --- a/.github/linters/.golangci.yml +++ b/.github/linters/.golangci.yml @@ -1,3 +1,7 @@ +# Copyright 2020 Wayback Archiver. All rights reserved. +# Use of this source code is governed by the MIT license +# that can be found in the LICENSE file. + --- ######################### ######################### diff --git a/.github/linters/.hadolint.yaml b/.github/linters/.hadolint.yaml index b408c6b..f201b0d 100644 --- a/.github/linters/.hadolint.yaml +++ b/.github/linters/.hadolint.yaml @@ -1,3 +1,7 @@ +# Copyright 2020 Wayback Archiver. All rights reserved. +# Use of this source code is governed by the MIT license +# that can be found in the LICENSE file. + --- ########################## ## Hadolint config file ## diff --git a/.github/linters/.markdown-lint.yml b/.github/linters/.markdown-lint.yml index 37004c4..6a3b9d4 100644 --- a/.github/linters/.markdown-lint.yml +++ b/.github/linters/.markdown-lint.yml @@ -1,7 +1,7 @@ # Copyright 2020 Wayback Archiver. All rights reserved. -# Use of this source code is governed by the GNU GPL v3 -# license that can be found in the LICENSE file. -# +# Use of this source code is governed by the MIT license +# that can be found in the LICENSE file. + --- ########################### ########################### diff --git a/.github/workflows/reusable-license.yml b/.github/workflows/reusable-license.yml new file mode 100644 index 0000000..b1e00a1 --- /dev/null +++ b/.github/workflows/reusable-license.yml @@ -0,0 +1,82 @@ +# Copyright 2020 Wayback Archiver. All rights reserved. +# Use of this source code is governed by the MIT license +# that can be found in the LICENSE file. + +name: License + +on: + push: + branches: + - '**' + pull_request: + branches: + - '**' + types: [ opened, synchronize, reopened ] + workflow_call: + +permissions: + contents: read + +jobs: + header: + runs-on: ubuntu-latest + name: Check License Headers + steps: + - name: Harden Runner + uses: step-security/harden-runner@2e205a28d0e1da00c5f53b161f4067b052c61f34 # v1.5.0 + with: + egress-policy: block + disable-telemetry: true + allowed-endpoints: > + github.com:443 + api.github.com:443 + + - name: Check out code base + if: github.event_name == 'push' + uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v3.1.0 + with: + fetch-depth: 0 + persist-credentials: false + + - name: Check out code base + if: github.event_name == 'pull_request' + uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v3.1.0 + with: + fetch-depth: 0 + persist-credentials: false + ref: ${{ github.event.pull_request.head.sha }} + + - name: Check License Header + uses: apache/skywalking-eyes/header@438e4ea5682269933ea2c8b5608662e52af26959 # v0.4.0 + + dependency: + runs-on: ubuntu-latest + name: "Check Dependencies' License" + steps: + - name: Harden Runner + uses: step-security/harden-runner@2e205a28d0e1da00c5f53b161f4067b052c61f34 # v1.5.0 + with: + egress-policy: block + disable-telemetry: true + allowed-endpoints: > + github.com:443 + api.github.com:443 + + - name: Check out code base + if: github.event_name == 'push' + uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v3.1.0 + with: + fetch-depth: 0 + persist-credentials: false + + - name: Check out code base + if: github.event_name == 'pull_request' + uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # v3.1.0 + with: + fetch-depth: 0 + persist-credentials: false + ref: ${{ github.event.pull_request.head.sha }} + + - name: "Check Dependencies' License" + uses: apache/skywalking-eyes/dependency@438e4ea5682269933ea2c8b5608662e52af26959 # v0.4.0 + diff --git a/.github/workflows/reviewdog.yml b/.github/workflows/reviewdog.yml index 61ca991..da7438e 100644 --- a/.github/workflows/reviewdog.yml +++ b/.github/workflows/reviewdog.yml @@ -1,3 +1,7 @@ +# Copyright 2020 Wayback Archiver. All rights reserved. +# Use of this source code is governed by the MIT license +# that can be found in the LICENSE file. + name: ReviewDog on: diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml deleted file mode 100644 index 5553d1e..0000000 --- a/.github/workflows/stale.yml +++ /dev/null @@ -1,19 +0,0 @@ -name: Stale - -on: - schedule: - - cron: "0 3 * * 6" - -jobs: - stale: - name: Stale - runs-on: ubuntu-latest - steps: - - name: Mark stale issues and pull requests - uses: actions/stale@v3 - with: - repo-token: ${{ github.token }} - stale-issue-message: "This issue is stale because it has been open 120 days with no activity. Remove stale label or comment or this will be closed in 5 days" - stale-pr-message: 'It has been open 120 days with no activity. Remove stale label or comment or this will be closed in 5 days' - days-before-stale: 120 - days-before-close: 5 diff --git a/.licenserc.yaml b/.licenserc.yaml new file mode 100644 index 0000000..8b7c02d --- /dev/null +++ b/.licenserc.yaml @@ -0,0 +1,23 @@ +# Copyright 2020 Wayback Archiver. All rights reserved. +# Use of this source code is governed by the MIT license +# that can be found in the LICENSE file. + +header: + license: + spdx-id: MIT + copyright-owner: Wayback Archiver + content: | + Copyright 2020 Wayback Archiver. All rights reserved. + Use of this source code is governed by the MIT license + that can be found in the LICENSE file. + + paths-ignore: + - '.github/ISSUE_TEMPLATE' + - '.github/PULL_REQUEST_TEMPLATE' + - '.gitattributes' + - '.semgrepignore' + - '**/*.md' + - 'LICENSE' + - 'CODEOWNERS' + + comment: on-failure