Skip to content
terraform provider that manages nix builds and nixos machines.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
example Implement #10 (inline expressions + configs) and improve documentation. Apr 19, 2019
nix
.gitignore
LICENSE
README.md
data_nix_build.go
go.mod Fix stale mod file. Apr 9, 2019
go.sum
main.go
provider.go Add build resource, allow builds to work when they depend on local fi… Apr 16, 2019
resource_nix_build.go
resource_nixos.go Implement #10 (inline expressions + configs) and improve documentation. Apr 19, 2019

README.md

terraform-provider-nix

A terraform provider for nix builds and nixos installations.

With this provider you can do things like:

  • Build a vm image from a nix expression and deploy it with terraform.
  • Build a docker image from a nix expression and deploy it with terraform.
  • Manage a nixos installation via ssh.

Note, this is a completely different project from the existing plugin in nixpkgs. Please consult that project to decide which suites your needs better.

Quickstart

This will run the example which is a good starting point, demonstrating all options. The example uses google cloud, though I would appreciate contributed examples for other platforms. After running the example you will have a managed server and vm images.

go build
cd example
terraform init -plugin-dir ../
terraform apply -var google_cloud_project=your_project_id

Debugging

To view commands being run, set the env variable TF_LOG=debug.

Example configuration and options

See the example directory for an example configuration with all valid options specified.

Development Status

Working, but want feedback and users. Currently breaking changes are possible to enhance the design. Breaking changes will be announced on the mailing list.

Contact

Sponsor Messages

This project was sponsored by backupbox.io

... Your message here

Sponsoring

This project took time and effort to make, please sponsor the project via this paypal donation link.

Add a markdown message shorter than 70 characters total to your donation it will be added to the sponsor section. Note that sponsor messages may be rejected at the project authors judgement.

If you can't afford to sponsor, please consider giving this project a star and share with your friends.

Authors

Andrew Chambers - ac@acha.ninja

You can’t perform that action at this time.