Chapter 1. Get started with OpenShift Dev Spaces


Start a new workspace from a Git repository, manage running workspaces, and authenticate to a Git server.

OpenShift Dev Spaces creates cloud development environments from any Git repository. Open a repository URL in OpenShift Dev Spaces to launch a workspace with the project code, tools, and dependencies defined in a devfile.

1.1. Start a workspace from a Git repository URL

Start a new OpenShift Dev Spaces workspace with cloned source code by using a Git repository URL, so that you can begin developing immediately without manual repository setup.

Prerequisites

Procedure

  1. Optional: Visit your OpenShift Dev Spaces dashboard pages to authenticate to your organization’s instance of OpenShift Dev Spaces.
  2. Enter the URL in your browser or in the Git Repository URL field on the Create Workspace page to start a new workspace:

    https://<openshift_dev_spaces_fqdn>#<git_repository_url>

    To append optional parameters, add ?<optional_parameters> to the URL. See Chapter 2, Optional parameters for the URLs for starting a new workspace for supported parameters.

    For example:

    • https://<openshift_dev_spaces_fqdn>#https://github.com/che-samples/cpp-hello-world
    • https://<openshift_dev_spaces_fqdn>#git@github.com:che-samples/cpp-hello-world.git

      URL syntax per Git provider:

      Expand
      Table 1.1. GitHub
      URL pattern

      Default branch: https://<openshift_dev_spaces_fqdn>#https://<github_host>/<user_or_org>/<repository>

      Specified branch: https://<openshift_dev_spaces_fqdn>#https://<github_host>/<user_or_org>/<repository>/tree/<branch_name>

      Pull request branch: https://<openshift_dev_spaces_fqdn>#https://<github_host>/<user_or_org>/<repository>/pull/<pull_request_id>

      Git+SSH: https://<openshift_dev_spaces_fqdn>#git@<github_host>:<user_or_org>/<repository>.git

      For GitHub, you can also use a URL of a directory containing a devfile, or a direct URL to the devfile. The devfile name must be devfile.yaml or .devfile.yaml. Other Git providers do not support this feature.

      Expand
      Table 1.2. GitLab
      URL pattern

      Default branch: https://<openshift_dev_spaces_fqdn>#https://<gitlab_host>/<user_or_org>/<repository>

      Specified branch: https://<openshift_dev_spaces_fqdn>#https://<gitlab_host>/<user_or_org>/<repository>/-/tree/<branch_name>

      Git+SSH: https://<openshift_dev_spaces_fqdn>#git@<gitlab_host>:<user_or_org>/<repository>.git

      Expand
      Table 1.3. Bitbucket Server
      URL pattern

      Default branch: https://<openshift_dev_spaces_fqdn>#https://<bb_host>/scm/<project-key>/<repository>.git

      Default branch (user profile repository): https://<openshift_dev_spaces_fqdn>#https://<bb_host>/users/<user_slug>/repos/<repository>/

      Specified branch: https://<openshift_dev_spaces_fqdn>#https://<bb_host>/users/<user-slug>/repos/<repository>/browse?at=refs%2Fheads%2F<branch-name>

      Git+SSH: https://<openshift_dev_spaces_fqdn>#git@<bb_host>:<user_slug>/<repository>.git

      Expand
      Table 1.4. Microsoft Azure DevOps
      URL pattern

      Default branch: https://<openshift_dev_spaces_fqdn>#https://<organization>@dev.azure.com/<organization>/<project>/_git/<repository>

      Specified branch: https://<openshift_dev_spaces_fqdn>#https://<organization>@dev.azure.com/<organization>/<project>/_git/<repository>?version=GB<branch>

      Git+SSH: https://<openshift_dev_spaces_fqdn>#git@ssh.dev.azure.com:v3/<organization>/<project>/<repository>

Verification

  • After you enter the URL to start a new workspace in a browser tab, the workspace starting page appears.
  • When the new workspace is ready, the workspace IDE loads in the browser tab.
  • A clone of the Git repository is present in the filesystem of the new workspace.
  • The workspace has a unique URL: https://<openshift_dev_spaces_fqdn>/<user_name>/<unique_url>.

1.2. Start a workspace from a raw devfile URL

Start a new OpenShift Dev Spaces workspace from a devfile URL. Open the URL in your browser or enter it in the Git Repo URL field on the Create Workspace page.

Prerequisites

  • You have a running instance of OpenShift Dev Spaces.
  • You know the Fully Qualified Domain Name (FQDN) URL of your organization’s OpenShift Dev Spaces instance: https://<openshift_dev_spaces_fqdn>.
  • The devfile contains project info to clone the Git repository into the workspace filesystem. See https://devfile.io/docs/2.2.0/adding-projects.

Procedure

  1. Optional: Visit your OpenShift Dev Spaces dashboard pages to authenticate to your organization’s instance of OpenShift Dev Spaces.
  2. Enter the devfile URL in your browser to start a new workspace.

    For a public repository:

    https://<openshift_dev_spaces_fqdn>#<devfile_url>

    For a private repository, include your personal access token in the URL:

    https://<openshift_dev_spaces_fqdn>#https://<token>@<host>/<path_to_devfile>

    where:

    <token>

    Your personal access token that you generated on the Git provider’s website. This method works for GitHub, GitLab, Bitbucket, Microsoft Azure, and other providers that support Personal Access Token.

    Important

    Automated Git credential injection does not work with token-embedded URLs. To configure Git credentials separately, see Section 7.6, “Use a Git provider access token”.

    To append optional parameters, add ?<optional_parameters> to the URL. See Chapter 2, Optional parameters for the URLs for starting a new workspace for supported parameters.

    For example:

    • Public repository: https://<openshift_dev_spaces_fqdn>#https://raw.githubusercontent.com/che-samples/cpp-hello-world/main/devfile.yaml
    • Private repository: https://<openshift_dev_spaces_fqdn>#https://<token>@raw.githubusercontent.com/che-samples/cpp-hello-world/main/devfile.yaml

Verification

After you enter the URL to start a new workspace in a browser tab, the workspace starting page appears. When the new workspace is ready, the workspace IDE loads in the browser tab.

+ The workspace has a unique URL: https://<openshift_dev_spaces_fqdn>/<user_name>/<unique_url>.

1.3. Basic actions you can perform on a workspace

You manage your workspaces and verify their current states in the Workspaces page (https://<openshift_dev_spaces_fqdn>/dashboard/#/workspaces) of your OpenShift Dev Spaces dashboard.

After you start a new workspace, you can perform the following actions on it in the Workspaces page:

Expand
Table 1.5. Basic actions you can perform on a workspace
ActionGUI steps in the Workspaces page

Reopen a running workspace

Click Open.

Restart a running workspace

Go to > Restart Workspace.

Stop a running workspace

Go to > Stop Workspace.

Start a stopped workspace

Click Open.

Delete a workspace

Go to > Delete Workspace.

1.4. Git server authentication from a workspace

OpenShift Dev Spaces workspaces support authenticated Git operations such as cloning private repositories and pushing to remote repositories. Administrators and users configure authentication to ensure seamless access to Git servers from workspaces.

User authentication to a Git server from a workspace is configured by the administrator or, in some cases, by the individual user:

  • Your administrator configures an OAuth application on GitHub, GitLab, Bitbucket, or Microsoft Azure Repos for your Red Hat OpenShift Dev Spaces instance.
  • As a workaround, some users create their own Kubernetes Secrets for personal Git-provider access tokens or configure SSH keys.
Red Hat logoGithubredditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat Documentation

Legal Notice

Theme

© 2026 Red Hat
Back to top