Five minutes to try a lightweight alternative to onedev – gitlab

Time:2021-1-18

After one year’s efforts, onedev 3.0 was finally released. This version adds a continuous integration engine and supports docker and kubernetes. It can be said that it can replace the bulky gitlab in most cases. The project is open source. At present, in GitHub:
https://github.com/theonedev/onedev

Onedev is designed to make simple things extremely simple and complex things possible. The function of the project website is introduced in detail. At present, there is only English version, and the support of Chinese version is the next step.

Let’s get down to business. Let’s try onedev for no more than five minutes (assuming your network speed is OK, don’t download docker image too slowly)

  1. Run the following command on Linux or Mac OS X:
    docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock -v $(which docker):/usr/bin/docker -v $(pwd)/onedev:/opt/onedev -p 6610:6610 1dev/server
  2. Open browser to accesshttp://localhost:6610And follow the prompts to configure onedev
  3. Add a project my app
  4. From the command line, run the following command to create a react based sample project my app:
    npx create-react-app my-app
  5. Enter the directory my app and run the following command to push the code to onedev:

    git remote add origin http://localhost:6610/projects/my-app
    git push origin master:master

    When prompted for user name and password, enter the previously created administrator account

  6. Visit the project my app from onedev and click the link on the files pageadd build specThe edit interface of build spec is displayed. For typical projects, onedev will provide task templates, as shown in the following figure:
    Five minutes to try a lightweight alternative to onedev - gitlab
  7. Here we directly use the default template, save the build spec, and then you can see a CI build running automatically
    Five minutes to try a lightweight alternative to onedev - gitlab

Recommended Today

MySQL partition

MySQL partition Advantages of partitioning Store more data To optimize the query, only scan one or more necessary partitions. For count () and sum (), only summarize the partition statistics For data that is out of date or does not need to be saved, partitioning is faster Data queries are distributed across multiple disks to […]