Setup WSL2 Environment for Windows
Last updated
Last updated
Pre-requisite
OS: Windows 11
graphics cards installer compatible on your device
Steps
wsl --install
Install Ubuntu 20.04 LTS from Microsoft store
Note: This will be the default terminal that we will be using so make sure all the commands are run under Ubuntu terminal
Set
ssh-keygen -t ed25519 -C "your_email@example.com"
1. When you're prompted to "Enter a file in which to save the key," press Enter. This accepts the default file location.
2. At the prompt, type a secure passphrase.
go to the file directory where the ssh key is saved
/c/Users/you/.ssh/id_algorithm
Go to your Github settings > SSH Key & GPG Keys
then Paste the generated key under .ssh folder
Install Remote-wsl on your VSCode extension
run this command sudo apt update && sudo apt dist-upgrade
Clone Project repository using SSH
On your root folder run this command
Install inside wsl
Install
Configure aws
aws configure --profile identifi_qa
access key: AKIAR73M5IQAJDI7TGPN
secret key: sB0D0PY+ITY2cfy9UHNWG28XkIfHL//GFoNo3R2S
region: ap-southeast-1
output: json
Run aws login
run the following on your terminal Note: If you may encounter some unknown commands all you have to to is install it
Open the test folder directory of the project and install the following packages
Install required node version use in the project then check node and npm version
Run Docker command
docker-compose down
: to stop running the containers
docker-compose pull
: to pull the latest docker image of the project
docker-compose up -d
: to start and run the application
docker container ls
: to verify if the docker container is running
Check if you run able to run the test by running npx cypress open
Visit on your browser the project application: localhost:9000/login