From e22e1693408730f35a947eede7d1b0583bde25b5 Mon Sep 17 00:00:00 2001 From: Razzi Abuissa Date: Wed, 4 Oct 2023 15:14:49 -0500 Subject: [PATCH] Add fpm packaging for .deb --- .fpm | 14 ++++++++++++++ Makefile | 3 +++ ronin | 3 ++- 3 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 .fpm diff --git a/.fpm b/.fpm new file mode 100644 index 0000000..9716043 --- /dev/null +++ b/.fpm @@ -0,0 +1,14 @@ +-s dir +-t deb +-p ronin-0.1.0-1-any.deb +--name ronin +--version 0.1.0 +--architecture all +--depends qemu-system +--description "Run a debian virtual machine using qemu in 1 command" +--url https://git.sr.ht/~razzi/ronin --maintainer "Razzi Abuissa " +ronin=/usr/local/bin/ronin +setup-ssh.exp=/usr/libexec/ronin/setup-ssh.exp +setup-ssh.sh=/usr/libexec/ronin/setup-ssh.sh +guest-setup.sh=/usr/libexec/ronin/guest-setup.sh + diff --git a/Makefile b/Makefile index f287a4a..3133ca9 100644 --- a/Makefile +++ b/Makefile @@ -17,6 +17,9 @@ launch: install: ln -s $(shell pwd)/ronin /usr/local/bin +deb: + fpm + clean: -pkill -i qemu -$(RM) -r ~/.ronin/ diff --git a/ronin b/ronin index a0db6ed..87dc311 100755 --- a/ronin +++ b/ronin @@ -4,6 +4,7 @@ test ! -z "$RONIN_DEBUG" && set -ex RONIN_DISK="$HOME/.ronin/ronin-disk.qcow2" +RONIN_LIBEXEC=/usr/libexec/ronin ronin_setup() { mkdir -p ~/.cache/ronin && \ @@ -36,7 +37,7 @@ ronin_setup() { mv "$HOME/.ronin/ronin_key.priv.pub" "$HOME/.ronin/ronin_key.pub" RONIN_GUEST_SSHD_KEY="$HOME/.ronin/guest_ssh_host_ed25519_key.pub" - test ! -f "$RONIN_GUEST_SSHD_KEY" && ./setup-ssh.sh + test ! -f "$RONIN_GUEST_SSHD_KEY" && "$RONIN_LIBEXEC/setup-ssh.sh" return 0 } -- 2.45.2