Skip to content

Commit f0b75e1

Browse files
committed
Upd sonar link in readme
1 parent 6ed7005 commit f0b75e1

File tree

1 file changed

+30
-37
lines changed

1 file changed

+30
-37
lines changed

README.md

Lines changed: 30 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -2,34 +2,30 @@
22

33
[![Lifecycle:Stable](https://img.shields.io/badge/Lifecycle-Stable-97ca00?style=for-the-badge)](https://github.com/bcgov/repomountie/blob/master/doc/lifecycle-badges.md)
44
[![GitHub Workflow Status (branch)](https://img.shields.io/github/actions/workflow/status/bcgov/api-services-portal/ci-build-deploy.yaml?branch=dev&style=for-the-badge)](https://github.com/bcgov/api-services-portal/actions/workflows/ci-build-deploy.yaml)
5-
[![Coverage](https://img.shields.io/sonar/coverage/aps-portal/dev?server=https%3A%2F%2Fsonarcloud.io&style=for-the-badge)](https://sonarcloud.io/summary/new_code?id=aps-portal)
5+
[![Coverage](https://img.shields.io/sonar/coverage/aps-portal-e2e/dev?server=https%3A%2F%2Fsonarcloud.io&style=for-the-badge)](https://sonarcloud.io/summary/overall?id=aps-portal-e2e)
66
![GitHub](https://img.shields.io/github/license/bcgov/aps-portal?style=for-the-badge)
77
![GitHub tag (latest by date)](https://img.shields.io/github/v/tag/bcgov/aps-portal?label=release&style=for-the-badge)
88

9-
109
## Introduction
1110

12-
1311
The `API Services Portal` is a frontend for API Providers to manage the lifecycle of their APIs and for Developers to discover and access these APIs. It works in combination with the Kong Community Edition Gateway and Keycloak IAM solution.
1412

15-
1613
## Local Deployment
1714

18-
19-
The repo is setup to create a local deployment of the Portal along with required support services (Postgres, Keycloak, OAuth2-proxy, Feeder and Kong Gateway) using `docker compose`.
15+
The repo is setup to create a local deployment of the Portal along with required support services (Postgres, Keycloak, OAuth2-proxy, Feeder and Kong Gateway) using `docker compose`.
2016

2117
1. Clone and build the [Gateway Admin API](https://github.com/bcgov/gwa-api) (gwa-api)
2218

23-
```
24-
git clone https://github.com/bcgov/gwa-api
25-
cd ./microservices/gatewayApi
26-
docker build -t gwa-api:e2e .
27-
```
19+
```
20+
git clone https://github.com/bcgov/gwa-api
21+
cd ./microservices/gatewayApi
22+
docker build -t gwa-api:e2e .
23+
```
2824

2925
1. Build: Back in `api-services-portal`, run `docker compose build`.
3026
1. Run: `docker compose up`. Wait for startup to complete - look for `Swagger UI registered`.
3127
1. The Portal is now live at http://oauth2proxy.localtest.me:4180
32-
1. To login, use username `janis@idir` and password `awsummer` (or username `local` and password `local`).
28+
1. To login, use username `janis@idir` and password `awsummer` (or username `local` and password `local`).
3329
1. If you have made any changes to the app code, update images by running `docker compose build` then `docker compose up`.
3430
1. Clean up: `docker compose down` removes all the hosted services
3531

@@ -68,40 +64,39 @@ Use the following configuration to run the Portal locally (outside of Docker) ag
6864

6965
1. Follow [local deployment instructions](#local-deployment) and run `docker compose up`.
7066
1. In `/src` run `npm install`.
71-
1. If using Node version > 17, run `npm install --legacy-peer-deps`
67+
68+
1. If using Node version > 17, run `npm install --legacy-peer-deps`
7269

7370
1. Turn off the docker compose Portal: `docker stop apsportal`
7471
1. Configure the `oauth2-proxy` that is running in Docker:
75-
1. Update `upstreams` in `local/oauth2-proxy/oauth2-proxy-local.cfg` to include the IP address of your local machine, e.g. `upstreams=["http://172.100.100.01:3000"]`
76-
<br>You can obtain the IP address using `hostname -I`.
77-
78-
1. Restart the oauth2-proxy: `docker compose restart oauth2-proxy`
79-
1. Update `DESTINATION_URL` in `local/feeds/.env.local` to include the IP address of your local machine
80-
1. Restart the feeder: `docker compose restart feeder`
81-
1. Update `PORTAL_ACTIVITY_URL` in `local/gwa-api/.env.local` to include the IP address of your local machine
82-
1. Restart the feeder: `docker compose restart gwa-api`
83-
84-
72+
73+
1. Update `upstreams` in `local/oauth2-proxy/oauth2-proxy-local.cfg` to include the IP address of your local machine, e.g. `upstreams=["http://172.100.100.01:3000"]`
74+
<br>You can obtain the IP address using `hostname -I`.
75+
76+
1. Restart the oauth2-proxy: `docker compose restart oauth2-proxy`
77+
1. Update `DESTINATION_URL` in `local/feeds/.env.local` to include the IP address of your local machine
78+
1. Restart the feeder: `docker compose restart feeder`
79+
1. Update `PORTAL_ACTIVITY_URL` in `local/gwa-api/.env.local` to include the IP address of your local machine
80+
1. Restart the feeder: `docker compose restart gwa-api`
81+
8582
1. Start the Portal locally:
8683

87-
```sh
88-
cd src
89-
set -o allexport
90-
source ../.env.local
91-
LOG_LEVEL=debug
92-
KNEX_HOST=kong-db.localtest.me
93-
NEXT_PUBLIC_MOCKS=off
94-
set +o allexport
84+
```sh
85+
cd src
86+
set -o allexport
87+
source ../.env.local
88+
LOG_LEVEL=debug
89+
KNEX_HOST=kong-db.localtest.me
90+
NEXT_PUBLIC_MOCKS=off
91+
set +o allexport
9592

96-
npm run dev
97-
```
93+
npm run dev
94+
```
9895

9996
1. The Portal is now live at http://oauth2proxy.localtest.me:4180 and should auto-update on code changes.
10097

101-
10298
## Design
10399

104-
105100
The `API Services Portal` is a React application using the Chakra UI component library, and using two frameworks: KeystoneJS V5, and NextJS.
106101

107102
The application is divided up into the following six components:
@@ -176,10 +171,8 @@ Currently support feeders:
176171

177172
Source: `feeds`
178173

179-
180174
## Development
181175

182-
183176
### TypeScript
184177

185178
The client-side Next.js application uses TypeScript, and because it plays nicely with GraphQL types, uses a codegen to generate the API types.

0 commit comments

Comments
 (0)