mirror of
https://github.com/coder/coder.git
synced 2025-07-23 21:32:07 +00:00
chore(examples): Add login_before_ready
and startup_script_timeout
(#5880)
This commit is contained in:
committed by
GitHub
parent
90c4d5d28a
commit
a1212014df
@ -2,7 +2,7 @@ terraform {
|
||||
required_providers {
|
||||
coder = {
|
||||
source = "coder/coder"
|
||||
version = "0.6.6"
|
||||
version = "0.6.10"
|
||||
}
|
||||
google = {
|
||||
source = "hashicorp/google"
|
||||
@ -46,15 +46,18 @@ resource "google_compute_disk" "root" {
|
||||
}
|
||||
|
||||
resource "coder_agent" "main" {
|
||||
auth = "google-instance-identity"
|
||||
arch = "amd64"
|
||||
os = "linux"
|
||||
startup_script = <<EOT
|
||||
#!/bin/bash
|
||||
auth = "google-instance-identity"
|
||||
arch = "amd64"
|
||||
os = "linux"
|
||||
|
||||
login_before_ready = false
|
||||
startup_script_timeout = 180
|
||||
startup_script = <<-EOT
|
||||
set -e
|
||||
|
||||
# install and start code-server
|
||||
curl -fsSL https://code-server.dev/install.sh | sh -s -- --version 4.8.3 | tee code-server-install.log
|
||||
code-server --auth none --port 13337 | tee code-server-install.log &
|
||||
curl -fsSL https://code-server.dev/install.sh | sh -s -- --version 4.8.3
|
||||
code-server --auth none --port 13337 >/tmp/code-server.log 2>&1 &
|
||||
EOT
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user