can someone please help me. I have problems to do test on gitlab with a django application. It's about connexion to the server, I've try with postgress or mysql but nothing!!
Related
I deployed the server developed with FastAPI on vercel and it is working. Server is updated to use mysql server and is now working with local mysql. But now I have no way to deploy that on vercel. Can anyone give some tips about how to do that?
Hi I have deployed a Flask (ML Project) in Heroku cloud and the app is published. But when I try to predict the model, it gave an error of database connection. When I debug I found out that the connection to the cassandra db is not working. Here was my code
self.cloud_config = {'secure_connect_bundle': "cassandraconnection\\secure-connect-test.zip"}
self.auth_provider = PlainTextAuthProvider('XXX','XXX')
self.cluster = Cluster(cloud=self.cloud_config, auth_provider=self.auth_provider)
The secure-connect-test.zip file is located in the project directory itself. But still i am getting the error
No such file or directory: 'cassandraconnection\\secure-connect-test.zip'
Can anyone suggest where I am making the mistake. Or how to solve this issue
It's very likely that where you think the secure bundle should be and where Heroku is looking for it don't match.
We recommend that you always specify the full path to your Astra DB secure connect bundle to avoid confusion. Cheers!
This is the first time I've developed a web app using Django and one of my first major attempts at programming.
I'm trying to deploy my project to the django test server- http://127.0.0.1:8000/ -but I get an error that says the connection is refused. I've looked through Django's documentation and and other websites about django deployment but I'm at a loss on how to troubleshoot this error.
If someone can recommend a way for me to deploy django locally so I can test my web app using django test server or recommend another deployment service that is easy for new programmers to use that would be very appreciated.
edit: After doing what Ojas Kale had suggested I still am at a loss on what the possible issue or issues that are causing this error.
Davis Joseph.
I want to host my Django 1.10 web application on WHM(VPS). for that i have installed Django and another necessary tools on WHM(VPS) by ssh login. and i also have uploaded my Django application code through cpanel in public_html directory.
When i run python manage.py runserver <ip_address:8000> from ssh terminal, i am able to access that application. but when i close the ssh terminal, it terminates all the running process. so could not access application after that.
So, Is there any way that without running python manage.py script i can access Django application?
Any help would be highly appreciated.
Thank you.
Django comes with a built-in development server, it's not really meant to be used when deploying to a remote VPS.
There are some great resources to help you along, but what you're likely going to want to do is deploy your app on a stack using gunicorn or uwsgi as an application server and a web server like Nginx or apache 2 as a reverse proxy.
I personally use Nginx and uwsgi.
There are some great resources explaining how to deploy a Django server. Have a look at this one from digital ocean, it was a great help when I needed to set up a production server correctly: https://www.digitalocean.com/community/tutorials/how-to-serve-django-applications-with-uwsgi-and-nginx-on-ubuntu-16-04
best of luck with it!
I'm having a lot of trouble with getting web2py to work on Heroku. I can't even get a basic app to work. Whenever I go to my herokuapp page, it says
Application Error
An error occurred in the application and your page could not be served. Please try again in a few moments.
If you are the application owner, check your logs for details."
It may be a problem with the DB setup. By default web2py only supports sqlite or Google App Engine (GAE). It's probably trying to initialize sqlite databases on Heroku's read-only filesystem.
Either disable the DB code temporarily to see if this is indeed the case, or configure a connection to a supported database (MySQL, S3, etc).
Take a look at the "official" Heroku script in scripts/setup-web2py-heroku.sh
Try with a simple wsgi application first. Here is some tutorial: http://webpython.codepoint.net/wsgi_tutorial
Web2py will work without any problems if you can run simple wsgi apps.