This repository has been archived on 2024-04-06. You can view files and clone it, but cannot push or open issues or pull requests.
core-old/.drone.yml

187 lines
3.4 KiB
YAML
Raw Normal View History

2022-07-24 12:06:31 +00:00
---
kind: pipeline
type: docker
name: test
steps:
- name: test
2023-02-02 05:52:00 +00:00
image: golang:1.20
2022-10-14 05:41:26 +00:00
environment:
TESTS_DB_DSN: postgres://postgres:twhelp@database:5432/twhelp?sslmode=disable
TESTS_AMQP_URI: amqp://twhelp:twhelp@rmq:5672/
2022-07-24 12:06:31 +00:00
commands:
- make generate
2022-07-24 12:06:31 +00:00
- go test -race -coverprofile=coverage.txt -covermode=atomic ./...
services:
- name: database
image: postgres:14.7
environment:
POSTGRES_DB: twhelp
POSTGRES_PASSWORD: twhelp
- name: rmq
image: rabbitmq:3.11.9-alpine
environment:
RABBITMQ_DEFAULT_USER: twhelp
RABBITMQ_DEFAULT_PASS: twhelp
2022-07-24 12:06:31 +00:00
trigger:
event:
- push
- pull_request
branch:
- master
---
kind: pipeline
type: docker
name: check-go-mod
steps:
2022-10-14 05:41:26 +00:00
- name: go.mod
2023-02-02 05:52:00 +00:00
image: golang:1.20
2022-07-24 12:06:31 +00:00
commands:
- make generate
2022-07-24 12:06:31 +00:00
- go mod tidy
- git diff --exit-code go.mod
trigger:
event:
- push
- pull_request
branch:
- master
---
kind: pipeline
type: docker
name: golangci-lint
steps:
- name: golangci-lint
2023-03-21 04:37:43 +00:00
image: golangci/golangci-lint:v1.52
2022-07-24 12:06:31 +00:00
commands:
- make generate
2022-07-24 12:06:31 +00:00
- golangci-lint run
trigger:
event:
- push
- pull_request
branch:
- master
2022-12-04 07:57:16 +00:00
---
kind: pipeline
type: docker
name: govulncheck
platform:
os: linux
arch: amd64
steps:
- name: govulncheck
2023-02-02 05:52:00 +00:00
image: golang:1.20
2022-12-04 07:57:16 +00:00
commands:
- make generate
- go install golang.org/x/vuln/cmd/govulncheck@latest
- govulncheck ./...
trigger:
event:
- cron
cron:
- govulncheck
---
kind: pipeline
type: docker
name: linux-amd64
platform:
os: linux
arch: amd64
steps:
- name: publish
image: plugins/docker
settings:
username:
from_secret: docker_username
password:
from_secret: docker_password
registry: gitea.dwysokinski.me
repo: gitea.dwysokinski.me/twhelp-packages/core
auto_tag: true
auto_tag_suffix: linux-amd64
dockerfile: ./build/docker/twhelp/prod/Dockerfile
build_args_from_env: [DRONE_TAG]
trigger:
event:
- tag
---
kind: pipeline
type: docker
name: manifest
steps:
- name: manifest
image: plugins/manifest
settings:
auto_tag: "true"
ignore_missing: "true"
spec: ./build/docker/twhelp/prod/manifest.tmpl
username:
from_secret: docker_username
password:
from_secret: docker_password
- name: manifest-latest
image: plugins/manifest
settings:
tags: latest
ignore_missing: "true"
spec: ./build/docker/twhelp/prod/manifest.tmpl
username:
from_secret: docker_username
password:
from_secret: docker_password
trigger:
event:
- tag
depends_on:
- linux-amd64
---
kind: pipeline
type: docker
name: deploy
steps:
- name: deploy-k8s
image: alpine/k8s:1.25.6
environment:
KUBECONFIG:
from_secret: kubeconfig
commands:
- "mkdir ~/.kube && echo \"$KUBECONFIG\" > ~/.kube/twhelp"
- "cd ./k8s/overlays/prod && kustomize edit set image twhelp=gitea.dwysokinski.me/twhelp-packages/core:${DRONE_TAG##v} && cd ../../.."
- "kubectl --kubeconfig ~/.kube/twhelp -n twhelp delete jobs.batch twhelp-migrations-job || true"
2022-09-30 06:17:55 +00:00
- kustomize build ./k8s/overlays/prod | kubectl --kubeconfig ~/.kube/twhelp apply -n twhelp -f -
trigger:
event:
- tag
depends_on:
- manifest
---
kind: signature
2023-03-21 04:37:43 +00:00
hmac: fa9b0512365e2a37ef267087213035caa8c4163312bb0656e016fc71a35bd221
chore(deps): update module github.com/riandyrn/otelchi to v0.5.0 (#90) This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [github.com/riandyrn/otelchi](https://github.com/riandyrn/otelchi) | require | minor | `v0.4.0` -> `v0.5.0` | --- ### ⚠ Dependency Lookup Warnings ⚠ Warnings were logged while processing this repo. Please check the Dependency Dashboard for more information. --- ### Release Notes <details> <summary>riandyrn/otelchi</summary> ### [`v0.5.0`](https://github.com/riandyrn/otelchi/releases/tag/v0.5.0) [Compare Source](https://github.com/riandyrn/otelchi/compare/v0.4.0...v0.5.0) #### What's Changed - Feat: Add option [`WithFilter`](https://github.com/riandyrn/otelchi/blob/master/config.go#L75-L82) to ignore tracing in certain endpoints as described in [#&#8203;10](https://github.com/riandyrn/otelchi/issues/10). Contributed by [@&#8203;hsblhsn](https://github.com/hsblhsn). - Docs: Add multi services example to make it easy for people to get started using `otelchi`. **Full Changelog**: https://github.com/riandyrn/otelchi/compare/v0.4.0...v0.5.0 </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzMi4yMDEuMSIsInVwZGF0ZWRJblZlciI6IjMyLjIwMS4xIn0=--> Co-authored-by: Renovate <renovate@dwysokinski.me> Co-authored-by: Dawid Wysokiński <contact@dwysokinski.me> Reviewed-on: https://gitea.dwysokinski.me/twhelp/core/pulls/90 Co-authored-by: renovate <renovate@noreply.localhost> Co-committed-by: renovate <renovate@noreply.localhost>
2022-10-06 12:58:03 +00:00
...