terraform-provider-qovery

Qovery Terraform Provider

Stars
15

Bot releases are visible (Hide)

terraform-provider-qovery - v0.17.0

Published by github-actions[bot] over 1 year ago

terraform-provider-qovery - v0.16.6

Published by github-actions[bot] over 1 year ago

terraform-provider-qovery - v0.16.5

Published by github-actions[bot] over 1 year ago

terraform-provider-qovery - v0.16.4

Published by github-actions[bot] over 1 year ago

terraform-provider-qovery - v0.16.3

Published by github-actions[bot] over 1 year ago

terraform-provider-qovery - v0.16.2

Published by github-actions[bot] over 1 year ago

What's Changed

terraform-provider-qovery - v0.16.1

Published by erebe over 1 year ago

terraform-provider-qovery - v0.16.0

Published by github-actions[bot] over 1 year ago

terraform-provider-qovery - v0.15.1

Published by github-actions[bot] over 1 year ago

What's Changed

terraform-provider-qovery - v0.15.0

Published by github-actions[bot] over 1 year ago

What's Changed

The purpose of this change is to allow the deployment of services through deployment stages.

Before this change, every service (application / database / container) was deployed sequentially using a state attribute inside the terraform file, e.g:

resource "qovery_application" "app" {
#[...]
   state = "RUNNING"
}

The following points must require your attention:

  • create deployment stages to order services deployments using a qovery_deployment_stage resource
  • pilot the whole environment deployment using a qovery_deployment resource
  • the state present in each service resources has been removed

Deployment Stage resource

This resource is not mandatory. If no deployment stage is created, services will be deployed using default natural stages: databases -> jobs -> containers -> applications

Deployment stage resource allows to set its order through move_after and move_before attributes (optional)

resource "qovery_deployment_stage" "stage_1" {
  environment_id = qovery_environment.environment.id
  name           = "Deployment Stage 1" 
  description    = "some deployment stage"
}

resource "qovery_deployment_stage" "stage_2" {
  environment_id = qovery_environment.environment.id
  name           = "Deployment Stage 2"
  description    = "some deployment stage"
  move_after     = qovery_deployment_stage.stage_1.id
}

A deployment stage can then be linked to a service, e.g:

resource "qovery_application" "app" {
#[...]

   deployment_stage_id = qovery_deployment_stage.stage_1.id
}

Deployment resource

Services are now deployed using the deployment_resource

  • desired_state is similar to the state attribute we used in service resources, it can be one of the following values: RUNNING , STOPPED, RESTARTED
  • version is used to force terraform to retrigger a deployment even if the desired_state hasn't changed.
    E.g, in the following scenario:
    • you have already applied with desired_state equal to RUNNING
    • you want to redeploy your services
    • manually set version in your qovery_deployment resource

ℹ️ version is a UUID, you can use external lib such as hashicorp/random to generate random values

terraform {
  required_providers {
    random = {
      source = "hashicorp/random"
      version = "3.4.3"
    }
  }
}

#[...]

resource "random_uuid" "test" {
}

resource "qovery_deployment" "my_deployment" {
  environment_id = qovery_environment.env.id

  desired_state  = "RUNNING"
  version        = random_uuid.test.result

  depends_on = [qovery_application.app, qovery_container.container, qovery_database.database]
}

⚠️ State attribute in service resources

the state attribute is now removed so it must not be present on the services resources.
It concerns the following resources: qovery_application, qovery_container and qovery_database

terraform-provider-qovery - v0.14.8

Published by github-actions[bot] over 1 year ago

terraform-provider-qovery - v0.14.7

Published by github-actions[bot] over 1 year ago

terraform-provider-qovery - v0.14.6

Published by erebe over 1 year ago

terraform-provider-qovery - v0.14.5

Published by github-actions[bot] over 1 year ago

What's Changed

terraform-provider-qovery - v0.14.4

Published by github-actions[bot] over 1 year ago

What's Changed

terraform-provider-qovery - v0.14.3

Published by github-actions[bot] over 1 year ago

terraform-provider-qovery - v0.14.2

Published by github-actions[bot] over 1 year ago

What's Changed

terraform-provider-qovery - v0.14.1

Published by github-actions[bot] over 1 year ago

What's Changed

terraform-provider-qovery - v0.14.0

Published by github-actions[bot] over 1 year ago

What's Changed

terraform-provider-qovery - v0.13.3

Published by github-actions[bot] over 1 year ago

What's Changed