This GitHub Action scans your repository to detect whether specific AWS services are being used. It checks for code or configuration files commonly associated with:
- AWS Lambda (Python, JavaScript, TypeScript)
- AWS Glue (Python)
- Step Functions (ASL JSON)
- Lambda Layers (Python, JavaScript, TypeScript)
Use this in CI workflows to inform deployment steps, enforce compliance, or audit infrastructure.
- Detects Lambda code in
lambda/src
- Detects Glue scripts in
glue/script
- Detects Step Functions definitions in
state-machine
- Scans
python-layer
for Lambda Layer languages - Outputs structured JSON with all detected services
Name | Description |
---|---|
services-used |
JSON object showing which AWS services were found |
{
"lambda-python": true,
"lambda-js": false,
"lambda-ts": true,
"glue-python": true,
"state-machine": false,
"python-layer-python": false,
"python-layer-js": false,
"python-layer-ts": true
}
name: Detect AWS Services
on:
push:
branches: [main]
jobs:
detect-services:
runs-on: ubuntu-latest
steps:
- name: Checkout Code
uses: actions/checkout@v4
- name: Scan AWS Services
id: scan
uses: subhamay-bhattacharyya-gha/scan-aws-services-action@main
- name: Print Output
run: echo "Detected Services: ${{ steps.scan.outputs.services-used }}"
To test or develop this action locally:
- Clone the repo
- Run
node main.js
from the project root - Ensure the expected folders (
lambda/src
,glue/script
, etc.) exist for testing - Review the console output for service detection results
You can also test it inside a GitHub workflow by referencing the action locally:
- name: Test Local Action
uses: ./ # Use local path for testing
We welcome contributions! You can help by:
- Reporting bugs
- Suggesting features
- Writing docs
- Submitting PRs
Check out the CONTRIBUTING.md guide to get started. Please also read our Code of Conduct.
See CHANGELOG.md for release notes.
Latest versions:
v1.0.1
: Added pre-commit hooksv1.0.0
: Initial release
This project is licensed under the MIT License. See LICENSE for details.