refactor: remove SDKs to start agent faster
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
c59097d374
commit
0fe7a1ebba
2 changed files with 2 additions and 68 deletions
|
@ -17,6 +17,7 @@ packages:
|
|||
- bat
|
||||
- fzf
|
||||
- dnf-plugins-core
|
||||
- icu
|
||||
%{ if install_podman_setup ~}
|
||||
- podman
|
||||
- podman-docker
|
||||
|
@ -24,13 +25,6 @@ packages:
|
|||
- skopeo
|
||||
- buildah
|
||||
%{ endif ~}
|
||||
%{ if install_go_setup ~}
|
||||
- golang
|
||||
%{ endif ~}
|
||||
%{ if install_dotnet_setup ~}
|
||||
- dotnet-sdk-6.0
|
||||
- dotnet-sdk-7.0
|
||||
%{ endif ~}
|
||||
mounts:
|
||||
- [
|
||||
"${volume_path}",
|
||||
|
@ -82,11 +76,7 @@ write_files:
|
|||
runcmd:
|
||||
- chown -R ${username}:${username} /home/${username}
|
||||
- systemctl enable --now coder-agent
|
||||
%{ if install_terraform_setup ~}
|
||||
- dnf config-manager --add-repo https://rpm.releases.hashicorp.com/fedora/hashicorp.repo
|
||||
- dnf -y install terraform
|
||||
%{ endif ~}
|
||||
%{ if install_dotnet_setup ~}
|
||||
%{ if install_podman_setup ~}
|
||||
- loginctl enable-linger ${username}
|
||||
- mkdir -p /home/${username}/.config/systemd/user/sockets.target.wants
|
||||
- ln -sf /usr/lib/systemd/system/podman.socket /home/${username}/.config/systemd/user/sockets.target.wants/
|
||||
|
|
|
@ -195,41 +195,6 @@ data "coder_parameter" "code_server" {
|
|||
}
|
||||
}
|
||||
|
||||
data "coder_parameter" "install_go" {
|
||||
name = "install_go"
|
||||
description = "Should Go SDK be installed?"
|
||||
default = "true"
|
||||
type = "string"
|
||||
mutable = true
|
||||
option {
|
||||
name = "Install"
|
||||
value = "true"
|
||||
}
|
||||
|
||||
option {
|
||||
name = "Don't install"
|
||||
value = "false"
|
||||
}
|
||||
}
|
||||
|
||||
data "coder_parameter" "install_dotnet" {
|
||||
name = "install_dotnet"
|
||||
description = "Should .NET SDK be installed?"
|
||||
default = "true"
|
||||
type = "string"
|
||||
mutable = true
|
||||
|
||||
option {
|
||||
name = "Install"
|
||||
value = "true"
|
||||
}
|
||||
|
||||
option {
|
||||
name = "Don't install"
|
||||
value = "false"
|
||||
}
|
||||
}
|
||||
|
||||
data "coder_parameter" "install_podman" {
|
||||
name = "install_podman"
|
||||
description = "Should Podman be installed?"
|
||||
|
@ -247,24 +212,6 @@ data "coder_parameter" "install_podman" {
|
|||
}
|
||||
}
|
||||
|
||||
data "coder_parameter" "install_terraform" {
|
||||
name = "install_terraform"
|
||||
description = "Should Terraform be installed?"
|
||||
default = "true"
|
||||
type = "string"
|
||||
mutable = true
|
||||
|
||||
option {
|
||||
name = "Install"
|
||||
value = "true"
|
||||
}
|
||||
|
||||
option {
|
||||
name = "Don't install"
|
||||
value = "false"
|
||||
}
|
||||
}
|
||||
|
||||
data "coder_workspace" "me" {
|
||||
}
|
||||
|
||||
|
@ -314,10 +261,7 @@ resource "hcloud_server" "root" {
|
|||
init_script = base64encode(coder_agent.dev.init_script)
|
||||
coder_agent_token = coder_agent.dev.token
|
||||
code_server_setup = data.coder_parameter.code_server.value
|
||||
install_go_setup = data.coder_parameter.install_go.value
|
||||
install_dotnet_setup = data.coder_parameter.install_dotnet.value
|
||||
install_podman_setup = data.coder_parameter.install_podman.value
|
||||
install_terraform_setup = data.coder_parameter.install_terraform.value
|
||||
user_shell = data.coder_parameter.user_shell.value
|
||||
})
|
||||
|
||||
|
|
Loading…
Reference in a new issue