- Building Serverless Python Web Services with Zappa
- Abdulwahid Abdulhaque Barguzar
- 248字
- 2021-07-16 18:16:13
Installing and configuring Zappa
Installing Zappa is a straightforward task, but before we move ahead, we need to configure the prerequisites. Make sure you have Python 2.7 or Python 3.6 and have a valid AWS account. Now, you need to configure the AWS credentials on your machine with help awscli:
$ pip install awscli
Configure the AWS credentials using the aws configure command, as shown in the following screenshot:

The configuration for AWS credentials requires that you have an AWS Access Key ID, AWS Secret Access Key, Default region name, and a Default output format.
You can get AWS credential information from your My Security Credentials page, as shown in the following screenshot:

Once you've configured your AWS credentials, we can move ahead with Zappa's installation.
Zappa must be installed in a virtual environment. It's strongly recommended that you create a virtual environment and activate it before installing Zappa. I prefer to use the virtualenv tool. There are other tools available to manage your virtual environments:
$ virtualenv env -p python3.6
Here, we are creating a virtual environment named env and using python3.6, where -p indicates the Python version. Now, activate the virtual environment as follows:
$ source env/source/bin
We are set to go now, so let's install Zappa using pip:
$ pip install zappa
Now, we are ready to launch Zappa. In the following sections, we will be creating a small program to demonstrate how we can make Zappa's deployment serverless.
- Modern JavaScript Web Development Cookbook
- CorelDRAW X6 中文版圖形設(shè)計(jì)實(shí)戰(zhàn)從入門到精通
- C++黑客編程揭秘與防范
- 物聯(lián)網(wǎng)安全:理論、實(shí)踐與創(chuàng)新
- 智能網(wǎng)聯(lián)汽車V2X與智能網(wǎng)聯(lián)設(shè)施I2X
- 重新定義Spring Cloud實(shí)戰(zhàn)
- 面向物聯(lián)網(wǎng)的嵌入式系統(tǒng)開發(fā):基于CC2530和STM32微處理器
- PLC、現(xiàn)場(chǎng)總線及工業(yè)網(wǎng)絡(luò)實(shí)用技術(shù)速成
- CCNP TSHOOT(642-832)認(rèn)證考試指南
- 通信原理及MATLAB/Simulink仿真
- INSTANT KineticJS Starter
- SAE原理與網(wǎng)絡(luò)規(guī)劃
- 網(wǎng)絡(luò)AI+:2030后的未來網(wǎng)絡(luò)
- 云工廠:開啟中國制造云時(shí)代
- Web用戶查詢?nèi)罩就诰蚺c應(yīng)用