Skip to content

Latest commit

 

History

History
49 lines (40 loc) · 1.63 KB

DEVELOPER.md

File metadata and controls

49 lines (40 loc) · 1.63 KB

Service Screener Developer Guide

Preparation on Mac environment

## Install homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
# PLEASE READ
# FOLLOW THE 'NEXT STEP' shows after installation
# THERE ARE 2 COMMANDS TO COPY/PASTE to set the environment variables correctly

## Install Python, and set the alias in ~/.zprofile or ~/.bash_profile
brew install [email protected]
which python3.12
alias python3=... <to the path above>, #also setup this in ~/.zprofile?

## Install AWS CLI
curl "https://awscli.amazonaws.com/AWSCLIV2.pkg" -o "AWSCLIV2.pkg"
sudo installer -pkg AWSCLIV2.pkg -target /

# Setup AWS Profile
aws configure --profile ss

# Setup before running screener command
python3 -m venv .
source bin/activate
python3 -m pip install --upgrade pip
pip install -r requirements.txt
alias screener="python3 $(pwd)/main.py"

## When executing SS locally
screener --regions ap-southeast-1 --profile ss

## TROUBLESHOOTING
# 1/ For some odd cases, where modules install but venv shows 'module not found', has to force refresh python module by
#    executing help("modules") command
% python
>>> help("modules")
>>> import boto3

Pre-requisite

  1. Login to your Git account
  2. Fork the master repository from aws-samples
  3. git clone
  4. setup aws-cli follows aws official documentation: https://docs.aws.amazon.com/cli/latest/userguide/getting-started-install.html
  5. Setup necessary IAM Users with readOnly permission.
  6. Generate Accesskey & Secret combination to be used by local machine
  7. Run aws configure --profile <name> and follow through the setup wizard