2019-09-19 06:19:25 +00:00
|
|
|
#define MyAppName "SFTPGo"
|
2020-06-28 13:57:33 +00:00
|
|
|
#if GetEnv("SFTPGO_ISS_VERSION") != ""
|
|
|
|
#define MyAppVersion GetEnv("SFTPGO_ISS_VERSION")
|
|
|
|
#else
|
|
|
|
#define MyAppVersion "v0.0.0"
|
|
|
|
#endif
|
2019-09-19 06:19:25 +00:00
|
|
|
#define MyAppURL "https://github.com/drakkan/sftpgo"
|
2020-06-28 13:57:33 +00:00
|
|
|
#define MyVersionInfo StringChange(MyAppVersion,"v","")
|
|
|
|
#if GetEnv("SFTPGO_ISS_DOC_URL") != ""
|
|
|
|
#define DocURL GetEnv("SFTPGO_ISS_DOC_URL")
|
|
|
|
#else
|
2021-02-09 18:53:03 +00:00
|
|
|
#define DocURL "https://github.com/drakkan/sftpgo/blob/main/README.md"
|
2020-06-28 13:57:33 +00:00
|
|
|
#endif
|
2019-09-19 06:19:25 +00:00
|
|
|
#define MyAppExeName "sftpgo.exe"
|
2020-06-28 13:57:33 +00:00
|
|
|
#define MyAppDir "..\output"
|
|
|
|
#define MyOutputDir ".."
|
2019-09-19 06:19:25 +00:00
|
|
|
|
|
|
|
[Setup]
|
|
|
|
AppId={{1FB9D57F-00DD-4B1B-8798-1138E5CE995D}
|
|
|
|
AppName={#MyAppName}
|
|
|
|
AppVersion={#MyAppVersion}
|
2020-06-29 12:55:58 +00:00
|
|
|
AppVerName={#MyAppName} {#MyAppVersion}
|
2019-09-19 06:19:25 +00:00
|
|
|
AppPublisherURL={#MyAppURL}
|
|
|
|
AppSupportURL={#MyAppURL}
|
|
|
|
AppUpdatesURL={#MyAppURL}
|
|
|
|
DefaultDirName={autopf}\{#MyAppName}
|
|
|
|
DefaultGroupName={#MyAppName}
|
2019-10-07 20:37:28 +00:00
|
|
|
LicenseFile={#MyAppDir}\LICENSE.txt
|
|
|
|
OutputDir={#MyOutputDir}
|
2019-09-19 06:19:25 +00:00
|
|
|
OutputBaseFilename=sftpgo_windows_x86_64
|
|
|
|
SolidCompression=yes
|
|
|
|
WizardStyle=modern
|
|
|
|
ArchitecturesInstallIn64BitMode=x64
|
|
|
|
PrivilegesRequired=admin
|
|
|
|
ArchitecturesAllowed=x64
|
2020-10-31 10:04:24 +00:00
|
|
|
MinVersion=6.1
|
2020-06-28 13:57:33 +00:00
|
|
|
VersionInfoVersion={#MyVersionInfo}
|
2019-09-19 06:19:25 +00:00
|
|
|
|
|
|
|
[Languages]
|
|
|
|
Name: "english"; MessagesFile: "compiler:Default.isl"
|
|
|
|
|
|
|
|
[Files]
|
2019-10-07 20:37:28 +00:00
|
|
|
Source: "{#MyAppDir}\sftpgo.exe"; DestDir: "{app}"; Flags: ignoreversion
|
2020-03-03 21:31:13 +00:00
|
|
|
Source: "{#MyAppDir}\sftpgo.db"; DestDir: "{commonappdata}\{#MyAppName}"; Flags: onlyifdoesntexist uninsneveruninstall
|
2019-10-07 20:37:28 +00:00
|
|
|
Source: "{#MyAppDir}\LICENSE.txt"; DestDir: "{app}"; Flags: ignoreversion
|
2020-03-03 21:31:13 +00:00
|
|
|
Source: "{#MyAppDir}\sftpgo.json"; DestDir: "{commonappdata}\{#MyAppName}"; Flags: onlyifdoesntexist uninsneveruninstall
|
|
|
|
Source: "{#MyAppDir}\templates\*"; DestDir: "{commonappdata}\{#MyAppName}\templates"; Flags: ignoreversion recursesubdirs createallsubdirs
|
|
|
|
Source: "{#MyAppDir}\static\*"; DestDir: "{commonappdata}\{#MyAppName}\static"; Flags: ignoreversion recursesubdirs createallsubdirs
|
2019-09-19 06:19:25 +00:00
|
|
|
|
|
|
|
[Dirs]
|
2020-03-03 21:31:13 +00:00
|
|
|
Name: "{commonappdata}\{#MyAppName}\logs"; Permissions: everyone-full
|
|
|
|
Name: "{commonappdata}\{#MyAppName}\backups"; Permissions: everyone-full
|
|
|
|
Name: "{commonappdata}\{#MyAppName}\credentials"; Permissions: everyone-full
|
2019-09-19 06:19:25 +00:00
|
|
|
|
|
|
|
[Icons]
|
2019-10-07 20:37:28 +00:00
|
|
|
Name: "{group}\Web Admin"; Filename: "http://127.0.0.1:8080/web";
|
2020-06-29 12:55:58 +00:00
|
|
|
Name: "{group}\Service Control"; WorkingDir: "{app}"; Filename: "powershell.exe"; Parameters: "-Command ""Start-Process cmd \""/k cd {app} & {#MyAppExeName} service --help\"" -Verb RunAs"; Comment: "Manage SFTPGo Service"
|
2020-06-28 13:57:33 +00:00
|
|
|
Name: "{group}\Documentation"; Filename: "{#DocURL}";
|
2019-09-19 06:19:25 +00:00
|
|
|
Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}"
|
|
|
|
|
|
|
|
[Run]
|
|
|
|
Filename: "netsh"; Parameters: "advfirewall firewall delete rule name=""SFTPGo Service"""; Flags: runhidden
|
|
|
|
Filename: "netsh"; Parameters: "advfirewall firewall add rule name=""SFTPGo Service"" dir=in action=allow program=""{app}\{#MyAppExeName}"""; Flags: runhidden
|
2020-03-07 17:06:46 +00:00
|
|
|
Filename: "{app}\{#MyAppExeName}"; Parameters: "service stop"; Flags: runhidden
|
|
|
|
Filename: "{app}\{#MyAppExeName}"; Parameters: "service uninstall"; Flags: runhidden
|
2020-03-04 08:27:14 +00:00
|
|
|
Filename: "{app}\{#MyAppExeName}"; Parameters: "service install -c ""{commonappdata}\{#MyAppName}"" -l ""logs\sftpgo.log"""; Description: "Install SFTPGo Windows Service"; Flags: runhidden
|
2019-09-19 06:19:25 +00:00
|
|
|
Filename: "{app}\{#MyAppExeName}"; Parameters: "service start"; Description: "Start SFTPGo Windows Service"; Flags: runhidden
|
|
|
|
|
|
|
|
[UninstallRun]
|
|
|
|
Filename: "{app}\{#MyAppExeName}"; Parameters: "service stop"; Flags: runhidden
|
|
|
|
Filename: "{app}\{#MyAppExeName}"; Parameters: "service uninstall"; Flags: runhidden
|
|
|
|
Filename: "netsh"; Parameters: "advfirewall firewall delete rule name=""SFTPGo Service"""; Flags: runhidden
|