Verified Commit 94f04dd1 authored by Daniel Sonck's avatar Daniel Sonck
Browse files

Remove dependency on remote state

parent bb05f9f6
Pipeline #413 waiting for manual action with stages
in 3 minutes and 52 seconds
data "terraform_remote_state" "player" {
backend = "http"
config = {
address = var.player_state_address
}
}
locals {
labels = {
environment = var.environment
......@@ -17,7 +9,10 @@ locals {
}
name = "${var.environment}-playlist"
player = data.terraform_remote_state.player.outputs.service
player = {
address = var.player_address
port = var.player_port
}
}
resource "kubernetes_service_account" "playlist" {
......
......@@ -15,7 +15,8 @@ terraform {
EOB
cat << EOC > details.auto.tfvars # language=terraform
player_state_address = "${CI_API_V4_URL:-}/projects/${player_project_id:-131}/terraform/state/${ENV}"
player_address = "${player_address:-player.default}"
player_port = "${player_port:-2000}"
environment = "${ENV}"
gitlab_app = "${APP}"
......
......@@ -14,10 +14,14 @@ variable "gitlab_app" {
type = string
}
variable "player_state_address" {
variable "player_address" {
type = string
}
variable "player_port" {
type = number
}
variable "image" {
type = string
}
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment