mirror of
https://github.com/proxysu/ProxySU.git
synced 2024-11-25 14:46:08 +03:00
生成测试版
This commit is contained in:
parent
493e972bcd
commit
b37f7e9eb5
@ -30,12 +30,12 @@
|
||||
</Grid.RowDefinitions>
|
||||
<TextBlock Text="主机名" HorizontalAlignment="Left" VerticalAlignment="Bottom" Margin="5" Grid.Column="0" Grid.Row="0"></TextBlock>
|
||||
<TextBlock Text="端口" HorizontalAlignment="Left" VerticalAlignment="Bottom" Margin="5" Grid.Column="2" Grid.Row="0"></TextBlock>
|
||||
<TextBox x:Name="TextBoxHost" Text="192.168.200.200" Margin="5" Grid.Column="1" Grid.Row="0"></TextBox>
|
||||
<TextBox x:Name="TextBoxHost" Text="" Margin="5" Grid.Column="1" Grid.Row="0"></TextBox>
|
||||
<TextBox x:Name="TextBoxPort" CommandManager.PreviewExecuted="TextBoxPort_PreviewExecuted" Text="22" Margin="5" Grid.Column="3" Grid.Row="0" PreviewTextInput="TextBoxPort_PreviewTextInput"/>
|
||||
<TextBlock Text="用户名:" HorizontalAlignment="Left" VerticalAlignment="Bottom" Margin="5" Grid.Column="0" Grid.Row="1"></TextBlock>
|
||||
<TextBlock x:Name="TextBlockPassword" Text="密码:" HorizontalAlignment="Left" VerticalAlignment="Bottom" Margin="5" Grid.Column="2" Grid.Row="1"></TextBlock>
|
||||
<TextBox x:Name="TextBoxUserName" Text="root" Margin="5" Grid.Column="1" Grid.Row="1"></TextBox>
|
||||
<PasswordBox x:Name="PasswordBoxHostPassword" Password="Tianlong71605" Margin="5" Grid.Column="3" Grid.Row="1"></PasswordBox>
|
||||
<PasswordBox x:Name="PasswordBoxHostPassword" Password="" Margin="5" Grid.Column="3" Grid.Row="1"></PasswordBox>
|
||||
<RadioButton x:Name="RadioButtonPasswordLogin" GroupName="CertIsYesNo" Content="密码登录" Grid.Column="0" Grid.Row="2" Checked="RadioButtonPasswordLogin_Checked"></RadioButton>
|
||||
<RadioButton x:Name="RadioButtonCertLogin" GroupName="CertIsYesNo" Content="密钥登录" Grid.Column="1" Grid.Row="2" Checked="RadioButtonCertLogin_Checked"></RadioButton>
|
||||
<Button x:Name="ButtonOpenFileDialog" Content="浏览..." Margin="8" Grid.Column="2" Grid.Row="2" Click="ButtonOpenFileDialog_Click"></Button>
|
||||
|
@ -455,10 +455,18 @@ namespace ProxySU
|
||||
|
||||
//下载官方安装脚本安装
|
||||
|
||||
//client.RunCommand("curl -o /tmp/go.sh https://install.direct/go.sh");
|
||||
//client.RunCommand("bash /tmp/go.sh");
|
||||
//client.RunCommand("mv /etc/v2ray/config.json /etc/v2ray/config.json.1");
|
||||
client.RunCommand("mkdir /etc/v2ray");
|
||||
client.RunCommand("curl -o /tmp/go.sh https://install.direct/go.sh");
|
||||
string installResult= client.RunCommand("bash /tmp/go.sh").ToString();
|
||||
client.RunCommand("mv /etc/v2ray/config.json /etc/v2ray/config.json.1");
|
||||
if (!installResult.Contains("installed"))
|
||||
{
|
||||
MessageBox.Show("安装V2ray失败(官方脚本go.sh运行出错!)");
|
||||
client.Disconnect();
|
||||
currentStatus = "安装V2ray失败(官方脚本go.sh运行出错!)";
|
||||
textBlockName.Dispatcher.BeginInvoke(updateAction, textBlockName, progressBar, currentStatus);
|
||||
return;
|
||||
}
|
||||
//client.RunCommand("mkdir /etc/v2ray");
|
||||
//上传配置文件
|
||||
|
||||
currentStatus = "程序安装完毕,配置文件上传中......";
|
||||
|
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue
Block a user