Skip to content

tuier/terraform-provider-chronos

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Chronos Terraform Provider

Install

$ go get 

Usage

Provider Configuration

Use a tfvar file or set the ENV variable

$ export TF_VAR_chronos_url="http://chronos.domain.tld:4040"
variable "chronos_url" {}

provider "chronos" {
  url = "${var.chronos_url}"
}
$ export TF_VAR_chronos_url="https://chronos.domain.tld:8443"
$ export TF_VAR_chronos_debug="true"
$ export TF_VAR_chronos_timeout="5"
variable "chronos_url" {}
variable "chronos_debug" {}
variable "chronos_timeout" {}

provider "chronos" {
  url = "${var.chronos_url}"
  debug = "${var.chronos_debug}"
  request_timeout = "${var.chronos_timeout}"
}

Basic Usage

resource "chronos_job" "hello-world" {
  name = "Hello World"
  command = "echo Hello World"
  owner = "[email protected]"
  owner_name = "firstname surname"
  description = "simple example who display Hello World"
  schedule = "R/2014-03-08T20:00:00.000Z/PT2H"
  schedule_timezone = "GMT"
}

Docker Usage

resource "chronos_job" "docker-hello-world" {
  name = "Hello Docker"
  command = "echo Hello Docker"
  owner = "[email protected]"
  owner_name = "firstname surname"
  description = "simple example who display Hello Docker"
  container = {
  	type = "DOCKER"
  	image = "debian:jessie"
  	network = "HOST"
  }
  schedule = "R/2014-03-08T20:00:00.000Z/PT2H"
  schedule_timezone = "GMT"
}

Development

Build

$ go install

Test

$ export CHRONOS_URL="http://chronos.domain.tld:8080"
$ ./test.sh

About

Terraform provider for the mesos framework: Chronos

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published