Django application deployment #Bluemix where postgresql is not available as a service - django

I'm trying to deploy my application into Bluemix which is using PostgreSQL as a database.
On Bluemix portal PostgreSQL is not available in listed services. How can I add it to my project.
Thanks in advance!

PostgreSQL is listed under the Labs section of the catalogue.
This service does not come with production-grade support.
If you want a supported version, use the service provided by Compose.

Related

Deploy Python apps to Azure App Service on Windows Server

I can't find any proper guideline how to deploy a Django web application on Windows Server, almost all tutorials talk about Linux. Can someone explain or give a link?
I now we need an IIS. What about DNS and AD, or any other services? I would like to know the relationship among IIS, DNS and AD, or any other services.
One simple way to deploy a Python app to Windows app service is to use the Devops Projects
Step 1: Create a Python Project
Step 2: Choose an application framework as Django
Step 3: Select the Windows Web App
Step 4: Fill the rest of the settings.
Once the project is created you can pass the custom code and do the deployment from the Azure Devops pipelines.
EDIT
if you want to deploy the app on VM follow the steps as mentioned here.

Working with PostgreSQL and Django on Google App Engine standard environment

I'm currently setting up a Django app on the Google App Engine platform, using a standard environment. Is it possible to connect to a PosgreSQL Google Cloud SQL instance?
I can connect to a MySQL instance by following this tutorial (https://cloud.google.com/python/django/appengine). I can't get PostgreSQL to work however - is this because PostgreSQL only works on a flexible environment?
Many thanks

Dockerized wso2 APIM

I was exploring the possibility of using Wso2 API Manager in a dockerized cluster and was pointed to this link.
https://github.com/gayangunarathne/Docker-compose/tree/master/wso2-products/WSO2APIM/1.10.
In the docker-compose file I see references to svnrepo service. Could you please point me to instructions on how to configure this? Is this really required for Deployment Synchronizer Configuration?
Also any idea how I can access dockerhub.private.wso2.com ? Also any other examples of the distributed patterns of components of API Manager (like gateway,keymanager,store,publisher) in docker containers that are running in the production environment?
WSO2 will soon have their docker images available publicly.
SVN is only required for dep-sync. For now you can use any svn docker container for that.
We are currently implementing distributed deployment patterns with docker-compose. These will be released once ready..
Hope this helps.
Supun

django on google app engine with relational database

So is there any other way to use mysql database with django app on app engine? I found nice solution but it is not free - Google SQL Cloud seem to work great. But how about, moving django app to appengine and connecting to other hosting with mysql db? Or do you have any other solutions?
So to sum up - is there any way to work GAE with outside database?
Actually I have found the answer:
The Python Development Server in the Google App Engine SDK can use a locally-installed MySQL server instance to closely mirror the Google Cloud SQL environment during development.
More info here-> https://developers.google.com/appengine/docs/python/cloud-sql/developers-guide

Grails App with Multi Tenant Single DB plugin URL implementation in Cloudfoundry

I am currently creating a web app using Grails implementing Multi Tenant Single DB plugin. The plugin allows me to have multiple tenants on a single db using a tenantID to differentiate between tenants. The plugin detects witch tenant will deal the current request that is made on my app by resolving using different domains/subdomains for each tenant.
For example:
Tenant 1 = companyA.myapp.com
Tenant 2 = companyB.myapp.com
On my local machine running Grails development mode I was able to implement the different hosts by changing my /etc/hosts and each tenant would have their own subdomain.
I am currently interested in using cloud foundry as my cloud platform but when I deploy my app to cloud foundry it is already using my app name as the subdomain for cloud foundry.
For example:
- myapp.cloudfoundry.com
Is it possible to change or control the domain name resolver in
cloud foundry?
Does anybody know how to handle multi-tenant subdomains as explained above in cloud foundry? Probably provide the steps in implementing this using cloud foundry?
What is the best approach to implement this using cloud foundry?
My App is using Grails 2.0.4 and Multi Tenant Single DB plugin 0.8.2.
Thanks
Unfortunately the current beta version CloudFoundry does not allow modification of the cloudfoundry subdomain. The plan is to have the GA towards the end of this year with a private preview of the version of the site available sooner in the fall. At that time you could be able to customize the subdomain.
Therefore you might need to change a little in your TenantResolver to only check the subdomain that varies.
To implement your requirement, did you try installing the grails cf plugin? If not you can start from here.
If you are using cli, installing the plugin just needs command in your project workspace:
grails install-plugin cloud-foundry
When your app is ready for deployment, push it to cloudfoundry:
grails cf-push
Note that you will have to have your cf credentials configured in the grails config file.
After that you can map multiple URLs you want using:
grails cf-map user1.yourapp.cloudfoundry.com
If you have already known about vmc which is the client command line interface for cf, you can see the urls mapped with your app by
vmc apps
If not you can refer to the installation guide to start if you would like to do that.
If you are using STS/eclipse, things will be even easier. First you need to have grails-support extension as well as the cloud foundry integration installed. For detailed docs of the cf integration please refer here.
After your app is deployed, right click the project and choose "Grails Tools" -> "Open Grails Command Prompt". This will enable you to have same grails cf plugin commands as the CLI does.
Hope this can help your move forward in the cloudfoundry world. Let me know if you have more questions.
Thanks,
William