[packages/sish] new, an open source serveo/ngrok alternative

glen glen at pld-linux.org
Fri Sep 13 13:13:32 CEST 2019


commit dbe31ea0e1fbba37c8326c1ed596d12e79e2241f
Author: Elan Ruusamäe <glen at pld-linux.org>
Date:   Fri Sep 13 14:12:34 2019 +0300

    new, an open source serveo/ngrok alternative

 sish.spec | 57 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 57 insertions(+)
---
diff --git a/sish.spec b/sish.spec
new file mode 100644
index 0000000..087d19f
--- /dev/null
+++ b/sish.spec
@@ -0,0 +1,57 @@
+#
+# Conditional build:
+%bcond_with	prebuilt		# use prebuilt binary
+
+%define		revision	58fc3ee5f
+Summary:	An open source serveo/ngrok alternative
+Name:		sish
+Version:	0.0.1
+Release:	1
+License:	MIT
+Group:		Development/Building
+Source0:	https://github.com/antoniomika/sish/archive/%{revision}/%{revision}.tar.gz
+# Source0-md5:	878d1a9bee0864181965448869f1c184
+URL:		https://github.com/antoniomika/sish
+BuildRequires:	golang >= 1.11
+BuildRequires:	rpmbuild(macros) >= 1.647
+ExclusiveArch:	%{ix86} %{x8664} %{arm}
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+# go stuff
+%define _enable_debug_packages 0
+%define gobuild(o:) go build -ldflags "${LDFLAGS:-} -B 0x$(head -c20 /dev/urandom|od -An -tx1|tr -d ' \\n')" -a -v %{?debug:-x} %{?**};
+%define import_path	github.com/antoniomika/sish
+
+%description
+An open source serveo/ngrok alternative. HTTP(S)/WS(S)/TCP Tunnels to
+localhost using only SSH.
+
+%prep
+%setup -qc
+
+# for doc
+mv %{name}-*/*.md .
+
+# don't you love go?
+install -d src/$(dirname %{import_path})
+mv %{name}-* src/%{import_path}
+
+%build
+export GOPATH=$(pwd)
+cd src/%{import_path}
+
+go get ./...
+%gobuild ./...
+
+%install
+rm -rf $RPM_BUILD_ROOT
+install -d $RPM_BUILD_ROOT%{_bindir}
+install -p bin/%{name} $RPM_BUILD_ROOT%{_bindir}
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(644,root,root,755)
+%doc README.md
+%attr(755,root,root) %{_bindir}/sish
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/sish.git/commitdiff/dbe31ea0e1fbba37c8326c1ed596d12e79e2241f



More information about the pld-cvs-commit mailing list