The WHY
There was a request to duplicate files from a SharePoint document library to a File Share. For this particular instance, I didn’t dive deep into the why but dived right into solutioning.
For testing purposes, I create an “instant flow” that would run when you told it to do so in order to streamline the testing. I quickly ran into issues where I was trying to connect to the On-prem Gateway but was not having much luck. Additionally, looking elsewhere on the interwebs for supporting documentation but found little to nothing about solving our connectivity issues.
Below is a step by step process on how to get your gateway to connect and use that with the File System connector.
The HOW
Download / Install gateway on the server (Link to On-Premise Gateway download)
The account you install the gateway with will be the one that is the admin. Open this connection within gateways in the power platform, and you can share this connection with others.
Create On-Prem Gateway including descriptive name
- Root folder (I took this from the path to the area where I wanted to store the file) be sure that you add a parent folder and not your select folder. I found small issues while navigating directly to the folder
- Windows as the authentication type

Add your username, which would be the domain\user OR IP address\user. Both work and will be accepted. If this schema isn’t followed, the connection will say it passes but will not be successful.
Select the gateway you have installed.

Creating a test flow to ensure this works:
Create an Instant Flow “Manually triggered Flow”
Add the action to Get file content from SharePoint. Navigate to any document you have read rights to within O365.

Add the Create file action and input the following:
Click the folder to navigate to your desired area
Type in a title and use the desired file extension. If you’re getting content of an excel file, type “.xslx” for a document type “.docx”
Insert the file contetn from the get file content step
Click Save

Run flow and test.
I saw the file pop up instantly within my environment. I hope you do as well!
Helpful Links:
https://docs.microsoft.com/en-us/power-automate/gateway-reference
https://docs.microsoft.com/en-us/data-integration/gateway/service-gateway-install