-
Trying to build and deploy an ASp.NET Blazor web site. I have most of the build and deploy action working, but am stuck with the last step. I am using 3rd party hosting, where the only access I have to the server is either a control panel or FTP. Simply FTPing the files to the server doesn’t work, as IIS locks some of them, so it seems I need to upload a file named The relevant parts of my current First question is, is this the best way to do it at all? It seems very convoluted. I couldn’t find any way of FTPing a single file, only a folder, so had to create a folder, then create an The bigger problem is that the last step fails with the following message…
I am running the build and deploy under Windows, and the server is running Windows. I’m not sure how to get around this. Thanks for any guidance. I’m very new to GitHub actions, so please feel free to suggest any improvements I could make. Here are the relevant parts of the
|
Beta Was this translation helpful? Give feedback.
Replies: 9 comments
-
It looks like the action About actions - GitHub Docs//docs.github.com/en/actions/creating-actions/about-actions You’ll either need to replace any steps in your workflow that run Docker actions or you’ll need to run your workflow on a Linux runner instead. |
Beta Was this translation helpful? Give feedback.
-
Thanks for the reply. Unfortunately, I can’t build and deploy on a Linux runner, as they don’t seem to handle Blazor very well (I’m not the first to spot this). Do you know of any way I can get around this? This is such a common issue with IIS, I can’t believe I’m the first person to want to solve it, but I’ve searched for hours, and just can’t find anyone who shows how to do it. Although my current code seems clunky, if I could find a way to delete or rename the file via FTP, it would work. Surely there must be some way of doing this on a Windows machine? Thanks again. |
Beta Was this translation helpful? Give feedback.
-
My first thought is that Python is available on the Windows runners, so you could use the |
Beta Was this translation helpful? Give feedback.
-
@airtower-luna Thanks for the suggestion. As I’m completely new at actions, please could you give me some guidance as to how I would use that module in my yml file? Specifically, would I need to do anything to get Python running, and how do I use the module in the yml? Thanks again. |
Beta Was this translation helpful? Give feedback.
-
mryossu:
Two options:
I’m not sure how the Windows runners are set up, but according to the environment documentation Python is already installed, so you shouldn’t need to do anything. If you need a specific version you might want to run |
Beta Was this translation helpful? Give feedback.
-
Thanks for the reply. I tried this, but couldn’t get it to work. Here is the test .yml file I have…
When I run it, it fails with the following error…
The “^” was underneath the “ftp:” at the end of the “with” line. If I add single quotes around the secrets, then the error changes to…
Any ideas? Thanks again. |
Beta Was this translation helpful? Give feedback.
-
OK, ignore the previous. Seems the syntax was wrong. I changed the code to…
…and it worked fine. Thanks again |
Beta Was this translation helpful? Give feedback.
-
I’m glad it works, I’d recommend using |
Beta Was this translation helpful? Give feedback.
-
OK, thanks for the tip. Thanks again for all the help. |
Beta Was this translation helpful? Give feedback.
OK, ignore the previous. Seems the syntax was wrong. I changed the code to…
…and it worked fine.
Thanks again