Last active
August 2, 2022 07:49
-
-
Save anka/f4a9a5f15e86c92ab39037ce5b09cd13 to your computer and use it in GitHub Desktop.
Workaround for running a Python Azure Function locally on an M1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Install Python | |
brew install python@3.9 | |
# Install NVM | |
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | bash | |
# Update/check your source files (.zshrc, .bashrc, etc.) | |
export PATH="~/.nvm/current/bin:$PATH" | |
# Install specific Node version | |
nvm install 14.17.6 | |
# Install gRPC package | |
pip3 install grpcio | |
# Install Azure Function Tools | |
npm install azure-functions-core-tools@4.0.4483 | |
# Override cygrpc package | |
cp /opt/homebrew/lib/python3.9/site-packages/grpc/_cython/cygrpc.cpython-39-darwin.so ~/.nvm/versions/node/v14.17.6/lib/node_modules/azure-functions-core-tools/bin/workers/python/3.9/OSX/X64/grpc/_cython/cygrpc.cpython-39-darwin.so |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment