I have a python/django application that im running on my dreamhost account. Excuse me for the novice question, but I'm a Java programmer by day and relatively new to python.
Ideally what I'd like to do is set something up where I can take the code I have locally, upload it to my server and then touch the restart.txt file. I realize I could probably accomplish this with a bat/ftp script, but I has hoping for something a bit more advanced/robust. I have a local mercurial repository where I'm doing version control, is it at all feasible to get mercurial running on dreamhost, and then set up so that when I push changes from my local repo to the server repo, those get deployed to the proper location?
Are there other solutions I should be looking at? I guess all I'm looking for is someone to point me in the right direction.
All the cool guys are using fabric nowadays. It's exactly what you looking for.
Related
So I recently finished my python project, grabbing values from an API and put it into my website.
Now I have no clue how I actually start the website (finding a host) and making it accessible to other people, I thought turning to here might find the solution.
I have done a good amount of research, tried "pythonanywhere" and "google app engine" but seem to not really find a solution.
I was hoping to be able to use "hostinger" as a host, as they have a good price and a good host. Contacted them but they said that they couldn't, though I could upload it to a VPS (which they have). Would it work for me to upload my files to this VPS and therefor get it to a website? or should I use another host?
I just deployed my first app and used Heroku. I'm very happy with it so far and it was fairly straight forward to set up. It does require a basic git understanding but was not hard to learn
A VPS would work, but you'll need to understand basic linux server admin to get things setup properly.
Sounds like you don't have any experience with server admin, so something like App Engine would be great for you. There are a ton of tutorials on the internet for deploying flask to GAE.
I've never worked with Django before so forgive me if a question sounds stupid.
I need to develop a web application, but I do not want to deploy it on a server. I need to package it, so that others would "install" it on their machine and run it. Why I want to do it this way? There are many reasons, which I don't want to go into right now. My question is: can I do it? If yes, then how?
This is possible. However, the client machine would need to be equipped with the correct technologies for this to work.
When you launch a web app on a server (live), the server is required to have certain settings and installs. For example, a Django web app: the server must have a version of Django installed.
Hence, whichever machine is running your web app, must have Django installed. It presumably also needs to have the database too. It might be quite a hassling process but it's possible.
Just like as a developer, you may have multiple users working on 1 project. So, they all need to have that project 'installed' on their devices so they can run it locally.
You need to either use a python to executable program, with Django already in it. The website files you can place into the dist folder or whatever folder has the executable in it. Then you can compress it and share it with others (who have the same OS as you).
For an example:
You have this script in Django (I'm too lazy to actually write one), and you want to share it with someone who doesn't have Python and Django on his/her computer.
I'm trying to setup nginx, gunicorn, supervisor and trac, it is all working fine, even the static files which I asked for help here some days before... but the authentification. How does it works??
I know about the basic/digest authentification with nginx... but is there any plugin or something to have authentification without to setup basic/digest authentification in nginx? I mean, is there some web-based authentification?
I've found an AccountManager plugin, but seems that it has been discontinued or it doesn't receive any update (at least for installation directions)
If it is not posible to setup trac with some kind of web/psql authentification, tell me about an alternative based in python, please.
I'm considering taiga because it's based on django at the back and looks very good, but I'm afraid it goes private software in the future, so i wanted to find a completely open source solution here.
Thanks
I'm considering taiga because it's based on django at the back and
looks very good, but I'm afraid it goes private software in the
future, so i wanted to find a completely open source solution here.
Taiga developers here! Taiga is not going open source in the future. We will charge for private projects, but public projects will always be free and Open Source self-hosted version will always be available. So please, don't worry about this or write us to our mailing list (some people asked this already)
https://groups.google.com/forum/#!forum/taigaio
We are happy that you considered Taiga.
I have developed a few python programs that I want to make available online.
I am new to web services, and I am not sure what I need to do in order to create a service where somebody makes a request to an URL (for example), and the URL triggers a Python program that displays something in the user's browser, or a set of inputs are given to the program via browser, and then python does whatver it is supposed to do.
I was playing with the google app engine, which runs fine with the tutorial, and was planning to use it becuase it looks easy, but the problem with GAE is that it does not work well (or does not work at all) with some libraries that I plan to use.
I guess what I am trying to do is some sort of API using my WebFaction account.
Can anybody point me in the right directions? What choices do I have in WebFaction? What are the easiest tools available?
Thank you very much for your help in advance.
Cheers
Well, your question is a little bit generic, but here are a few pointers/tips:
Webfaction allows you to install pretty much anything you want (you need to compile it / or ask the admins to install some CentOS package for you).
They provide some default Apache server with mod_wsgi, so you can run web2py, Django or any other wsgi frameworks.
Most popular Python web frameworks have available installers in Webfaction (web2py, django...), so I would recommend you to go with one of them.
I would also install supervisord to keep your service running after some reboot/crash/problem.
I would be glad to help you if you have any specific question...
How can i create a safe environment to create new and play with my web applications?
My ingredients so far: python,flask,github,heroku --- I have effectively created a app using flask and heroku (it just says hello world)
I have some knowledge of python. Have read through but hardly understand the flaskr tutorial for Flask. I do however envision that i'm going to be very frustrated if i can't have some kind of version history of my stumblings.
Without being sure i feel like the recipe might include: Github and virtualenv and some coping pasting of directories...
whats a recommended way to do this?
Just setup a GitHub repository and start hacking away with Flask.
Some pointers:
Use SQLAlchemy for database operations. It's secure and easy to use.
Either dive right into your project or make some simple test ones with Flask. It's a really beautiful framework to work with and is easy to learn, so just try to accomplish some simple tasks and get used to how it works.
I suggest you to use virtualenv and virtualenvwrapper, this way you can work on isolated pythons without filling your system's python with many eggs and switch between them easily.