From 9755f5a175e983a86fc7c17fd14bedc3f8c243f4 Mon Sep 17 00:00:00 2001 From: Ammar Bandukwala Date: Sun, 31 Jul 2022 19:38:38 +0000 Subject: [PATCH 1/2] docs: clean up English Some minor mistakes were introduced in #3319 --- docs/templates.md | 24 ++++++++++-------------- docs/workspaces.md | 9 +++++++++ 2 files changed, 19 insertions(+), 14 deletions(-) diff --git a/docs/templates.md b/docs/templates.md index e7122a191e99f..d6757a567aca3 100644 --- a/docs/templates.md +++ b/docs/templates.md @@ -98,11 +98,7 @@ inherited by all child processes of the agent, including SSH sessions. #### startup_script Use the Coder agent's `startup_script` to run additional commands like -installing IDEs and clone dotfile and project repos. In this example, the -project and dotfile repos are specified as Terraform input variables elsewhere -in the `main.tf` Note the `&` after the `code-server` start to execute -`code-server` process in the background so the `startup_script` can continue -with the repo cloning steps. +installing IDEs, [cloning dotfile](./dotfiles.md#templates), and cloning project repos. ```hcl resource "coder_agent" "coder" { @@ -113,9 +109,16 @@ resource "coder_agent" "coder" { #!/bin/bash # install code-server -curl -fsSL https://code-server.dev/install.sh | sh +curl -fsSL https://code-server.dev/install.sh | sh + +# The & prevents the startup_script from blocking so the +# next commands can run. code-server --auth none --port & +# var.repo and var.dotfiles_uri is specified +# elsewhere in the Terraform code as input +# variables. + # clone repo ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts git clone --progress git@github.com:${var.repo} @@ -123,17 +126,10 @@ git clone --progress git@github.com:${var.repo} # use coder CLI to clone and install dotfiles coder dotfiles -y ${var.dotfiles_uri} - EOT + EOT } ``` -#### Logging - -The output of the `startup_script` are located in -`/tmp/coder-startup-script.log` within the workspace. - -The Coder agent log is located in `/tmp/coder-agent.log` within the workspace. - ### Parameters Templates often contain _parameters_. These are defined by `variable` blocks in diff --git a/docs/workspaces.md b/docs/workspaces.md index 46dfb5435f5a6..2f38882d20ef4 100644 --- a/docs/workspaces.md +++ b/docs/workspaces.md @@ -49,6 +49,15 @@ The workspace will be stopped and started: coder update ``` +## Logging + +Coder stores MacOS and Linux logs at the following locations: + +| Service | Location | +| ---------------- | ------------------------------- | +| `startup_script` | `/tmp/coder-startup-script.log` | +| Agent | `/tmp/coder-agent.log` | + --- ## Up next From 8fea7d54f5a46b16b3cc895f7c1b62bba6a8091b Mon Sep 17 00:00:00 2001 From: Ammar Bandukwala Date: Sun, 31 Jul 2022 19:58:18 +0000 Subject: [PATCH 2/2] Fix issues in #3320 --- docs/ides.md | 2 - docs/ides/configuring-gateway.md | 81 ++++++++++++-------------------- docs/manifest.json | 4 +- 3 files changed, 32 insertions(+), 55 deletions(-) diff --git a/docs/ides.md b/docs/ides.md index 3faff22ddd289..5fa9fb9544600 100644 --- a/docs/ides.md +++ b/docs/ides.md @@ -4,9 +4,7 @@ The following desktop IDEs have been tested with Coder, though any IDE with SSH support should work: - [VS Code Remote SSH](#vs-code-remote) - extension) - [JetBrains with Gateway](./ides/configuring-gateway.md) - installed) - IntelliJ IDEA - CLion - GoLand diff --git a/docs/ides/configuring-gateway.md b/docs/ides/configuring-gateway.md index fd46198e47f61..a910d33c41e77 100644 --- a/docs/ides/configuring-gateway.md +++ b/docs/ides/configuring-gateway.md @@ -1,57 +1,36 @@ # Configuring JetBrains Gateway -The following screenshots outline in more detail how to create a new Connection -for JetBrains Gateway to a Coder workspace. +The following walkthrough details how to connect JetBrains Gateway to +Coder. ## Creating a new JetBrains Gateway Connection -After installing Gateway on your local system, you may connect to a Coder -workspace as follows - +1. [Install Gateway](https://www.jetbrains.com/help/idea/jetbrains-gateway.html) +1. [Configure the `coder` CLI](../ides.md#ssh-configuration) 1. Open Gateway, make sure "SSH" is selected under "Remote Development" -2. Click "New Connection" - -![Gateway Home](../images/gateway/gateway-home.png) - -3. In the resulting dialog, click the gear icon to the right of "Connection:" - -![Gateway New Connection](../images/gateway/gateway-new-connection.png) - -4. Hit the "+" button to add a new SSH connection - -![Gateway Add Connection](../images/gateway/gateway-add-ssh-configuration.png) - - 1. For the Host, enter `coder.` - 2. For the Port, enter `22` (this is ignored by Coder) - 3. For the Username, enter `coder` - 4. For the Authentication Type, select "OpenSSH config and authentication - agent" - 5. Make sure the checkbox for "Parse config file ~/.ssh/config" is checked. - 6. Click "Test Connection" to ensure you setting are ok. - 7. Click "OK" - -![Gateway SSH -Configuration](../images/gateway/gateway-create-ssh-configuration.png) - -5. Select the connection you just added. - -![Gateway Welcome](../images/gateway/gateway-welcome.png) - -6. Click "Check Connection and Continue" - -![Gateway Continue](../images/gateway/gateway-continue.png) - -7. Select the JetBrains IDE for your project and the project directory - 1. Use an SSH terminal to your workspace to create a directory or check out - code if you haven't already. - -> Note the JetBrains IDE is installed in the directory `~/. -> cache/JetBrains/RemoteDev/dist` - -![Gateway Choose IDE](../images/gateway/gateway-choose-ide.png) - -8. Click "Download and Start IDE" to connect. - -![Gateway IDE Opened](../images/gateway/gateway-intellij-opened.png) - - +1. Click "New Connection" + ![Gateway Home](../images/gateway/gateway-home.png) +1. In the resulting dialog, click the gear icon to the right of "Connection:" + ![Gateway New Connection](../images/gateway/gateway-new-connection.png) +1. Hit the "+" button to add a new SSH connection + ![Gateway Add Connection](../images/gateway/gateway-add-ssh-configuration.png) + +1. For the Host, enter `coder.` +1. For the Port, enter `22` (this is ignored by Coder) +1. For the Username, enter `coder` +1. For the Authentication Type, select "OpenSSH config and authentication + agent" +1. Make sure the checkbox for "Parse config file ~/.ssh/config" is checked. +1. Click "Test Connection" to validate these settings. +1. Click "OK" + ![Gateway SSH Configuration](../images/gateway/gateway-create-ssh-configuration.png) +1. Select the connection you just added + ![Gateway Welcome](../images/gateway/gateway-welcome.png) +1. Click "Check Connection and Continue" + ![Gateway Continue](../images/gateway/gateway-continue.png) +1. Select the JetBrains IDE for your project and the project directory. + SSH into your server to create a directory or check out code if you haven't already. + ![Gateway Choose IDE](../images/gateway/gateway-choose-ide.png) + > Note the JetBrains IDE is remotely installed into `~/. cache/JetBrains/RemoteDev/dist` +1. Click "Download and Start IDE" to connect. + ![Gateway IDE Opened](../images/gateway/gateway-intellij-opened.png) diff --git a/docs/manifest.json b/docs/manifest.json index 0bebc1b8d58b4..8d4e73767e636 100644 --- a/docs/manifest.json +++ b/docs/manifest.json @@ -83,8 +83,8 @@ "path": "./ides/configuring-web-ides.md" }, { - "title": "Configuring Jetbrains Gateway", - "description": "Learn how to configure Jetbrains Gateway for your workspaces", + "title": "Configuring JetBrains Gateway", + "description": "Learn how to configure JetBrains Gateway for your workspaces", "path": "./ides/configuring-gateway.md" } ] pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy