QE Processes - JU-DEV-Bootcamps/ERAS GitHub Wiki
Purpose
Explain how QE work is done day-to-day
🚀 Deployment Process
Standardize QE responsibilities during deployment of changes to Development environment
Requirements:
- Have installed Ubuntu
- Have Installed DBeaver
Database Configuration
Process to configure the Database locally for development environment:
-
Have installed DBeaver 26.0.1 and open it
-
Create a new Connection with name postgres and the following configuration 5.1 Select PostgreSQL 5.2 Set Main tab Host 127.0.0.1 Database: postgress Username: eras_user Password: eras_password Show all databases: Checked 5.3 Set SSH tab Host/IP: 10.24.80.173 User Name: ubuntu Authentication Method: Public Key Private Key: [Search for test_act.pem to open key for dev environment]
-
Create a new database for with name:eras_db
Deployment steps (step-by-step):
-
Open Github and Navigate to ERAS Project Dashboard https://github.com/orgs/JU-DEV-Bootcamps/projects/2
-
Check that Ready for 'Testing > testing' column display any item(s)
-
Verify that there are pull requests pending to be deployed
-
Open DBeaver
-
Recreate eras_db.Delete eras_db and recreate it with the same name(This steps is done only if Data is corrupted or DB changes)
-
Ubuntu should be already installed
-
Open file explorer and type \wsl$
-
Navigate to \wsl.localhost\Ubuntu\home\lenny
-
Copy the test_act.pem key to this folder
-
Open Ubuntu terminal 6.1 Set Permissions:
Chmod 600 test_act.pem 6.2 Connect to the Dev environment:
ssh -i test_act.pem [email protected] 6.3 List the containers: docker ps 6.4 Stop docker containers of both Frontend and Backend docker stop ==> Frontend docker stop ==> Backend 6.5 Clean the containers stopped docker system prune -
Go back to GitHub
-
Navigate to Repositories and search for ERAS: https://github.com/JU-DEV-Bootcamps/ERAS
-
Click on Actions
-
Select Deploy process on runner https://github.com/JU-DEV-Bootcamps/ERAS/actions/workflows/stage_deploy_runner.yml
-
Expand 'Run Workflow' dropdown and set development branch Use Workflow from: develop Select the environment: develop
-
Click Run Workflow
-
Wait until deployment is completed successfully 12-20 mins approximately
-
Open the development environment and verify it works as expected
If any issues: If deployment failed, inform to Technical Lead
Process to generate a new Key to be approved
- Navigate ERAS main repository https://github.com/JU-DEV-Bootcamps/ERAS
- Navigate to User navigation settings(top right section) > Settings
- Click on Developer settings
- Expand Personal access tokens
- Select Tokens(classic)
- Click 'Generate new token' > Generate New token (Fine-grained, repo-spoke)
- Configure token Name: [Token name]
- Description: e.g.: Eras Key to deploy Backend and Frontend
- Expiration: 30 days(! not possible to generate for more days)
- Repository access: All repositories
- Resource owner: JU-DEV-Bootcamps
- Set permission: Actions Read and write Variables Read-only Administration Read-only Artifact metadata Read-only Attestations Read-only Codespaces Read and write Codespaces lifecycle admin Read and write Codespaces metadata Read-only Codespaces secrets Read and write Contents Read-only Dependabot secrets Read-only Deployments Read and write Discussions Read-only Environments Read-only Issues Read-only Merge queues Read-only Metadata Read-only Pages Read-only Pull requests Read-only Secret scanning alert dismissal requests Read-only Repository security advisories Read-only Custom properties Read-only Webhooks Read-only Secret scanning alerts Read-only Secret scanning push protection bypass requests Read-only Secrets Read-only Code scanning alerts Read and write Commit statuses Read-only Dependabot alerts Read-only Workflows Read and write
- Click "Generate token"
- Send request for approval to Technical lead(Marcel)
- Once approved, 'copy the personal access token'. If needed regenerate the token for the key and copy it
- Navigate to Settings page of Main repository https://github.com/JU-DEV-Bootcamps/ERAS/settings
- Select 'Secret and variables'> Actions
- Search in the 'Repository secrets' for PAT_TOKEN
- Click on edit of PAT_TOKEN item and paste the token generated, then click on 'Update secret'