You've already forked go-semantic-release
fix(ci): Updated architecture types to align docker image. #10
10
.release.yml
10
.release.yml
@@ -8,15 +8,15 @@ branch:
|
|||||||
master: release
|
master: release
|
||||||
develop: beta
|
develop: beta
|
||||||
assets:
|
assets:
|
||||||
- name: ./build/go-semantic-release.linux_x86_64
|
- path: ./build/go-semantic-release.linux_amd64
|
||||||
compress: true
|
compress: true
|
||||||
- name: ./build/go-semantic-release.linux_arm64
|
- path: ./build/go-semantic-release.linux_arm64
|
||||||
compress: true
|
compress: true
|
||||||
- name: ./build/go-semantic-release.windows_i386.exe
|
- path: ./build/go-semantic-release.windows_i386.exe
|
||||||
compress: true
|
compress: true
|
||||||
- name: ./build/go-semantic-release.windows_x86_64.exe
|
- path: ./build/go-semantic-release.windows_amd64.exe
|
||||||
compress: true
|
compress: true
|
||||||
- name: ./build/go-semantic-release.darwin_x86_64
|
- path: ./build/go-semantic-release.darwin_amd64
|
||||||
compress: true
|
compress: true
|
||||||
changelog:
|
changelog:
|
||||||
docker:
|
docker:
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ steps:
|
|||||||
GOOS=linux
|
GOOS=linux
|
||||||
GOARCH=amd64
|
GOARCH=amd64
|
||||||
CGO_ENABLED=0
|
CGO_ENABLED=0
|
||||||
go build -o build/go-semantic-release.linux_x86_64 -ldflags "-w -s --X main.version=`go-semantic-release next`"
|
go build -o build/go-semantic-release.linux_amd64 -ldflags "-w -s --X main.version=`go-semantic-release next`"
|
||||||
./cmd/go-semantic-release/
|
./cmd/go-semantic-release/
|
||||||
- >
|
- >
|
||||||
GOOS=linux
|
GOOS=linux
|
||||||
@@ -44,13 +44,13 @@ steps:
|
|||||||
GOOS=windows
|
GOOS=windows
|
||||||
GOARCH=amd64
|
GOARCH=amd64
|
||||||
CGO_ENABLED=0
|
CGO_ENABLED=0
|
||||||
go build -o build/go-semantic-release.windows_x86_64.exe -ldflags "-w -s -X main.version=`go-semantic-release next`"
|
go build -o build/go-semantic-release.windows_amd64.exe -ldflags "-w -s -X main.version=`go-semantic-release next`"
|
||||||
./cmd/go-semantic-release/
|
./cmd/go-semantic-release/
|
||||||
- >
|
- >
|
||||||
GOOS=darwin
|
GOOS=darwin
|
||||||
GOARCH=amd64
|
GOARCH=amd64
|
||||||
CGO_ENABLED=0
|
CGO_ENABLED=0
|
||||||
go build -o build/go-semantic-release.darwin_x86_64 -ldflags "-w -s -X main.version=`go-semantic-release next`"
|
go build -o build/go-semantic-release.darwin_amd64 -ldflags "-w -s -X main.version=`go-semantic-release next`"
|
||||||
./cmd/go-semantic-release/
|
./cmd/go-semantic-release/
|
||||||
- go-semantic-release --loglevel debug release # Actually make the release on Gitea. Uploading assets
|
- go-semantic-release --loglevel debug release # Actually make the release on Gitea. Uploading assets
|
||||||
environment:
|
environment:
|
||||||
@@ -64,25 +64,25 @@ steps:
|
|||||||
- push
|
- push
|
||||||
- manual
|
- manual
|
||||||
|
|
||||||
# publish-docker-tagged:
|
publish-docker-tagged:
|
||||||
# image: docker.io/cybercinch/woodpecker-plugin-depot
|
image: docker.io/cybercinch/woodpecker-plugin-depot
|
||||||
# pull: true
|
pull: true
|
||||||
# settings:
|
settings:
|
||||||
# <<: *docker_creds
|
<<: *docker_creds
|
||||||
# token:
|
token:
|
||||||
# from_secret: depot_token
|
from_secret: depot_token
|
||||||
# repohost: hub.cybercinch.nz
|
repohost: hub.cybercinch.nz
|
||||||
# repo: cybercinch/${CI_REPO_NAME}
|
repo: cybercinch/${CI_REPO_NAME}
|
||||||
# project:
|
project:
|
||||||
# from_secret: depot_project
|
from_secret: depot_project
|
||||||
# dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
# push: true
|
push: true
|
||||||
# platforms: *platforms
|
platforms: *platforms
|
||||||
# tags: ["latest", "$CI_COMMIT_TAG"]
|
tags: ["latest", "$CI_COMMIT_TAG"]
|
||||||
# when:
|
when:
|
||||||
# branch: ${CI_REPO_DEFAULT_BRANCH}
|
branch: ${CI_REPO_DEFAULT_BRANCH}
|
||||||
# event:
|
event:
|
||||||
# - tag
|
- tag
|
||||||
|
|
||||||
publish-docker-develop:
|
publish-docker-develop:
|
||||||
image: docker.io/cybercinch/woodpecker-plugin-depot
|
image: docker.io/cybercinch/woodpecker-plugin-depot
|
||||||
|
|||||||
19
Dockerfile
19
Dockerfile
@@ -1,20 +1,13 @@
|
|||||||
FROM golang:1.20
|
|
||||||
|
|
||||||
WORKDIR /code
|
|
||||||
|
|
||||||
COPY . /code/
|
|
||||||
|
|
||||||
RUN GOOS=linux \
|
|
||||||
GOARCH=amd64 \
|
|
||||||
CGO_ENABLED=0 \
|
|
||||||
go build -o build/go-semantic-release.linux_x86_64 -ldflags "-w -s --X main.version=`go-semantic-release next`" \
|
|
||||||
./cmd/go-semantic-release/
|
|
||||||
|
|
||||||
FROM alpine:3.14
|
FROM alpine:3.14
|
||||||
|
ARG TARGETPLATFORM
|
||||||
|
ARG TAG=v2.2.3
|
||||||
|
|
||||||
WORKDIR /code
|
WORKDIR /code
|
||||||
|
|
||||||
COPY ./build/go-semantic-release.linux_x86_64 /usr/local/bin/go-semantic-release
|
ADD https://hub.cybercinch.nz/cybercinch/go-semantic-release/releases/download/${TAG}/go-semantic-release.linux_${TARGETPLATFORM//"linux/"/}.zip /tmp
|
||||||
|
RUN unzip /tmp/go-semantic-release.linux_${TARGETPLATFORM//"linux/"/}.zip && \
|
||||||
|
mv /tmp/go-semantic-release.linux_${TARGETPLATFORM//"linux/"/} /usr/local/bin/go-semantic-release && \
|
||||||
|
rm -f /tmp/go-semantic-release.linux_${TARGETPLATFORM//"linux/"/}.zip
|
||||||
|
|
||||||
USER 1000
|
USER 1000
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user