Deploy Firebase Python Resources
ActionsTags
(2)A GitHub Action for deploying Python-based Firebase Cloud Functions. This repository serves as both the action implementation and a live example of its usage.
- 🐍 Python dependency management from pyproject.toml
- 🔐 Secure handling of service account credentials
- Detailed deployment summaries
Basic usage:
- uses: digital-wisdom/deploy-firebase-python@v1
with:
project_id: my-firebase-project
service_account_json: ${{ secrets.FIREBASE_SERVICE_ACCOUNT }}
deploy_command: "firebase deploy --only functions"- uses: digital-wisdom/deploy-firebase-python@v1
with:
project_id: my-firebase-project
service_account_json: ${{ secrets.FIREBASE_SERVICE_ACCOUNT }}- uses: digital-wisdom/deploy-firebase-python@v1
with:
project_id: my-firebase-project
service_account_json: ${{ secrets.FIREBASE_SERVICE_ACCOUNT }}
deploy_command: "firebase deploy --only functions:api,functions:webhook"- uses: digital-wisdom/deploy-firebase-python@v1
with:
service_account_json: ${{ secrets.FIREBASE_SERVICE_ACCOUNT }}
deploy_command: "make deploy-staging"- uses: digital-wisdom/deploy-firebase-python@v1
with:
service_account_json: ${{ secrets.FIREBASE_SERVICE_ACCOUNT }}
functions_dir: "backend/functions"
project_id: my-firebase-project| Input | Description | Required | Default |
|---|---|---|---|
service_account_json |
Firebase service account JSON | Yes | N/A |
deploy_command |
Deployment command to execute | No | firebase deploy --only functions |
project_id |
Firebase project ID (runs firebase use if specified) |
No | N/A |
functions_dir |
Directory with pyproject.toml (creates requirements.txt if missing) | No | functions |
- Firebase service account key
- requirements.txt or pyproject.toml in functions_dir
The action automatically sets up:
GOOGLE_APPLICATION_CREDENTIALS: Points to the service account file- Firebase project configuration via
firebase use
- Service account credentials are securely handled and cleaned up
- Credentials file is automatically removed after deployment
- Uses GitHub's secure token handling
This action follows semantic versioning. You can use it in three ways:
- Major version:
@v1- Recommended for stability- uses: digital-wisdom/deploy-firebase-python@v1
- Specific version:
@v1.0.0- Pinned to exact version- uses: digital-wisdom/deploy-firebase-python@v1.0.0
- Branch:
@main- Latest changes (not recommended for production)- uses: digital-wisdom/deploy-firebase-python@main
Contributions are welcome! Please follow these guidelines:
-
Use Conventional Commits for commit messages:
feat: add new featurefix: resolve bugdocs: update documentationchore: maintenance tasks
-
Changes will automatically:
- Generate release notes
- Update the changelog
- Create a new version
- Update major version tag
This project is licensed under the MIT License - see the LICENSE file for details.
Deploy Firebase Python Resources is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.