Jenkins/resources/com/cadoles/podman/nfpm.yaml.gotmpl

25 lines
918 B
Go Template
Raw Permalink Normal View History

{{ $serviceName := index ( .Env.IMAGE_NAME | strings.Split "/" | coll.Reverse ) 0 }}
name: "cadoles-pod-{{ $serviceName }}"
arch: amd64
platform: linux
version: "{{ strings.TrimPrefix "v" ( getenv "IMAGE_TAG" "latest" ) }}"
version_schema: none
version_metadata: git
section: "{{ getenv "PACKAGE_SECTION" "default" }}"
priority: "{{ getenv "PACKAGE_PRIORITY" "optional" }}"
maintainer: "{{ getenv "PACKAGE_MAINTAINER" "contact@cadoles.com" }}"
description: "{{ getenv "PACKAGE_DESCRIPTION" "" }}"
homepage: "{{ getenv "PACKAGE_HOMEPAGE" "https://forge.cadoles.com" }}"
license: "{{ getenv "PACKAGE_LICENCE" "GPL-3.0" }}"
depends:
- podman
scripts:
postinstall: post-install.sh
contents:
- packager: deb
src: pod.service
dst: "/usr/lib/systemd/system/cadoles-pod-{{ $serviceName }}.service"
- packager: deb
src: pod.conf
dst: /etc/cadoles-pod-{{ $serviceName }}.conf
type: config|noreplace