mirror of
				https://github.com/jtesta/ssh-audit.git
				synced 2025-11-04 03:02:15 +01:00 
			
		
		
		
	Updated packaging instructions and merged Windows instructions.
This commit is contained in:
		
							
								
								
									
										36
									
								
								PACKAGING
									
									
									
									
									
								
							
							
						
						
									
										36
									
								
								PACKAGING
									
									
									
									
									
								
							@@ -1,3 +1,23 @@
 | 
			
		||||
= Windows =
 | 
			
		||||
 | 
			
		||||
An executable can only be made on a Windows host because the PyInstaller tool (https://www.pyinstaller.org/) does not support cross-compilation.
 | 
			
		||||
 | 
			
		||||
On a Windows machine, do the following:
 | 
			
		||||
 | 
			
		||||
1.) Install Python v3.7.x from https://www.python.org/.  (As of this writing v3.8.0 isn't supported.)  To make life easier, check the option to add Python to the PATH environment variable.
 | 
			
		||||
 | 
			
		||||
2.) Using pip, install pyinstaller and colorama:
 | 
			
		||||
 | 
			
		||||
    pip install pyinstaller colorama
 | 
			
		||||
 | 
			
		||||
3.) Create the executable with:
 | 
			
		||||
 | 
			
		||||
    cd src\ssh_audit
 | 
			
		||||
    rename ssh_audit.py ssh-audit.py
 | 
			
		||||
    pyinstaller -F --icon ..\..\windows_icon.ico ssh-audit.py
 | 
			
		||||
 | 
			
		||||
---
 | 
			
		||||
 | 
			
		||||
= PyPI =
 | 
			
		||||
 | 
			
		||||
To create package and upload to test server:
 | 
			
		||||
@@ -31,13 +51,23 @@ $ pip3 install ssh-audit
 | 
			
		||||
 | 
			
		||||
To create the snap package, run a fully-updated Ubuntu Server 20.04 VM.
 | 
			
		||||
 | 
			
		||||
As root, run (leave all options default):
 | 
			
		||||
Install pre-requisites with:
 | 
			
		||||
 | 
			
		||||
# lxd init
 | 
			
		||||
$ sudo apt install make snapcraft
 | 
			
		||||
$ sudo snap install review-tools
 | 
			
		||||
 | 
			
		||||
Initialize LXD (leave all options default):
 | 
			
		||||
 | 
			
		||||
$ sudo lxd init
 | 
			
		||||
 | 
			
		||||
Bump the version number in snapcraft.yaml.  Then run:
 | 
			
		||||
 | 
			
		||||
# make -f Makefile.snap
 | 
			
		||||
$ make -f Makefile.snap
 | 
			
		||||
 | 
			
		||||
Upload the snap with:
 | 
			
		||||
 | 
			
		||||
$ snapcraft login
 | 
			
		||||
$ snapcraft upload --release=stable ssh-audit_*.snap
 | 
			
		||||
 | 
			
		||||
----
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user