Skip to content
This repository was archived by the owner on Aug 18, 2025. It is now read-only.
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
Binary file added assets/getting-started/gh-access-token.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified assets/getting-started/view-files.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 1 addition & 2 deletions getting-started/data-scientists.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ workspace capable of supporting data science projects. You'll learn how to:
- Create a workspace with Jupyter Notebook and other data science packages
present;
- Add a sample project to your workspace, specifically
[one as a Jupyter Notebook using IMDB movie data](https://github.com/khorne3/data-science-imdb-sample);
- Create a dev URL and preview changes to your project.
[one as a Jupyter Notebook using IMDB movie data](https://github.com/khorne3/data-science-imdb-sample).

## Prerequisites

Expand Down
60 changes: 46 additions & 14 deletions getting-started/developers.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@ learn how to:

- Connect Coder to your Git provider;
- Create a workspace;
- Add a sample project to your workspace;
- Create a dev URL and preview changes to your project.
- Add [Create React App](https://create-react-app.dev/) to your workspace, which
will allow you to create a sample single-page application that you can modify;
- Create a dev URL and preview changes to your project;
- Push your changes to a GitHub repo.

## Prerequisites

Expand Down Expand Up @@ -75,30 +77,32 @@ next to the name of your workspace.

## Step 3: Add a sample project to your workspace

Once you've created your workspace, you can start using Coder after adding a
sample project to your workspace.
Once you've created your workspace, you can start working in Coder. For this
tutorial, we'll be leveraging the
[Create React App](https://create-react-app.dev/) to get you set up with a way
to create single-page applications.

1. Under **Browser applications**, click **Code Web** to open VS Code in your
browser.

1. When VS Code launches in your browser, click **Open folder...**. In the
prompt, you'll see `/home/coder`. This directory is where you'll clone a
sample React app project Git repository. Click **OK** to proceed.
prompt, you'll see `/home/coder`. This directory is where you'll store your
sample React app project. Click **OK** to proceed.

![Open folder](../assets/getting-started/open-folder.png)

1. Click the hamburger icon in the top right, and select **Terminal** > **New
Terminal** to open a new terminal.

1. Clone the `create-react-app` repository:
1. You're now ready to create a demo app that you can modify:

```console
git clone git@github.com:facebook/create-react-app.git
npx create-react-app my-app
cd my-app
```

Once you've cloned the repository, you can click the **Explorer** icon and
expand the **create-react-app** folder in the left-have nav bar to see the
contents of the repo.
Once done, you can expand the `my-app` folder in the left-have nav bar to see
its contents:

![View files](../assets/getting-started/view-files.png)

Expand Down Expand Up @@ -126,9 +130,7 @@ specified and renders a browser link you can use to view your application.
Web window and running the following in the terminal:

```console
npx create-react-app my-app
cd my-app
npm start
npm start
```

1. From the workspace overview, launch your dev URL by clicking its name; Coder
Expand All @@ -140,3 +142,33 @@ specified and renders a browser link you can use to view your application.
you save your changes to this file, your preview will reload.

![Preview changes](../assets/getting-started/hello-world.png)

## Step 5: Push your repo to GitHub

The follow steps show you how to push your app to a newly created GitHub repo.

1. Log in to GitHub and navigate to
[Create a new repository](https://github.com/new).

1. Provide a **repository name** and click **Create repository**.

1. Return to your workspace, run the following in your terminal to add a remote
to your GitHub repo, change the primary branch name to `main`, and push the
contents to your newly created repo:

```console
git remote add origin https://github.com/<username>/<repoName>.git
git branch -M main
git push origin main
```

1. Within the IDE window (near the top), you'll be prompted to log in to GitHub
by providing your username and password/personal access token.

1. Next, Code Web will display an alert that says the GitHub extension wants to
sign in; click **Allow** to proceed.

1. In the subsequent window, click **Continue** to authorize Visual Studio Code
to access GitHub.

At this point, the contents of your repo should be pushed to GitHub.
57 changes: 40 additions & 17 deletions getting-started/docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@ You'll learn how to:

- Connect Coder to your Git provider;
- Create a workspace;
- Add a sample project to your workspace;
- Create a dev URL and preview changes to your project.
- Add [Create React App](https://create-react-app.dev/) to your workspace, which
will allow you to create a sample single-page application that you can modify;
- Create a dev URL and preview changes to your project;
- Push your changes to a GitHub repo.

## Prerequisites

Expand All @@ -31,13 +33,7 @@ changes.

1. Provide Coder with your SSH key to connect and authenticate to GitHub.

If your site manager has configured OAuth, go to **Linked Accounts** and
follow the on-screen instructions to link your GitHub account.

![Link GitHub account](../assets/getting-started/linked-accounts.png)

If your site manager has _not_ configured OAuth, go to **SSH keys**. Copy
your public SSH key and
Go to **SSH keys**. Copy your public SSH key and
[provide it to GitHub](https://docs.github.com/en/authentication/connecting-to-github-with-ssh/adding-a-new-ssh-key-to-your-github-account).

![Add SSH key](../assets/getting-started/ssh-keys.png)
Expand All @@ -53,7 +49,7 @@ You will now create the workspace where you'll work on your development project.
1. Provide a **Workspace Name**.

1. In the **Image** section, click **Packaged** (this tab contains
Coder-provided images hosted in a Docker registry). Select **Ubuntu**. This
Coder-provided images hosted in a Docker registry). Select **NodeJS**. This
will populate the form in the **Import** tab.

1. Under **Workspace providers**, leave the default option (which is **Docker**)
Expand Down Expand Up @@ -85,15 +81,15 @@ sample project to your workspace.
1. Click the hamburger icon in the top right, and select **Terminal** > **New
Terminal** to open a new terminal.

1. Clone the `create-react-app` repository:
1. You're now ready to create a demo app that you can modify:

```console
git clone git@github.com:facebook/create-react-app.git
npx create-react-app my-app
cd my-app
```

Once you've cloned the repository, you can click the **Explorer** icon and
expand the **create-react-app** folder in the left-have nav bar to see the
contents of the repo.
Once done, you can expand the `my-app` folder in the left-have nav bar to see
its contents:

![View files](../assets/getting-started/view-files.png)

Expand All @@ -118,8 +114,6 @@ specified and renders a browser link you can use to view your application.
Web window and running the following in the terminal:

```console
npx create-react-app my-app
cd my-app
npm start
```

Expand All @@ -133,3 +127,32 @@ specified and renders a browser link you can use to view your application.
preview will update.

![Preview changes](../assets/getting-started/hello-world.png)

## Step 5: Push your repo to GitHub

The follow steps show you how to push your app to a newly created GitHub repo.

1. Log in to GitHub and navigate to
[Create a new repository](https://github.com/new).

1. Provide a **repository name** and click **Create repository**.

1. Return to your workspace, run the following in your terminal to add a remote
to your GitHub repo, change the primary branch name to `main`, and push the
contents to your newly created repo:

```console
git remote add origin https://github.com/<username>/<repoName>.git
git branch -M main
git push origin main
```

1. Next, Code Web will display an alert that says the GitHub extension wants to
sign in; click **Allow** to proceed.

1. Within the IDE window (near the top), you'll be prompted to provide your
GitHub Personal Access token

![GitHub Personal Access Token](../assets/getting-started/gh-access-token.png)]

At this point, the contents of your repo should be pushed to GitHub.