Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Azure Function runs on the Cloud and can be coded in PowerShell.
Or do you mean that you want to even implement it "on the Cloud" (in the Azure Portal)?
Borges

martin wrote:

But you can still use Azure Function, cannot you?


I am trying to do this entirely on the Cloud via Powershell.
martin

But you can still use Azure Function, cannot you?
Borges

To use WebJobs though you have to attach the script to an existing site. This is just a free floating powershell task that has nothing to do with any website. I wanted to automate it on Azure,
martin

Re: Using WinSCP within powershell script on Azure

I was not able to use WinSCP .NET assembly in Azure Runbook.
The assembly uses WinSCP executable internally. And I was not able to use it on Runbook.
I've posted a question on Stack Overflow:
https://stackoverflow.com/q/57574899/850848

If it turns out that it's indeed not possible, note that you can use WinSCP .NET assembly in Azure Functions:
https://winscp.net/eng/docs/guide_microsoft_azure_function_sftp
And in Azure WebJobs:
https://winscp.net/eng/docs/guide_microsoft_azure_webjob_sftp
Borges

Using WinSCP within powershell script on Azure

I'm able to run a script locally with the following script referring to the dll in the same local directory as the script.


Add-Type -Path "WinSCPnet.dll"

If I want to run my script within an Azure Runbook then I need to use WinSCP from Azure. Is it accessible there? Do I need to install it on a web service and refer to that?

Thanks!