diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 8d85f88..0092dbd 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,3 +1,19 @@ +# Copyright 2024 Cisco Systems, Inc. and its affiliates +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 + version: 2 updates: - package-ecosystem: "github-actions" @@ -9,3 +25,12 @@ updates: - "github/*" schedule: interval: "weekly" + - package-ecosystem: "gomod" + directory: "/" + schedule: + interval: "weekly" + groups: + go-dependencies: + patterns: + - "*" + open-pull-requests-limit: 5 diff --git a/.github/workflows/dependency-review.yml b/.github/workflows/dependency-review.yml new file mode 100644 index 0000000..da4b6cb --- /dev/null +++ b/.github/workflows/dependency-review.yml @@ -0,0 +1,43 @@ +# Copyright 2024 Cisco Systems, Inc. and its affiliates +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 + +# Dependency Review Action +# +# This Action will scan dependency manifest files that change as part of a Pull Request, +# surfacing known-vulnerable versions of the packages declared or updated in the PR. +# Once installed, if the workflow run is marked as required, +# PRs introducing known-vulnerable packages will be blocked from merging. +# +# Source repository: https://github.com/actions/dependency-review-action +name: 'Dependency Review' +on: [pull_request] + +permissions: + contents: read + +jobs: + dependency-review: + runs-on: ubuntu-latest + steps: + - name: Harden Runner + uses: step-security/harden-runner@63c24ba6bd7ba022e95695ff85de572c04a18142 # v2.7.0 + with: + egress-policy: audit + + - name: 'Checkout Repository' + uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0 + - name: 'Dependency Review' + uses: actions/dependency-review-action@0efb1d1d84fc9633afcdaad14c485cbbc90ef46c # v2.5.1 diff --git a/.github/workflows/license.yml b/.github/workflows/license.yml new file mode 100644 index 0000000..199d976 --- /dev/null +++ b/.github/workflows/license.yml @@ -0,0 +1,41 @@ +# Copyright 2024 Cisco Systems, Inc. and its affiliates +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 + +name: license-check + +on: + push: + branches: + # Run on pushes to default branch + - main + # Run against pull requests + pull_request: + +permissions: + contents: read + +jobs: + markdown: + runs-on: ubuntu-latest + steps: + - name: 🔒 harden runner + uses: step-security/harden-runner@63c24ba6bd7ba022e95695ff85de572c04a18142 # v2.7.0 + with: + egress-policy: audit + - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2 + - name: ⬇️ license checker + run: | + make check-license diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index bdee019..ae1cdce 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -1,3 +1,19 @@ +# Copyright 2024 Cisco Systems, Inc. and its affiliates +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 + name: lint on: @@ -8,6 +24,9 @@ on: # Run against pull requests pull_request: +permissions: + contents: read + jobs: markdown: runs-on: ubuntu-latest @@ -17,8 +36,6 @@ jobs: with: egress-policy: audit - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2 - - name: ⬇️ lint markdown files - uses: avto-dev/markdown-lint@04d43ee9191307b50935a753da3b775ab695eceb # v1.5.0 - with: - config: ".markdownlint.json" - args: "**/*.md .github/**/*.md" + - name: ⬇️ lint + run: | + make lint diff --git a/.github/workflows/markdown.yml b/.github/workflows/markdown.yml new file mode 100644 index 0000000..5e0c891 --- /dev/null +++ b/.github/workflows/markdown.yml @@ -0,0 +1,43 @@ +# Copyright 2024 Cisco Systems, Inc. and its affiliates +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 + +name: markdown-lint + +on: + push: + branches: + # Run on pushes to default branch + - main + # Run against pull requests + pull_request: + +permissions: + contents: read + +jobs: + markdown: + runs-on: ubuntu-latest + steps: + - name: 🔒 harden runner + uses: step-security/harden-runner@63c24ba6bd7ba022e95695ff85de572c04a18142 # v2.7.0 + with: + egress-policy: audit + - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2 + - name: ⬇️ lint markdown files + uses: avto-dev/markdown-lint@04d43ee9191307b50935a753da3b775ab695eceb # v1.5.0 + with: + config: ".markdownlint.json" + args: "**/*.md .github/**/*.md" diff --git a/.github/workflows/scorecard.yml b/.github/workflows/scorecard.yml index 532cc5c..478b4d0 100644 --- a/.github/workflows/scorecard.yml +++ b/.github/workflows/scorecard.yml @@ -1,3 +1,19 @@ +# Copyright 2024 Cisco Systems, Inc. and its affiliates +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 + name: scorecard on: @@ -23,6 +39,8 @@ jobs: permissions: id-token: write security-events: write + contents: read + actions: read secrets: inherit with: # Publish results of Scorecard analysis diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml index 152ddf8..ff79b99 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/stale.yml @@ -1,3 +1,19 @@ +# Copyright 2024 Cisco Systems, Inc. and its affiliates +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 + name: stale on: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..065ba00 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,41 @@ +# Copyright 2024 Cisco Systems, Inc. and its affiliates +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 + +name: test + +on: + push: + branches: + # Run on pushes to default branch + - main + # Run against pull requests + pull_request: + +permissions: + contents: read + +jobs: + markdown: + runs-on: ubuntu-latest + steps: + - name: 🔒 harden runner + uses: step-security/harden-runner@63c24ba6bd7ba022e95695ff85de572c04a18142 # v2.7.0 + with: + egress-policy: audit + - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2 + - name: ⬇️ test + run: | + make test diff --git a/.markdownlint.json b/.markdownlint.json index 2a820e7..cfea3e9 100644 --- a/.markdownlint.json +++ b/.markdownlint.json @@ -1,5 +1,7 @@ { "default": true, + "MD009": false, + "MD012": false, "MD013": { "line_length": 10000, "headings": false, @@ -12,5 +14,7 @@ "MD025": { "front_matter_title": "" }, + "MD031": false, + "MD032": false, "MD041": false } diff --git a/.pre-commit-config.yml b/.pre-commit-config.yml new file mode 100644 index 0000000..43c463d --- /dev/null +++ b/.pre-commit-config.yml @@ -0,0 +1,30 @@ +# Copyright 2024 Cisco Systems, Inc. and its affiliates +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 + +repos: +- repo: https://github.com/gitleaks/gitleaks + rev: v8.16.3 + hooks: + - id: gitleaks +- repo: https://github.com/jumanjihouse/pre-commit-hooks + rev: 3.0.0 + hooks: + - id: shellcheck +- repo: https://github.com/pre-commit/pre-commit-hooks + rev: v4.4.0 + hooks: + - id: end-of-file-fixer + - id: trailing-whitespace diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 7bd83d5..79871f0 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,6 +1,6 @@ # How to Contribute -Thanks for your interest in contributing to ``! Here are a few general guidelines on contributing and +Thanks for your interest in contributing to `terraform-provider-observability`! Here are a few general guidelines on contributing and reporting bugs that we ask you to review. Following these guidelines helps to communicate that you respect the time of the contributors managing and developing this open source project. In return, they should reciprocate that respect in addressing your issue, assessing changes, and helping you finalize your pull requests. In that spirit of mutual respect, @@ -14,7 +14,7 @@ any real-time space e.g., Slack, Discord, etc. ## Reporting Issues Before reporting a new issue, please ensure that the issue was not already reported or fixed by searching through our -[issues list](https://github.com/org_name/repo_name/issues). +[issues list](https://github.com/cisco-open/terraform-provider-observability/issues). When creating a new issue, please be sure to include a **title and clear description**, as much relevant information as possible, and, if possible, a test case. @@ -32,16 +32,16 @@ reserve breaking changes until the next major version release. ## Other Ways to Contribute -We welcome anyone that wants to contribute to `` to triage and reply to open issues to help troubleshoot +We welcome anyone that wants to contribute to `terraform-provider-observability` to triage and reply to open issues to help troubleshoot and fix existing bugs. Here is what you can do: - Help ensure that existing issues follows the recommendations from the _[Reporting Issues](#reporting-issues)_ section, providing feedback to the issue's author on what might be missing. -- Review and update the existing content of our [Wiki](https://github.com/org_name/repo_name/wiki) with up-to-date +- Review and update the existing content of our [Wiki](https://github.com/cisco-open/terraform-provider-observability/wiki) with up-to-date instructions and code samples. -- Review existing pull requests, and testing patches against real existing applications that use ``. +- Review existing pull requests, and testing patches against real existing applications that use `terraform-provider-observability`. - Write a test, or add a missing test case to an existing test. -Thanks again for your interest on contributing to ``! +Thanks again for your interest on contributing to `terraform-provider-observability`! :heart: diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..7987a27 --- /dev/null +++ b/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright 2024 Cisco Systems, Inc. + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/MAINTAINERS.md b/MAINTAINERS.md index 422fdc0..afdacba 100644 --- a/MAINTAINERS.md +++ b/MAINTAINERS.md @@ -1,5 +1,4 @@ # Maintainers -- [GitHub Username](https://github.com/username) -- [GitHub Username](https://github.com/username) -- [GitHub Username](https://github.com/username) +- [Praveen Kumar](https://github.com/kprav33n) +- [Ravi Chamarthy](https://github.com/rchamarthy) diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..f98e23b --- /dev/null +++ b/Makefile @@ -0,0 +1,45 @@ +TOP_LEVEL=$(shell git rev-parse --show-toplevel) +TOOLSDIR := $(TOP_LEVEL)/.tools +ADDLICENSE := $(TOOLSDIR)/addlicense +FSOC := $(TOOLSDIR)/fsoc +FSOC_VERSION := 0.67.0 +ADDLICENSE_VERSION := 1.1.1 + +$(ADDLICENSE): + mkdir -p $(TOOLSDIR) + wget https://github.com/google/addlicense/releases/download/v$(ADDLICENSE_VERSION)/addlicense_$(ADDLICENSE_VERSION)_Linux_x86_64.tar.gz + tar -xvf addlicense_$(ADDLICENSE_VERSION)_Linux_x86_64.tar.gz -C $(TOOLSDIR) addlicense + rm addlicense_$(ADDLICENSE_VERSION)_Linux_x86_64.tar.gz + +$(FSOC): + mkdir -p $(TOOLSDIR) + wget https://github.com/cisco-open/fsoc/releases/download/v$(FSOC_VERSION)/fsoc-linux-amd64.tar.gz + tar -xvf fsoc-linux-amd64.tar.gz -C $(TOOLSDIR) fsoc-linux-amd64 + mv $(TOOLSDIR)/fsoc-linux-amd64 $(TOOLSDIR)/fsoc + rm fsoc-linux-amd64.tar.gz + + +.PHONY: all +all: lint test check-license + +.PHONY: check-license +check-license: $(ADDLICENSE) + @echo "verifying license headers" + $(TOOLSDIR)/addlicense -check . + +.PHONY: add-license +add-license: $(ADDLICENSE) + @echo "adding license headers, please commit any modified files" + $(ADDLICENSE) -s -v -c "Cisco Systems, Inc. and its affiliates" -l apache . + +.PHONY: lint +lint: + @echo "linting placeholder" + +.PHONY: test +test: + @echo "testing placeholder" + +.PHONY: clean +clean: + rm -rf $(TOOLSDIR) diff --git a/README.md b/README.md index bf70fd1..c227463 100644 --- a/README.md +++ b/README.md @@ -1,41 +1,15 @@ -# Open Source Project Template +# Cisco Terraform Provider for Observability -[![Release](https://img.shields.io/github/v/release/cisco-ospo/oss-template?display_name=tag)](CHANGELOG.md) -[![Lint](https://github.com/cisco-ospo/oss-template/actions/workflows/lint.yml/badge.svg?branch=main)](https://github.com/cisco-ospo/oss-template/actions/workflows/lint.yml) +[![License](https://img.shields.io/github/license/cisco-open/terraform-provider-observability)](LICENSE) +[![Release](https://img.shields.io/github/v/release/cisco-open/terraform-provider-observability)]( + +[![Lint](https://github.com/cisco-open/terraform-provider-observability/actions/workflows/lint.yml/badge.svg?branch=main)](https://github.com/cisco-open/terraform-provider-observability/actions/workflows/lint.yml) [![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-2.1-fbab2c.svg)](CODE_OF_CONDUCT.md) [![Maintainer](https://img.shields.io/badge/Maintainer-Cisco-00bceb.svg)](https://opensource.cisco.com) -## Before You Start - -As much as possible, we have tried to provide enough tooling to get you up and running quickly and with a minimum of effort. This includes sane defaults for documentation; templates for bug reports, feature requests, and pull requests; and [GitHub Actions](https://github.com/features/actions) that will automatically manage stale issues and pull requests. This latter defaults to labeling issues and pull requests as stale after 60 days of inactivity, and closing them after 7 additional days of inactivity. These [defaults](.github/workflows/stale.yml) and more can be configured. For configuration options, please consult the documentation for the [stale action](https://github.com/actions/stale). - -In trying to keep this template as generic and reusable as possible, there are some things that were omitted out of necessity and others that need a little tweaking. Before you begin developing in earnest, there are a few changes that need to be made: - -- [ ] ✅ Select an appropriate license for your project. This can easily be achieved through the 'Add File' button on the GitHub UI, naming the file `LICENSE`, and selecting your desired license from the provided list. -- [ ] Update the `` placeholder in this file to reflect the name of the license you selected above. -- [ ] Replace `[INSERT CONTACT METHOD]` in [`CODE_OF_CONDUCT.md`](CODE_OF_CONDUCT.md) with a suitable communication channel. -- [ ] Change references to `org_name` to the name of the org your repo belongs to (eg. `cisco-open`): - - [ ] In [`README.md`](README.md) - - [ ] In [`CONTRIBUTING.md`](CONTRIBUTING.md) -- [ ] Change references to `repo_name` to the name of your new repo: - - [ ] In [`README.md`](README.md) - - [ ] In [`CONTRIBUTING.md`](CONTRIBUTING.md) -- [ ] Update the link to the contribution guidelines to point to your project: - - [ ] In [`.github/ISSUE_TEMPLATE/BUG_REPORT.md`](.github/ISSUE_TEMPLATE/BUG_REPORT.md) - - [ ] In [`.github/PULL_REQUEST_TEMPLATE.md`](.github/PULL_REQUEST_TEMPLATE.md) -- [ ] Replace the `` placeholder with the name of your project: - - [ ] In [`CONTRIBUTING.md`](CONTRIBUTING.md) - - [ ] In [`SECURITY.md`](SECURITY.md) -- [ ] Add names and contact information for actual project maintainers to [`MAINTAINERS.md`](MAINTAINERS.md). -- [ ] Delete the content of [`CHANGELOG.md`](CHANGELOG.md). We encourage you to [keep a changelog](https://keepachangelog.com/en/1.0.0/). -- [ ] Configure [`.github/dependabot.yaml`](dependabot.yaml) for your project's language and tooling dependencies. -- [ ] Replace the generic content in this file with the relevant details about your project. -- [ ] Acknowledge that some features like [branch protection rules](https://docs.github.com/en/repositories/configuring-branches-and-merges-in-your-repository/defining-the-mergeability-of-pull-requests/managing-a-branch-protection-rule) are only available when the repo is `public`. -- [ ] 🚨 Delete this section of the `README`! - -## About The Project - -Provide some information about what the project is/does. +Cisco Terraform Provider Plugin is a Hashicorp Terraform provider for the +Cisco Observability platform. The provider enables users to manage resources in +the Cisco Observability platform using Terraform. ## Getting Started @@ -43,12 +17,17 @@ To get a local copy up and running follow these simple steps. ### Prerequisites -This is an example of how to list things you need to use the software and how to install them. +This is an example of how to list things you need to use the software and how +to install them. + +- brew -- npm + Install [Homebrew](https://brew.sh) if not already installed. + +- fsoc ```sh - npm install npm@latest -g + brew install cisco-open/tap/fsoc ``` ### Installation @@ -56,24 +35,12 @@ This is an example of how to list things you need to use the software and how to 1. Clone the repo ```sh - git clone https://github.com/org_name/repo_name.git - ``` - -2. Install NPM packages - - ```sh - npm install + git clone https://github.com/cisco-open/terraform-provider-observability.git ``` -## Usage - -Use this space to show useful examples of how a project can be used. Additional screenshots, code examples and demos work well in this space. You may also link to more resources. - -_For more examples, please refer to the [Documentation](https://example.com) or the [Wiki](https://github.com/org_name/repo_name/wiki)_ - ## Roadmap -See the [open issues](https://github.com/org_name/repo_name/issues) for a list of proposed features (and known issues). +See the [open issues](https://github.com/cisco-open/terraform-provider-observability/issues) for a list of proposed features (and known issues). ## Contributing @@ -81,15 +48,8 @@ Contributions are what make the open source community such an amazing place to l ## License -Distributed under the `` License. See [LICENSE](LICENSE) for more information. +Distributed under the `Apache Software License` License. See [LICENSE](LICENSE) for more information. ## Contact -Your Name - [@twitter_handle](https://twitter.com/twitter_handle) - email - -Project Link: [https://github.com/org_name/repo_name](https://github.com/org_name/repo_name) - -## Acknowledgements - -This template was adapted from -[https://github.com/othneildrew/Best-README-Template](https://github.com/othneildrew/Best-README-Template). +For all project feedback, please use [Github Issues](https://github.com/cisco-open/terraform-provider-observability/issues). diff --git a/SECURITY.md b/SECURITY.md index 210a9c1..e7522f0 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -1,7 +1,7 @@ # Security Policies and Procedures This document outlines security procedures and general policies for the -`` project. +`terraform-provider-observability` project. - [Reporting a Bug](#reporting-a-bug) - [Disclosure Policy](#disclosure-policy) @@ -9,9 +9,9 @@ This document outlines security procedures and general policies for the ## Reporting a Bug -The `` team and community take all security bugs in -`` seriously. Thank you for improving the security of -``. We appreciate your efforts and responsible disclosure and +The `terraform-provider-observability` team and community take all security bugs in +`terraform-provider-observability` seriously. Thank you for improving the security of +`terraform-provider-observability`. We appreciate your efforts and responsible disclosure and will make every effort to acknowledge your contributions. Report security bugs by emailing `oss-security@cisco.com`.