Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/Azure-Samples/cosmos-db-nosql-python-quickstart
Quickstart application template for Azure Cosmos DB for NoSQL and Python
https://github.com/Azure-Samples/cosmos-db-nosql-python-quickstart
azd-templates azure azure-dev cosmos-db python
Last synced: 3 months ago
JSON representation
Quickstart application template for Azure Cosmos DB for NoSQL and Python
- Host: GitHub
- URL: https://github.com/Azure-Samples/cosmos-db-nosql-python-quickstart
- Owner: Azure-Samples
- License: mit
- Created: 2023-12-12T13:34:02.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-10-18T01:02:00.000Z (4 months ago)
- Last Synced: 2024-10-19T13:25:28.845Z (4 months ago)
- Topics: azd-templates, azure, azure-dev, cosmos-db, python
- Language: Bicep
- Homepage: https://learn.microsoft.com/azure/cosmos-db/nosql/quickstart-python
- Size: 151 KB
- Stars: 4
- Watchers: 23
- Forks: 7
- Open Issues: 1
-
Metadata Files:
- Readme: readme.md
- Contributing: .github/CONTRIBUTING.md
- License: LICENSE
- Code of conduct: .github/CODE_OF_CONDUCT.md
- Security: .github/SECURITY.md
Awesome Lists containing this project
README
---
page_type: sample
name: "Quickstart: Azure Cosmos DB for NoSQL and Azure SDK for Python"
description: This is a simple Flask web application to illustrate common basic usage of Azure Cosmos DB for NoSQL and the Azure SDK for Python.
urlFragment: template
languages:
- python
- azdeveloper
products:
- azure-cosmos-db
---# Quickstart: Azure Cosmos DB for NoSQL client library for Python
This is a simple Flask web application to illustrate common basic usage of Azure Cosmos DB for NoSQL's client library for Python. This sample application accesses an existing account, database, and container using the [`azure-cosmos`](https://pypi.org/project/azure-cosmos/) and [`azure-identity`](https://pypi.org/project/azure-identity/) packages from PyPi.
### Prerequisites
- [Docker](https://www.docker.com/)
- [Azure Developer CLI](https://aka.ms/azd-install)
- [Python 3.12](https://www.python.org/downloads/)### Quickstart
1. Log in to Azure Developer CLI.
```bash
azd auth login
```> [!TIP]
> This is only required once per-install.1. Initialize this template (`cosmos-db-nosql-python-quickstart`) using `azd init`
```bash
azd init --template cosmos-db-nosql-python-quickstart
```1. Ensure that **Docker** is running in your environment.
1. Use `azd up` to provision your Azure infrastructure and deploy the web application to Azure.
```bash
azd up
```1. Observed the deployed web application
![Screenshot of the deployed web application.](assets/web.png)