34 lines
733 B
PowerShell
34 lines
733 B
PowerShell
echo ""
|
|
echo ""
|
|
echo ""
|
|
echo "=============================="
|
|
echo ""
|
|
echo "Waren Init"
|
|
echo ""
|
|
echo "=============================="
|
|
echo ""
|
|
echo ""
|
|
echo "Generating SSH Key"
|
|
New-Item -ItemType Directory -Path "$Env:USERPROFILE\.ssh\keys" -Force
|
|
ssh-keygen -f "$Env:USERPROFILE\.ssh\keys\infra" -t ed25519 -C "$Env:USERDOMAIN"
|
|
echo ""
|
|
echo ""
|
|
echo "Copy SSH Key"
|
|
Get-Content "$Env:USERPROFILE\.ssh\keys\infra.pub"
|
|
echo ""
|
|
echo ""
|
|
echo "Install OpenSSH Server"
|
|
Add-WindowsCapability -Online -Name OpenSSH.Server
|
|
echo ""
|
|
echo ""
|
|
echo "Enable OpenSSH Server"
|
|
Set-Service -Name sshd -StartupType 'Automatic'
|
|
echo ""
|
|
echo ""
|
|
echo "Start OpenSSH Server"
|
|
Start-Service -Name sshd
|
|
echo ""
|
|
echo ""
|
|
echo "Install Debian"
|
|
wsl --install Debian
|