Quantcast
Channel: PowerShell.com – PowerShell Scripts, Tips, Forums, and Resources: Active Threads
Viewing all articles
Browse latest Browse all 8411

Create FTP Site problem

$
0
0

I am in the middle of a Windows 7 "Build" script with Powershell - taking a basic Windows PC and using a Powershell script to add all necessary users and items.  Am currently working on setting up an FTP server.  Have learned how to turn on FTP Server and IIS WebServer using DISM within Powershell, works great.  I am then trying to create my Default FTP Site.  Here is what I have so far (there will be a few more add'l items to come, but for now...)

Import-Module WebAdministration

New-WebFtpSite - Name "Default FTP Site" -Port "21" -PhysicalPath "C:\" -Force
Set-ItemProperty "IIS:\Sites\Default Ftp Site" -Name ftpServer.security.authentication.basicAuthentication.enabled - Value $true
Restart-WebItem "IIS:\Sites\Default FTP Site"

Everything works great except for -PhysicalPath - it's blank in the New-WebFtpSite line.  I've tried putting in other directories, i.e. "C:\temp", I've tried leaving out the quotes, but it never puts anything in that field when I check the Advanced Settings in the IIS Manager.  I guess I can test it out once I have all my settings in place and try to FTP in and see where it lands me, but anyone have an idea?

Thank you


Viewing all articles
Browse latest Browse all 8411