Install coder on almalinux vps and connect workspace to vs codeThis article provides a guide to install Coder on AlmaLinux VPS and connect workspace to VS Code.

What is Coder?

Coder is an open-source cloud development environment (CDE) that you host in your cloud or on-premises. With Coder, you can deploy environments that provide the infrastructure, IDEs, and tools your developers need.

What is VS Code?

Visual Studio Code, commonly referred to as VS Code, is an integrated development environment (IDE) developed by Microsoft for Windows, Linux, macOS and web browsers.

Pre-requisites

Before we discuss how to install Coder on AlmaLinux VPS and connect Workspace to VS Code, be sure you have the following:

Launch 100% ssd almalinux vps from $2. 49/mo!

Install Coder on AlmaLinux VPS and Connect Workspace to VS Code

To install Coder on AlmaLinux VPS and connect workspace to VS Code, follow the steps below:

Install and Start Coder

  1. Login to your VPS via SSH.
  2. Update the server packages:
    sudo dnf update -y
  3. Install Docker:
    sudo dnf install -y yum-utils device-mapper-persistent-data lvm2
    dnf config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
    curl -sSL https://get.docker.com | sh
    sudo dnf install -y docker-ce docker-ce-cli containerd.io
    sudo systemctl start docker
    sudo systemctl enable docker
    

    For more details, visit:

  4. Assign your user to the Docker group:
    sudo usermod -aG docker $USER
  5. Run newgrp to activate the groups changes:
    newgrp docker

    You might need to log out and back in or restart the machine for changes to take effect.

  6. Install Coder:
    curl -L https://coder.com/install.sh | sh
    
    • For standalone binaries, system packages, or other alternate installation methods, refer to the latest release on GitHub.
  7. Start Coder:
    coder server

Configure Coder with a New Workspace

  1. Locate the message in your terminal that reads, View the Web UI: https://<CUSTOM-STRING>.<TUNNEL>.try.coder.app. The server begins to stream logs immediately and you might have to scroll up to find it.
    Coder web ui url
  2. Access the URL in your browser.
  3. On the Welcome to Coder page, enter the information to create an admin user, then select Create account.
    Welcome to coder - create admin user from web ui
  4. On the Workspaces page, select Go to templates to create a new template.
  5. For this guide, use a Docker container. Locate Docker Containers and select Use template.
    Create your first template - docker containers
  6. Give the template a Name that you’ll recognize both in the Coder UI and in command-line calls. The rest of the template details are optional, but will be helpful when you have more templates.
  7. Select Create template.
  8. After the template is ready, select Create Workspace.
  9. Give the workspace a name and select Create Workspace.
  10. Coder starts your new workspace:
    Workspace running
  11. Select VS Code Desktop to install the Coder extension and connect to your Coder workspace.

Using VS Code

After VS Code loads the remote environment, you can select Open Folder to explore directories in the Docker container or work on something new.

To clone an existing repository:

  1. Select Clone Repository and enter the repository URL.
    For example, to clone the Coder repo, enter https://github.com/coder/coder.git.
    Learn more about how to find the repository URL in the GitHub documentation.
  2. Choose the folder to which VS Code should clone the repo. It will be in its own directory within this folder.
    Note that you cannot create a new parent directory in this step.
  3. After VS Code completes the clone, select Open to open the directory.
  4. You are now using VS Code in your Coder environment!

Launch 100% ssd almalinux vps from $2. 49/mo!

Conclusion

You now know how to install Coder on AlmaLinux VPS and connect workspace to VS Code.

Share this:
Avatar of editorial staff

Editorial Staff

Rad Web Hosting is a leading provider of web hosting, Cloud VPS, and Dedicated Servers in Dallas, TX.
lg