I'm working on a project where I need to create and manage clusters, pods, services and deployments on google container engine.I have googled a lot to find an API for that, Google's Container engine REST API is available, is there any python client for that API? what I need exactly.
Help me, please!
Thanks in advance!
On this page you can find information about using Python including installation of the client library and
Google Container Engine API: The Google Container Engine API is used
for building and managing container based applications, powered by the
open source Kubernetes technology.
This page contains information about getting started with the Google
Container Engine API using the Google API Client Library for Python.
In addition, you may be interested in the following documentation.
More generally there is this page about Google APIs and Python libraries and a getting started using Python in GCE example on Github.
Related
I have a python programs & classes combined together by main.py for the backend algorithms and works. I was developing the app for android using Jetpack compose in android studio.
Last week I started my research for cloud services that can run my python programs for my android.
I find that App Engine of Google Cloud Platform and Firebase. But after looking for tutorials I couldn’t find a way to work with App engine so I decided to go for Firebase.
In Firebase page, they had a service called - Cloud function. Now as per my understanding even I if I had gone with App engine, I would have used the Cloud function too.
How my app works?
My app is a social media app. I have a MongoDB server cluster in MongoDB Atlas that store every data. For authentication I had decided to go just for plain custom username & password stored encrypted on my same MongoDB server, but I was open to Firebase Authentication too. Since my app had a feed where photos, videos are stored - I needed a cloud storage for that. I found that Google Cloud storage for that.
So back to my question. Is there any service that is server-less (as I’ve very less people in my team to manage a server too) that can run Python programs for different requests from different users of my android app.
For sake of comparison, my app can be compared to Instagram without Reels!
My question is how to upload my python project, which contains different classes that are used to as algorithms for my app. It's like this, for ex., if an user goes to feed page then it has to call function in my python program that gets the feeds as per calling user's preference & followed accounts. My understanding is that I have to call this function from my android app.
I need help to find a tutorial for following things:
How to set up Firebase or App Engine & implement it in Android Studio
How to deploy my python files to firebase or App Engine for Cloud Functions
How to call this function from Android app (Kotlin + Compose) and receive in Python.
Note: I've already implemented the class that communicate with my MongoDB Atlas, So I also have functions in Python that updates the MongoDB.
Finally, how to upload the files from user input in Android app to Cloud Storage through my Python functions. And how to download files from Cloud Storage to Android app through my Python functions.
I just started using PYTHON and now i want to run a google vision cloud app on the server but I'm not sure how to start.
I do have a server up and running at http://18.217.137.107 and the app source code looks like https://cloud.google.com/vision/docs/detecting-landmarks#vision-landmark-detection-python.
Any help would be greatly appreciated.
What you need is a webapp built on some framework like django/flask. You can find a basic app example in the following link:
Create a basic GCP app using Flask
Please refer to this documentation about deploying Python application using Cloud Storage to App Engine Flex. Also, you might find this documentation to make an HTTP Request to Google Cloud Vision API useful, but this is based on Java and not Python.
I am new to Azure, and I want to use their billing API (especially Azure Resource Usage). And I hope I can use python to better support the whole project.
Thus, the sample code of Billing API is written in C#, which is not really helpful for me.
I have researched into the Azure Python SDK (http://azure-sdk-for-python.readthedocs.io/en/latest/index.html) for the whole day, but I did not find the class related to the billing API.
I am wondering whether I can find a Python library to call Billing API and help me monitor the usage of the Azure VM?
Appreciate for the help!
It seems that the Billing APIs haven't been implemented into Azure SDK for Python currently.
However, there is the similar requirement with you asked at the GitHub repository of Azure SDK for Python, refer to issue #600. And the MS engineer has answered the issue about the plan of the Azure Python SDK for Billing APIs.
You can monitor the issue thread on GitHub for any update of the SDK.
I'm trying to set up a basic python-based google app engine site that allows users to upload files to google cloud storage (mostly images)
I've been going through the documentation for the JSON API and the GCS client library overview (as well as blobstore etc) and still don't have a good handle on which is the best method and how they are related. Would be great if someone could give an overview of this or point me to some resources I can check out
Also, any sample code that's relevant would be really helpful. I've been able to run the upload samples here but not sure if they're useful for an app engine setup: https://github.com/GoogleCloudPlatform/storage-file-transfer-json-python
Thanks!!
Google Cloud Storage has two APIs -- the XML API and the JSON API. The XML API is XML based and very like the Amazon S3 API. The JSON API is similar to many other Google APIs, and it works with the standard Google API client libraries (for example, the Google API Python library). Both of these APIs can be used from anywhere, with or without App Engine, and are based on RESTful HTTP calls.
App Engine provides a couple of standard ways to access Google Cloud Storage. The first is built into App Engine's API as a feature called the "Google Cloud Storage Python API". This does not directly use either the XML or the JSON API. It's deprecated and no longer recommended.
The second App Engine library is called the "Google Cloud Storage
Python Client Library" and is not part of the core App Engine API. Instead, it's a Python library put out by Google that you can download and add to your application like any other library. This library happens to be implemented using the XML API. It provides a few extra features that are useful for App Engine users, such as the ability to serialize an upload while it's in progress. There's an example of using this library included as part of the download, in the python/demo directory. You can also see it online.
Equivalents of these tools also exist in Java and Go.
There's no need for users to use the App Engine-specific libraries unless they find them to be useful. The standard Python library or even just hand-written HTTP calls using urlfetch will work just as well. The App Engine library merely provides some useful extras for App Engine users.
App Engine also have a "Blobstore Python API". This is a feature specific to App Engine and distinct from Google Cloud Storage, except that it provides a few hooks into Google Cloud Storage, such as the ability to store files in Google Cloud Storage using the Blobstore API.
GAE documentation mentions that client api needs to be installed in the project folder. Does this need to be uploaded to GAE along with the project code or does GAE has the libraries available on their servers (in the same manner they support PIL, django, lxml, etc).
Sorry if this is a pedestrian question ? (I am also wondering why would they not bundle them into the developer SDK ? My question partly ensues from the fact that Google Cloud Storage API needs to be downloaded in the Python folder).
Yes, you have to upload the lib.
See this Gist with an explanation on how to use the GAE cloud storage client with Python in GAE production and development.