terraform-provider-jamfpro

command module
v0.0.26 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 3, 2024 License: MPL-2.0 Imports: 4 Imported by: 0

README

Terraform Provider for Jamf Pro

This repository contains the Terraform provider for managing resources in Jamf Pro. It is built on the Terraform Plugin SDK and intended for creating and managing Jamf Pro entities like departments, sites, policies, etc.

The provider contains:

  • Resources and data sources for Jamf Pro entities (internal/provider/),
  • Examples (examples/) and generated documentation (docs/),
  • Miscellaneous meta files.

Once the provider is finalized, you may want to publish it on the Terraform Registry so that others can use it.

Requirements

Building The Provider

  1. Clone the repository
  2. Enter the repository directory
  3. Build the provider using the Go install command:
go install

Adding Dependencies

This provider uses Go modules.

To add a new dependency github.com/author/dependency to your Terraform provider:

go Get github.com/author/dependency
go mod tidy

Then commit the changes to go.mod and go.sum.

Using the provider

To use this provider, you need to configure it with your Jamf Pro instance's URL and authentication credentials. The provider allows you to manage various resources such as departments, sites, and policies within Jamf Pro.

Developing the Provider

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 install. This will build the provider and put the provider binary in the $GOPATH/bin directory.

To generate or update documentation, run go generate.

To run the full suite of Acceptance tests, execute make testacc.

Note: Acceptance tests create real resources, and often cost money to run.

make testacc

Benchmarking

Indicative time taken to implement changes using this terraform provider against a jamf cloud instance of jamf pro.

Setup: Jamf Cloud instance of Jamf Pro Empty instance of jamf pro with 0 devices enrolled Deployment of jamf pro departments (Simplement resource type in jamf pro)

API Calls Resource Type CRUD Operation Time Taken
1000 Departments Create 8m10s
1000 Departments Read 8ms
1000 Departments Update 8ms
1000 Departments delete 8ms
10000 Departments Create (TF Plan+Apply) 8m10s
10000 Departments Read (TF Plan) 2m49s
10000 Departments Update (TF Plan+Apply) 8ms
10000 Departments delete 8ms

Providers

No providers.

Modules

No modules.

Resources

The provider currently has working coverage of the following jamf pro resource types

  • account groups
  • allowed file extensions
  • departments
  • disk encryption configurations
  • dock items
  • printers
  • scripts
  • sites

Inputs

No inputs.

Outputs

No outputs.

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
internal
client
config_client.go
config_client.go
endpoints/accountgroups
accountgroups_data_handling.go
accountgroups_data_handling.go
endpoints/accounts
accounts_data_handling.go
accounts_data_handling.go
endpoints/advancedcomputersearches
advancedcomputersearches_data_source.go
advancedcomputersearches_data_source.go
endpoints/advancedmobiledevicesearches
advancedmobiledevicesearches_data_source.go
advancedmobiledevicesearches_data_source.go
endpoints/advancedusersearches
advancedusersearches_data_source.go
advancedusersearches_data_source.go
endpoints/allowedfileextensions
allowedfileextensions_object.go
allowedfileextensions_object.go
endpoints/apiintegrations
apiintegrations_data_source.go
apiintegrations_data_source.go
endpoints/apiroles
apiroles_data_source.go
apiroles_data_source.go
endpoints/buildings
buildings_data_source.go
buildings_data_source.go
endpoints/common
jamf_privileges.go This package contains shared / common resource functions
jamf_privileges.go This package contains shared / common resource functions
endpoints/computercheckin
computercheckin_data_validation.go
computercheckin_data_validation.go
endpoints/computerextensionattributes
computerextensionattributes_data_source.go
computerextensionattributes_data_source.go
endpoints/computergroups
computergroup_data_source.go
computergroup_data_source.go
endpoints/computerinventory
computerinventory_data_source.go
computerinventory_data_source.go
endpoints/computerprestages
computerprestages_data_source.go
computerprestages_data_source.go
endpoints/departments
department_data_source.go
department_data_source.go
endpoints/diskencryptionconfigurations
diskencryptionconfigurations_resource.go
diskencryptionconfigurations_resource.go
endpoints/dockitems
dockitems_data_source.go
dockitems_data_source.go
endpoints/filesharedistributionpoints
filesharedistributionpoints_data_source.go
filesharedistributionpoints_data_source.go
endpoints/macosconfigurationprofiles
macosconfigurationprofiles_data_source.go
macosconfigurationprofiles_data_source.go
endpoints/networksegments
resources_data_source.go
resources_data_source.go
endpoints/packages
packages_data_source.go
packages_data_source.go
endpoints/policies
policies_data_source.go
policies_data_source.go
endpoints/printers
printers_rdata_handling.go
printers_rdata_handling.go
endpoints/scripts
scripts_date_source.go
scripts_date_source.go
endpoints/sites
sites_data_source.go
sites_data_source.go
helpers/hash
hash.go This package contains shared / common hash functions
hash.go This package contains shared / common hash functions
helpers/provider_diagnostics
provider_diagnostics.go
provider_diagnostics.go
helpers/type_assertion
type_assertion.go
type_assertion.go
provider
providers.go
providers.go
utilities
utilities.go For utility/helper functions to support the jamf pro tf provider
utilities.go For utility/helper functions to support the jamf pro tf provider
Package version contains a variable used to construct the User-Agent for API requests.
Package version contains a variable used to construct the User-Agent for API requests.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL