2019-07-08 20:51:44 +08:00
|
|
|
env:
|
|
|
|
- GO111MODULE=on
|
2019-07-12 16:20:44 +08:00
|
|
|
- CGO_ENABLED=0
|
2023-09-08 00:53:17 +08:00
|
|
|
- GITHUB_ORG=knadh
|
|
|
|
- DOCKER_ORG=listmonk
|
2019-07-08 20:51:44 +08:00
|
|
|
|
|
|
|
before:
|
|
|
|
hooks:
|
|
|
|
- make build-frontend
|
|
|
|
|
|
|
|
builds:
|
|
|
|
- binary: listmonk
|
2020-08-09 22:32:43 +08:00
|
|
|
main: ./cmd
|
2019-07-08 20:51:44 +08:00
|
|
|
goos:
|
2023-09-08 00:53:17 +08:00
|
|
|
- linux
|
2019-07-08 20:51:44 +08:00
|
|
|
- windows
|
|
|
|
- darwin
|
2020-10-19 01:18:00 +08:00
|
|
|
- freebsd
|
|
|
|
- openbsd
|
|
|
|
- netbsd
|
2019-07-08 20:51:44 +08:00
|
|
|
goarch:
|
|
|
|
- amd64
|
2023-03-21 20:31:30 +08:00
|
|
|
- arm64
|
|
|
|
- arm
|
|
|
|
goarm:
|
|
|
|
- 6
|
|
|
|
- 7
|
2019-07-08 20:51:44 +08:00
|
|
|
ldflags:
|
2023-07-18 13:46:25 +08:00
|
|
|
- -s -w -X "main.buildString={{ .Tag }} ({{ .ShortCommit }} {{ .Date }}, {{ .Os }}/{{ .Arch }})" -X "main.versionString={{ .Tag }}"
|
2019-07-08 20:51:44 +08:00
|
|
|
|
|
|
|
hooks:
|
|
|
|
# stuff executables with static assets.
|
2021-02-01 18:48:09 +08:00
|
|
|
post: make pack-bin BIN={{ .Path }}
|
2019-07-08 20:51:44 +08:00
|
|
|
|
|
|
|
archives:
|
|
|
|
- format: tar.gz
|
|
|
|
files:
|
|
|
|
- README.md
|
|
|
|
- LICENSE
|
2020-08-09 22:32:43 +08:00
|
|
|
|
2019-07-12 09:54:33 +08:00
|
|
|
dockers:
|
2023-07-18 13:46:25 +08:00
|
|
|
- use: buildx
|
|
|
|
goos: linux
|
2019-07-12 09:54:33 +08:00
|
|
|
goarch: amd64
|
2021-03-19 14:37:24 +08:00
|
|
|
ids:
|
2023-09-08 00:53:17 +08:00
|
|
|
- listmonk
|
2019-07-12 09:54:33 +08:00
|
|
|
image_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:latest-amd64"
|
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:{{ .Tag }}-amd64"
|
|
|
|
- "ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:latest-amd64"
|
|
|
|
- "ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:{{ .Tag }}-amd64"
|
2023-04-12 00:12:41 +08:00
|
|
|
build_flag_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- --platform=linux/amd64
|
|
|
|
- --label=org.opencontainers.image.title={{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.description={{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.url=https://github.com/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.source=https://github.com/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.version={{ .Version }}
|
|
|
|
- --label=org.opencontainers.image.created={{ time "2006-01-02T15:04:05Z07:00" }}
|
|
|
|
- --label=org.opencontainers.image.revision={{ .FullCommit }}
|
|
|
|
- --label=org.opencontainers.image.licenses=AGPL-3.0
|
2019-07-12 09:54:33 +08:00
|
|
|
dockerfile: Dockerfile
|
|
|
|
extra_files:
|
2023-09-08 00:53:17 +08:00
|
|
|
- config.toml.sample
|
2024-07-21 13:33:15 +08:00
|
|
|
- docker-entrypoint.sh
|
2023-07-18 13:46:25 +08:00
|
|
|
- use: buildx
|
|
|
|
goos: linux
|
|
|
|
goarch: arm64
|
|
|
|
ids:
|
2023-09-08 00:53:17 +08:00
|
|
|
- listmonk
|
2023-07-18 13:46:25 +08:00
|
|
|
image_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:latest-arm64v8"
|
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:{{ .Tag }}-arm64v8"
|
|
|
|
- "ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:latest-arm64v8"
|
|
|
|
- "ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:{{ .Tag }}-arm64v8"
|
2023-07-18 13:46:25 +08:00
|
|
|
build_flag_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- --platform=linux/arm64/v8
|
|
|
|
- --label=org.opencontainers.image.title={{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.description={{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.url=https://github.com/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.source=https://github.com/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.version={{ .Version }}
|
|
|
|
- --label=org.opencontainers.image.created={{ time "2006-01-02T15:04:05Z07:00" }}
|
|
|
|
- --label=org.opencontainers.image.revision={{ .FullCommit }}
|
|
|
|
- --label=org.opencontainers.image.licenses=AGPL-3.0
|
2023-07-18 13:46:25 +08:00
|
|
|
dockerfile: Dockerfile
|
|
|
|
extra_files:
|
2023-09-08 00:53:17 +08:00
|
|
|
- config.toml.sample
|
2024-07-21 13:33:15 +08:00
|
|
|
- docker-entrypoint.sh
|
2023-07-18 13:46:25 +08:00
|
|
|
- use: buildx
|
|
|
|
goos: linux
|
|
|
|
goarch: arm
|
|
|
|
goarm: 6
|
|
|
|
ids:
|
2023-09-08 00:53:17 +08:00
|
|
|
- listmonk
|
2023-07-18 13:46:25 +08:00
|
|
|
image_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:latest-armv6"
|
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:{{ .Tag }}-armv6"
|
|
|
|
- "ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:latest-armv6"
|
|
|
|
- "ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:{{ .Tag }}-armv6"
|
2023-07-18 13:46:25 +08:00
|
|
|
build_flag_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- --platform=linux/arm/v6
|
|
|
|
- --label=org.opencontainers.image.title={{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.description={{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.url=https://github.com/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.source=https://github.com/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.version={{ .Version }}
|
|
|
|
- --label=org.opencontainers.image.created={{ time "2006-01-02T15:04:05Z07:00" }}
|
|
|
|
- --label=org.opencontainers.image.revision={{ .FullCommit }}
|
|
|
|
- --label=org.opencontainers.image.licenses=AGPL-3.0
|
2023-07-18 13:46:25 +08:00
|
|
|
dockerfile: Dockerfile
|
|
|
|
extra_files:
|
2023-09-08 00:53:17 +08:00
|
|
|
- config.toml.sample
|
2024-07-21 13:33:15 +08:00
|
|
|
- docker-entrypoint.sh
|
2023-07-18 13:46:25 +08:00
|
|
|
- use: buildx
|
|
|
|
goos: linux
|
|
|
|
goarch: arm
|
|
|
|
goarm: 7
|
|
|
|
ids:
|
2023-09-08 00:53:17 +08:00
|
|
|
- listmonk
|
2023-07-18 13:46:25 +08:00
|
|
|
image_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:latest-armv7"
|
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:{{ .Tag }}-armv7"
|
|
|
|
- "ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:latest-armv7"
|
|
|
|
- "ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:{{ .Tag }}-armv7"
|
2023-07-18 13:46:25 +08:00
|
|
|
build_flag_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- --platform=linux/arm/v7
|
|
|
|
- --label=org.opencontainers.image.title={{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.description={{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.url=https://github.com/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.source=https://github.com/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}
|
|
|
|
- --label=org.opencontainers.image.version={{ .Version }}
|
|
|
|
- --label=org.opencontainers.image.created={{ time "2006-01-02T15:04:05Z07:00" }}
|
|
|
|
- --label=org.opencontainers.image.revision={{ .FullCommit }}
|
|
|
|
- --label=org.opencontainers.image.licenses=AGPL-3.0
|
2023-07-18 13:46:25 +08:00
|
|
|
dockerfile: Dockerfile
|
|
|
|
extra_files:
|
2023-09-08 00:53:17 +08:00
|
|
|
- config.toml.sample
|
2024-07-21 13:33:15 +08:00
|
|
|
- docker-entrypoint.sh
|
2023-07-18 13:46:25 +08:00
|
|
|
|
|
|
|
docker_manifests:
|
2023-09-08 00:53:17 +08:00
|
|
|
- name_template: "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:latest"
|
2023-07-18 13:46:25 +08:00
|
|
|
image_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:latest-amd64"
|
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:latest-arm64v8"
|
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:latest-armv6"
|
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:latest-armv7"
|
|
|
|
- name_template: "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:{{ .Tag }}"
|
2023-07-18 13:46:25 +08:00
|
|
|
image_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:{{ .Tag }}-amd64"
|
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:{{ .Tag }}-arm64v8"
|
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:{{ .Tag }}-armv6"
|
|
|
|
- "{{ .Env.DOCKER_ORG }}/{{ .ProjectName }}:{{ .Tag }}-armv7"
|
|
|
|
- name_template: ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:latest
|
2023-07-18 13:46:25 +08:00
|
|
|
image_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:latest-amd64
|
|
|
|
- ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:latest-arm64v8
|
|
|
|
- ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:latest-armv6
|
|
|
|
- ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:latest-armv7
|
|
|
|
- name_template: ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:{{ .Tag }}
|
2023-07-18 13:46:25 +08:00
|
|
|
image_templates:
|
2023-09-08 00:53:17 +08:00
|
|
|
- ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:{{ .Tag }}-amd64
|
|
|
|
- ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:{{ .Tag }}-arm64v8
|
|
|
|
- ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:{{ .Tag }}-armv6
|
|
|
|
- ghcr.io/{{ .Env.GITHUB_ORG }}/{{ .ProjectName }}:{{ .Tag }}-armv7
|