Linux is the preferred operating system to use while contributing to GCP Scanner. If you're using Windows, we recommend setting up Windows Subsystem for Linux.
- Have
pythoninstalled on your system. Check out this link to download. - have
gitinstalled on your system.
Install the package using pip
pip install gcp-scannerCheck if installation was done correctly
gcp-scanner --help-
Open the Terminal & Clone the project using
git clone https://github.com/google/gcp_scanner.git
-
Then,
cd gcp_scanner -
Create a Virtual Environment to install all your dependencies with
- on linux or wsl:
python3 -m venv venv
- on windows:
python -m venv venv
- on MacOS :
python3 -m venv venv
-
Activate the Virtual Environment with
- on linux or wsl:
source venv/bin/activate- on windows:
.\venv\Scripts\activate
- on MacOS:
source venv/bin/activate -
Install all dependencies using
pip install -r requirements.txt
-
If you want to install the visualization tool (you should have node.js already installed) then run
cd visualization_tool npm install npm run build cd ..
-
Install the tool in your local machine
pip install . -
Run to check if the tool was installed correctly
gcp-scanner --help
There is a docker build file if you want to run the scanner from a container:
docker build -f Dockerfile -t sa_scanner .