The StepSecurity provider allows Terraform to manage StepSecurity resources, enabling you to secure your GitHub Actions workflows and repositories through infrastructure as code.
Quick Links
Requirements
Using the Provider
Installation
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"
}
}
}
Authentication
The provider requires authentication with the StepSecurity API. You can configure this in several ways:
Environment Variables (Recommended)
export STEP_SECURITY_API_KEY="your-api-key"
export STEP_SECURITY_CUSTOMER="your-customer-name"
export STEP_SECURITY_API_BASE_URL="api-base-url" # Optional
Provider Configuration
provider "stepsecurity" {
api_key = "your-api-key"
customer = "your-customer-name"
api_base_url = "api-base-url" # Optional
}
Documentation
For detailed documentation on all available resources and data sources, visit the Terraform Registry.
Examples
The examples directory contains sample configurations for various use cases:
Development
Building the Provider
- Clone the repository:
git clone https://github.com/step-security/terraform-provider-stepsecurity.git
cd terraform-provider-stepsecurity
- Build the provider:
make build
Running Tests
# Run unit tests
make test
# Run acceptance tests (requires API credentials and needs local API setup)
make testacc
Testing Locally
After 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 {}
}
Reporting Issues
If you encounter any issues or have feature requests, please create an issue on GitHub.
Support