From a2c31f1831a82d63014b344380def645a6781397 Mon Sep 17 00:00:00 2001 From: Kazuhiro MUSASHI Date: Sun, 11 Aug 2024 18:44:24 +0900 Subject: [PATCH] Modify `.drone.yml` and `.goreleaser.yml`. --- .drone.yml | 5 +++-- .goreleaser.yml | 42 ++++++++++++++++++++++-------------------- 2 files changed, 25 insertions(+), 22 deletions(-) diff --git a/.drone.yml b/.drone.yml index 8809b48..349dcdd 100644 --- a/.drone.yml +++ b/.drone.yml @@ -20,8 +20,9 @@ steps: commands: - sudo chmod 666 /var/run/docker.sock - - curl -sL https://git.io/goreleaser -o /tmp/goreleaser-download - - chmod +x /tmp/goreleaser-download + - echo 'deb [trusted=yes] https://repo.goreleaser.com/apt/ /' | sudo tee /etc/apt/sources.list.d/goreleaser.list + - sudo apt update + - sudo apt install goreleaser - sudo chown -R circleci:circleci . - /tmp/goreleaser-download release --clean diff --git a/.goreleaser.yml b/.goreleaser.yml index e511935..97a4f26 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -1,15 +1,16 @@ -env: - - CGO_ENABLED=0 +version: 2 before: hooks: - # you may remove this if you don't use vgo - sudo apt update - sudo apt install rpm + - go mod tidy - go mod download + - go generate ./... builds: - - + - env: + - CGO_ENABLED=0 flags: - -trimpath goos: @@ -19,18 +20,7 @@ builds: - amd64 archives: - - - format: zip - -snapshot: - name_template: "{{ .Tag }}-next" - -changelog: - sort: asc - filters: - exclude: - - '^docs:' - - '^test:' + - format: zip nfpms: - @@ -41,7 +31,7 @@ nfpms: # Your app's homepage. # Default is empty. - #homepage: https://example.com/ + homepage: https://blog.kazu634.com/ # Your app's maintainer (probably you). # Default is empty. @@ -58,21 +48,33 @@ release: name: moneyforward disable: false + mode: append gitea_urls: api: https://gitea.kazu634.com/api/v1/ download: https://gitea.kazu634.com +changelog: + sort: asc + filters: + exclude: + - "^docs:" + - "^test:" + use: gitea + dockers: - image_templates: - - reg.kazu634.com/kazu634/{{ .ProjectName }}:{{ .Tag }} - - reg.kazu634.com/kazu634/{{ .ProjectName }}:latest + - reg.kazu634.com/kazu634/{{ .ProjectName }}:{{ .Tag }} + - reg.kazu634.com/kazu634/{{ .ProjectName }}:latest goos: linux goarch: amd64 dockerfile: Dockerfile + skip_push: false + skip_build: false + push_flags: - - --tls-verify=false + - --tls-verify=false