OpenAPI specification for OneUptime. This document describes the API endpoints, request and response formats, and other details necessary for developers to interact with the OneUptime API.
- Clone the repository
git clone https://github.com/oneuptime/terraform-provider-oneuptime
cd terraform-provider-oneuptime- Build the provider using the Go
installcommand:
go buildterraform {
required_providers {
oneuptime = {
source = "oneuptime/oneuptime"
version = "1.0.0"
}
}
}
provider "oneuptime" {
oneuptime_url = "https://api.oneuptime.com"
api_key = var.oneuptime_api_key
}If you wish to work on the provider, you'll first need Go installed on your machine (see Requirements above).
To compile the provider, run go build. This will build the provider and put the provider binary in the current directory.
To generate or update documentation, run go generate.
In order to run the full suite of Acceptance tests, run make testacc.
Note: Acceptance tests create real resources, and often cost money to run.
make testaccTo install the provider locally for testing:
make installThis will build and install the provider to your local Terraform plugins directory.
To run unit tests:
go test ./...To run acceptance tests:
TF_ACC=1 go test ./... -v -timeout 120mDocumentation is generated using terraform-plugin-docs. Run the following command to generate documentation:
go generate- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -am 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the Apache 2.0 License - see the LICENSE file for details.