adding packaging
This commit is contained in:
parent
41f93fcf15
commit
6435d0e844
|
@ -0,0 +1,9 @@
|
||||||
|
SHELL := /bin/bash
|
||||||
|
|
||||||
|
apk:
|
||||||
|
nfpm package -p apk
|
||||||
|
deb:
|
||||||
|
nfpm package -p deb
|
||||||
|
rpm:
|
||||||
|
nfpm package -p rpm
|
||||||
|
|
|
@ -1,9 +1,10 @@
|
||||||
#!ipxe
|
#!ipxe
|
||||||
|
|
||||||
set ignition-server 192.168.40.3
|
set ignition-server MY_IP_HERE
|
||||||
#set base-url http://${ignition-server}/flatcar
|
#set base-url http://${ignition-server}/flatcar
|
||||||
set base-url http://stable.release.flatcar-linux.net/amd64-usr/current
|
set base-url http://stable.release.flatcar-linux.net/amd64-usr/current
|
||||||
set vm-install-target /dev/vda
|
set vm-install-target /dev/vda
|
||||||
|
set bm-install-target /dev/sda
|
||||||
|
|
||||||
:start
|
:start
|
||||||
menu Cadoles PXE Boot Options
|
menu Cadoles PXE Boot Options
|
||||||
|
@ -26,40 +27,40 @@ choose --default exit --timeout 10000 option && goto ${option}
|
||||||
shell
|
shell
|
||||||
|
|
||||||
:klead
|
:klead
|
||||||
set ignition-url http://${ignition-server}/leader.json
|
set ignition-url http://${ignition-server}/os/leader.json
|
||||||
|
|
||||||
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=${ignition-url}
|
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=${ignition-url}
|
||||||
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
||||||
boot
|
boot
|
||||||
|
|
||||||
:kmaster
|
:kmaster
|
||||||
set ignition-url http://${ignition-server}/leader.json
|
set ignition-url http://${ignition-server}/os/leader.json
|
||||||
|
|
||||||
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=${ignition-url}
|
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=${ignition-url}
|
||||||
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
||||||
|
|
||||||
:knode
|
:knode
|
||||||
set ignition-url http://${ignition-server}/leader.json
|
set ignition-url http://${ignition-server}/os/leader.json
|
||||||
|
|
||||||
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=${ignition-url}
|
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 ignition.config.url=${ignition-url}
|
||||||
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
||||||
|
|
||||||
:iklead
|
:iklead
|
||||||
set ignition-url http://${ignition-server}/leader-install.json
|
set ignition-url http://${ignition-server}/os/leader-install.json
|
||||||
|
|
||||||
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 flatcar.target=${vm-install-target} ignition.config.url=${ignition-url}
|
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 flatcar.target=${vm-install-target} ignition.config.url=${ignition-url}
|
||||||
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
||||||
boot
|
boot
|
||||||
|
|
||||||
:iknode
|
:iknode
|
||||||
set ignition-url http://${ignition-server}/leader.json
|
set ignition-url http://${ignition-server}/os/leader.json
|
||||||
|
|
||||||
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 flatcar.target=${vm-install-target} ignition.config.url=${ignition-url}
|
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 flatcar.target=${vm-install-target} ignition.config.url=${ignition-url}
|
||||||
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
||||||
boot
|
boot
|
||||||
|
|
||||||
:iknode
|
:iknode
|
||||||
set ignition-url http://${ignition-server}/leader.json
|
set ignition-url http://${ignition-server}/os/leader.json
|
||||||
|
|
||||||
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 flatcar.target=${vm-install-target} ignition.config.url=${ignition-url}
|
kernel ${base-url}/flatcar_production_pxe.vmlinuz initrd=flatcar_production_pxe_image.cpio.gz flatcar.first_boot=1 flatcar.target=${vm-install-target} ignition.config.url=${ignition-url}
|
||||||
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
initrd ${base-url}/flatcar_production_pxe_image.cpio.gz
|
|
@ -0,0 +1,8 @@
|
||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
ip=$(/sbin/ip -o -4 addr list eth0 | awk '{print $4}' | cut -d/ -f1)
|
||||||
|
|
||||||
|
sed -i -e "s/MY_IP_HERE/${ip}/g" /srv/tftpboot/menu/boot.ipxe
|
||||||
|
|
||||||
|
service dnsmasq start
|
||||||
|
service mini_httpd start
|
|
@ -0,0 +1,41 @@
|
||||||
|
# nfpm example config file
|
||||||
|
#
|
||||||
|
# check https://nfpm.goreleaser.com/configuration for detailed usage
|
||||||
|
#
|
||||||
|
|
||||||
|
name: "ckube-pxe"
|
||||||
|
arch: "amd64"
|
||||||
|
platform: "linux"
|
||||||
|
version: "v0.0.1"
|
||||||
|
section: "default"
|
||||||
|
priority: "extra"
|
||||||
|
maintainer: "Cadoles <contact@cadoles.com>"
|
||||||
|
description: |
|
||||||
|
CadolesKube OS Installer (iPXE)
|
||||||
|
vendor: "Cadoles"
|
||||||
|
homepage: "https://www.cadoles.com"
|
||||||
|
license: "GPL-v3"
|
||||||
|
changelog: "changelog.yaml"
|
||||||
|
|
||||||
|
contents:
|
||||||
|
- src: butane
|
||||||
|
dst: /srv/os/butane
|
||||||
|
- src: /srv/os/butane
|
||||||
|
dst: /var/www/localhost/htdocs/os
|
||||||
|
type: symlink
|
||||||
|
- src: ipxe/etc/dnsmasq.d
|
||||||
|
dst: /etc
|
||||||
|
- src: ipxe/tftpboot
|
||||||
|
dst: /srv/tftpboot
|
||||||
|
|
||||||
|
scripts:
|
||||||
|
postinstall: ./misc/scripts/basic-setup.sh
|
||||||
|
|
||||||
|
overrides:
|
||||||
|
apk:
|
||||||
|
depends:
|
||||||
|
- dnsmasq
|
||||||
|
- dnsmasq-openrc
|
||||||
|
- dnsmasq-common
|
||||||
|
- alpine-ipxe
|
||||||
|
- mini_httpd
|
Loading…
Reference in New Issue