Live Preview your App in OneDev Pull Request

OneDev is a self-hosted DevOps platform with issue tracking, git repository management and built-in CI/CD capabilities. In the latest 4.2.1 version, it is possible to set up pull request to launch live preview of your application and tear it down after pull request is closed.

For demonstration purpose, I set up a Heroku starter application in OneDev, when a pull request is created, the application will be deployed to Heroku, and a link of the deployment will be displayed for reviewers to check like below:


Annotate source with Jest/ESLint information in OneDev

OneDev is an open source self-hosted DevOps platform, with ability to manage your git repositories, as well as running CI/CD jobs in docker containers.

The recent version can leverage your projects’s Jest/ESLint integration to:

  1. Annotate source code with Jest coverage and ESLint violations when view files or pull request changes
  2. Generate statistics of relevant metrics over time

OneDev is an open source GitLab-like devops platform emphasizing easy-of-use. Jest is a popular javascript testing framework. This tutorial explains how to set up OneDev to publish Jest test report in a CI process.

Run OneDev

Run below command in your terminal on Linux/Mac to start OneDev:

$ docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock -v $(pwd)/onedev:/opt/onedev -p 6610:6610 -p 6611:6611 1dev/server:4.1.2

Add a Demo Project

Now add a project in OneDev using Jest test framework, and push the code. For demonstration purpose, let’s use the react project


Introduction

GitOps is a DevOps approach to maintain Kubernetes-based infrastructure as code in git, and operate it with git tools such as push, revert, pull request.

OneDev (https://github.com/theonedev/onedev) is an open source git repository server, with built-in CI/CD integration.

This tutorial explains how to set up OneDev to do GitOps in Kubernetes.

Set Up Kubernetes Cluster

Firstable we need a Kubernetes cluster. You may use an existing one, or just set up a new one. For this tutorial, we chose to use GKE (Google Kubernetes Engine).

Just follow the quick start to create a cluster. To save your money, the default pool with only one…


OneDev is an open source all-in-one devops platform with the ability to manage git repositories, manage issues, and run continuous integrations. The project is hosted at github.com/theonedev/onedev.

docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock -v $(pwd)/onedev:/opt/onedev -p 6610:6610 -p 6611:6611 1dev/server

3. From OneDev projects page, add a project my-app

4. Run below command from your terminal to create a react application:

npx create-react-app my-app

OneDev: Self-Hosted All-in-One DevOps Platform

Would like to introduce OneDev, an open source DevOps platform featuring git repository management with code intelligence, issue management with customizable workflow, and a continuous integration engine with first-class support for Docker and Kubernetes.

It is super easy to install and manage. More info, please check https://github.com/theonedev/onedev

Robin Shen

Full stack developer. OneDev maintainer.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store