ci: add .drone.yml
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
surtur 2022-05-10 23:30:10 +02:00
parent b663f37929
commit 6fe3faa47b
Signed by: wanderer
GPG Key ID: 19CE1EC1D9E0486D
3 changed files with 77 additions and 0 deletions

69
.drone.yml Normal file

@ -0,0 +1,69 @@
---
kind: pipeline
type: docker
name: testing
platform:
os: linux
arch: amd64
steps:
- name: hadolint
pull: always
image: ghcr.io/hadolint/hadolint:v2.10.0-alpine
commands:
- hadolint --version
- hadolint Containerfile
when:
ref:
- refs/heads/development
- refs/heads/feature-**
- refs/pull/**
- refs/tags/**
event:
exclude: [cron]
- name: kaniko-build
pull: always
image: docker.io/immawanderer/drone-kaniko:linux-amd64
settings:
dockerfile: Containerfile
context: .
args:
- BUILD_DATE="$(date -u +"%Y-%m-%dT%H:%M:%SZ")"
- VCS_REF=${DRONE_COMMIT_SHA:0:7}
when:
ref:
- refs/heads/feature-**
- refs/pull/**
- refs/tags/**
event:
exclude: [cron]
- name: kaniko-publish
pull: always
image: docker.io/immawanderer/drone-kaniko:linux-amd64
settings:
dockerfile: Containerfile
context: .
args:
- BUILD_DATE="$(date -u +"%Y-%m-%dT%H:%M:%SZ")"
- VCS_REF=${DRONE_COMMIT_SHA:0:7}
tags:
- latest
- linux-amd64
- ${DRONE_COMMIT_SHA:0:8}
repo: immawanderer/nix-cachix-glibc
username:
from_secret: dh_username
password:
from_secret: dh_token
when:
ref:
- refs/heads/development
event:
exclude: [pull_request, tag]
trigger:
event: [push, pull_request, cron, tag]
...

@ -6,6 +6,13 @@ repos:
hooks: hooks:
- id: check-merge-conflict - id: check-merge-conflict
- id: check-yaml - id: check-yaml
- repo: local
hooks:
# this hook requires that the drone-cli tool is installed
- id: drone-lint
name: drone lint
entry: drone lint .drone.yml
language: system
- repo: https://git.dotya.ml/wanderer/hadolint-pre-commit - repo: https://git.dotya.ml/wanderer/hadolint-pre-commit
rev: v0.0.1 rev: v0.0.1
hooks: hooks:

@ -1,5 +1,6 @@
# nix-cachix-glibc # nix-cachix-glibc
[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)](https://github.com/pre-commit/pre-commit) [![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit&logoColor=white)](https://github.com/pre-commit/pre-commit)
[![Build Status](https://drone.dotya.ml/api/badges/wanderer-containers/nix-cachix-glibc/status.svg)](https://drone.dotya.ml/wanderer-containers/nix-cachix-glibc)
the Containerfile in this repo simply installs `cachix` and `glibc` packages on the Containerfile in this repo simply installs `cachix` and `glibc` packages on
top of the base image, the rationale being this image can be cached for reuse top of the base image, the rationale being this image can be cached for reuse