The StepSecurity provider allows Terraform to manage StepSecurity resources, enabling you to secure your GitHub Actions workflows and repositories through infrastructure as code.
The provider will be installed automatically when you run terraform init if you include it in your configuration.
terraform {
required_providers {
stepsecurity = {
source = "step-security/stepsecurity"
version = "~> 1.0"
}
}
}The provider requires authentication with the StepSecurity API. You can configure this in several ways:
export STEP_SECURITY_API_KEY="your-api-key"
export STEP_SECURITY_CUSTOMER="your-customer-name"
export STEP_SECURITY_API_BASE_URL="api-base-url" # Optionalprovider "stepsecurity" {
api_key = "your-api-key"
customer = "your-customer-name"
api_base_url = "api-base-url" # Optional
}For detailed documentation on all available resources and data sources, visit the Terraform Registry.
The examples directory contains sample configurations for various use cases:
- Clone the repository:
git clone https://github.com/step-security/terraform-provider-stepsecurity.git
cd terraform-provider-stepsecurity- Build the provider:
make build# Run unit tests
make test
# Run acceptance tests (requires API credentials and needs local API setup)
make testaccAfter building the provider, you can test it locally by creating a .terraformrc file in your home directory:
provider_installation {
dev_overrides {
"step-security/stepsecurity" = "/path/to/terraform-provider-stepsecurity"
}
direct {}
}If you encounter any issues or have feature requests, please create an issue on GitHub.