Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(jetbrains-gateway): add slug variable #322

Merged
merged 3 commits into from
Oct 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions jetbrains-gateway/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ This module adds a JetBrains Gateway Button to open any workspace with a single
```tf
module "jetbrains_gateway" {
source = "registry.coder.com/modules/jetbrains-gateway/coder"
version = "1.0.20"
version = "1.0.21"
agent_id = coder_agent.example.id
agent_name = "example"
folder = "/home/coder/example"
Expand All @@ -32,7 +32,7 @@ module "jetbrains_gateway" {
```tf
module "jetbrains_gateway" {
source = "registry.coder.com/modules/jetbrains-gateway/coder"
version = "1.0.20"
version = "1.0.21"
agent_id = coder_agent.example.id
agent_name = "example"
folder = "/home/coder/example"
Expand All @@ -46,7 +46,7 @@ module "jetbrains_gateway" {
```tf
module "jetbrains_gateway" {
source = "registry.coder.com/modules/jetbrains-gateway/coder"
version = "1.0.20"
version = "1.0.21"
agent_id = coder_agent.example.id
agent_name = "example"
folder = "/home/coder/example"
Expand All @@ -61,7 +61,7 @@ module "jetbrains_gateway" {
```tf
module "jetbrains_gateway" {
source = "registry.coder.com/modules/jetbrains-gateway/coder"
version = "1.0.20"
version = "1.0.21"
agent_id = coder_agent.example.id
agent_name = "example"
folder = "/home/coder/example"
Expand Down
8 changes: 7 additions & 1 deletion jetbrains-gateway/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,12 @@ variable "agent_id" {
description = "The ID of a Coder agent."
}

variable "slug" {
type = string
description = "The slug for the coder_app. Allows resuing the module with the same template."
default = "gateway"
}

variable "agent_name" {
type = string
description = "Agent name."
Expand Down Expand Up @@ -247,7 +253,7 @@ data "coder_workspace_owner" "me" {}

resource "coder_app" "gateway" {
agent_id = var.agent_id
slug = "gateway"
slug = var.slug
display_name = local.display_name
icon = local.icon
external = true
Expand Down