Compare commits

...

5 Commits

Author SHA1 Message Date
Antoine Langlois c5c69099dd
add github actions badges 2021-08-03 11:51:46 +02:00
Antoine Langlois 46b2f03636
add github actions 2021-08-02 14:41:48 +02:00
Antoine Langlois 7f9d0cd98d
add go workflow 2021-08-02 12:00:55 +02:00
Antoine Langlois 1720e13cb9
add docker workflow 2021-08-02 12:00:44 +02:00
Antoine Langlois 5353a79536
chore(ci): implement DroneCI [skip ci] 2021-06-28 16:07:20 +02:00
3 changed files with 83 additions and 0 deletions

55
.github/workflows/docker-publish.yml vendored Normal file
View File

@ -0,0 +1,55 @@
name: Docker
on:
push:
# Publish semver tags as releases.
tags: [ 'v*.*.*' ]
env:
# Use docker.io for Docker Hub if empty
REGISTRY: ghcr.io
# github.repository as <account>/<repo>
IMAGE_NAME: ${{ github.repository }}
jobs:
build:
runs-on: self-hosted
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v2
# Login against a Docker registry except on PR
# https://github.com/docker/login-action
- name: Log into registry ${{ env.REGISTRY }}
uses: docker/login-action@v1
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
# Extract metadata (tags, labels) for Docker
# https://github.com/docker/metadata-action
- name: Extract Docker metadata
id: meta
uses: docker/metadata-action@v3
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
tags: |
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
# Build and push Docker image with Buildx (don't push on PR)
# https://github.com/docker/build-push-action
- name: Build and push Docker image
uses: docker/build-push-action@v2
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

25
.github/workflows/go.yml vendored Normal file
View File

@ -0,0 +1,25 @@
name: Go
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: self-hosted
steps:
- uses: actions/checkout@v2
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.15
- name: Build
run: go build -v ./...
- name: Test
run: go test -v ./...

View File

@ -1,3 +1,6 @@
![Test & Build](https://github.com/DataHearth/ddnsclient/actions/workflows/go.yml/badge.svg)
![Docker](https://github.com/DataHearth/ddnsclient/actions/workflows/docker-publish.yml/badge.svg)
# DDNS Client
## How to install DDNS-CLIENT as dependency