Forums

Automatically deploying app to PythonAnywhere through GitHub

Exploring Alternatives to Webhooks for Integrating GitHub Actions with PythonAnywhere

Hello everyone,

I'm currently trying to enhance my workflow by integrating GitHub Actions with PythonAnywhere. Traditionally, I know that webhooks are commonly used for this purpose, but I've found them not to be the ideal solution for my needs.

Has anyone here successfully established a connection between GitHub Actions and PythonAnywhere without using webhooks? If so, could you share how you achieved this? I'm interested in any alternative methods that might be available, such as direct API calls, third-party tools, or any scripts that facilitate this integration.

Any insights or examples of how you've set up your environment would be greatly appreciated. I'm looking for a robust solution that ensures seamless deployment and synchronization between GitHub and PythonAnywhere.

Thank you for your help!

As you have a paid account, which supports SSH, perhaps you could deploy using actions with a git push from the remote side? We have a blog post explaining how to do that from your local machine, and doing it from a GitHub action would probably be very similar.

Hey I have an action on GitHub for Django Application

https://github.com/umuttopalak/pythonanywhere-deploy-action

I also working on for deploying Flask applications

That's really useful, thank you for sharing it!