Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/opnlabs/dot
A minimal continuous integration system. Uses docker to run jobs concurrently in stages.
https://github.com/opnlabs/dot
Last synced: 14 days ago
JSON representation
A minimal continuous integration system. Uses docker to run jobs concurrently in stages.
- Host: GitHub
- URL: https://github.com/opnlabs/dot
- Owner: opnlabs
- License: mit
- Created: 2023-10-26T17:32:35.000Z (about 1 year ago)
- Default Branch: master
- Last Pushed: 2024-07-30T10:22:26.000Z (3 months ago)
- Last Synced: 2024-07-31T20:45:20.658Z (3 months ago)
- Language: Go
- Homepage:
- Size: 7.66 MB
- Stars: 15
- Watchers: 1
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-go - dot - A minimal, local first continuous integration system that uses Docker to run jobs concurrently in stages. (Continuous Integration / Standard CLI)
- fucking-awesome-go - dot - A minimal, local first continuous integration system that uses Docker to run jobs concurrently in stages. (Continuous Integration / Standard CLI)
- awesome-go - dot - A minimal, local first continuous integration system that uses Docker to run jobs concurrently in stages. (Continuous Integration / Standard CLI)
- awesome-go-with-stars - dot - A minimal, local first continuous integration system that uses Docker to run jobs concurrently in stages. (Continuous Integration / Standard CLI)
- awesome-go-plus - dot - A minimal, local first continuous integration system that uses Docker to run jobs concurrently in stages. (Continuous Integration / Standard CLI)
- awesome-go-plus - dot - A minimal, local first continuous integration system that uses Docker to run jobs concurrently in stages. ![stars](https://img.shields.io/badge/stars-23-blue) ![forks](https://img.shields.io/badge/forks-0-blue) (Continuous Integration / Standard CLI)
README
# Dot
[![Go Reference](https://pkg.go.dev/badge/github.com/opnlabs/dot.svg)](https://pkg.go.dev/github.com/opnlabs/dot) [![Dot](https://github.com/opnlabs/dot/actions/workflows/main.yml/badge.svg)](https://github.com/opnlabs/dot/actions/workflows/main.yml) [![Go Report Card](https://goreportcard.com/badge/github.com/cvhariharan/dot)](https://goreportcard.com/report/github.com/cvhariharan/dot) [![Codacy Badge](https://app.codacy.com/project/badge/Coverage/1a5800bae3c143c29e3559e3f46bffb1)](https://app.codacy.com/gh/opnlabs/dot/dashboard?utm_source=gh&utm_medium=referral&utm_content=&utm_campaign=Badge_coverage)A minimal CI. Designed to be local first.
All the jobs run inside docker containers. `Dot` communicates with the Docker daemon using the [Docker client API](https://pkg.go.dev/github.com/docker/docker/client#section-readme).
Refer the project [wiki](https://github.com/opnlabs/dot/wiki) to learn more about dot.
## Features
- Single binary, can run anywhere, on your machine or CI/CD systems
- Multi stage builds with support for build artifacts
- Simple yaml job definition
- Bring your own Docker images. Supports private registries
- Uses plain Docker
- Supports conditional evaluation using expressions## Installation
Get the latest version from the [releases](https://github.com/opnlabs/dot/releases) section.The latest version can also be installed using `go`.
```bash
go install github.com/opnlabs/dot@latest
```### Run using Docker
```bash
docker run -it -v /var/run/docker.sock:/var/run/docker.sock -v /path/to/project:/app ghcr.io/opnlabs/dot:latest -m
```## Example
This example uses [GoReleaser](https://github.com/goreleaser/goreleaser) to build this project.
```yaml
stages:
- test
- security
- buildjobs:
- name: Run tests
stage: test
image: "docker.io/golang:1.21.3"
variables:
- TEST: true
script:
- go test ./...
condition: TEST- name: Run checks
stage: security
image: "docker.io/golangci/golangci-lint:latest"
script:
- golangci-lint run ./...- name: Build using Goreleaser
stage: build
image: "docker.io/golang:1.21.3-bookworm"
script:
- git config --global safe.directory '*'
- curl -sfL https://goreleaser.com/static/run | bash -s -- build --snapshot
artifacts:
- dist
```
Extract the binary once the build is complete.
```
tar xvf .artifacts/artifacts-*.tar
dist/dot_linux_amd64_v1/dot version
```
### Build Dot with Dot
This project can be built with `Dot`. The [dot.yml](dot.yml) file describes all the jobs necessary to build a linux binary. Clone the repo and run```bash
go run main.go -m
```
This should create an artifact tar file in the `.artifacts` directory with the linux binary `dot`.
The `-m` flag gives `dot` access to the host's docker socket. This is required only if containers are created within `dot`.