Skip to content

Commit

Permalink
Merge pull request #290 from Sunbird-RC/release-2.0.0
Browse files Browse the repository at this point in the history
Release Candidate for 2.0.0
  • Loading branch information
srprasanna authored Feb 27, 2024
2 parents cfe5c78 + 69194d3 commit ab7ea6c
Show file tree
Hide file tree
Showing 1,346 changed files with 32,669 additions and 246,656 deletions.
3 changes: 2 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
**/node_modules
**/build
**/build
**/dist
32 changes: 31 additions & 1 deletion .env
Original file line number Diff line number Diff line change
@@ -1 +1,31 @@
RELEASE_VERSION=v1.0.0
RELEASE_VERSION=v2.0.0-rc1
KEYCLOAK_SECRET=**********

# vault service
VAULT_ADDR=http://0.0.0.0:8200
VAULT_API_ADDR=http://0.0.0.0:8200
VAULT_ADDRESS=http://0.0.0.0:8200

# identity service
VAULT_ADDR=http://vault:8200
VAULT_TOKEN=
VAULT_BASE_URL=http://vault:8200/v1
VAULT_ROOT_PATH=http://vault:8200/v1/kv
VAULT_TIMEOUT=5000
VAULT_PROXY=false
SIGNING_ALGORITHM=Ed25519Signature2020
JWKS_URI=
ENABLE_AUTH=false
WEB_DID_BASE_URL=https://example.com/identifier

# credential schema service
IDENTITY_BASE_URL=http://identity:3332
JWKS_URI=
ENABLE_AUTH=false

# credential service
IDENTITY_BASE_URL=http://identity:3332
SCHEMA_BASE_URL=http://schema:3333
CREDENTIAL_SERVICE_BASE_URL=https://example.com/credentials
JWKS_URI=
ENABLE_AUTH=false
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -88,5 +88,6 @@ out

.ipynb_checkpoints
db-data*
vault-data
es-data*
keycloak-mobile*.jar
12 changes: 0 additions & 12 deletions Dockerfile

This file was deleted.

64 changes: 25 additions & 39 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,77 +1,60 @@
#SOURCES = $(wildcard java/**/*.java)
rwildcard=$(wildcard $1$2) $(foreach d,$(wildcard $1*),$(call rwildcard,$d/,$2))
SOURCES := $(call rwildcard,java/,*.java)
RELEASE_VERSION = v1.0.0
IMAGES := ghcr.io/sunbird-rc/sunbird-rc-core ghcr.io/sunbird-rc/sunbird-rc-nginx ghcr.io/sunbird-rc/sunbird-rc-context-proxy-service \
ghcr.io/sunbird-rc/sunbird-rc-public-key-service ghcr.io/sunbird-rc/sunbird-rc-keycloak ghcr.io/sunbird-rc/sunbird-rc-certificate-api \
ghcr.io/sunbird-rc/sunbird-rc-certificate-signer ghcr.io/sunbird-rc/sunbird-rc-notification-service ghcr.io/sunbird-rc/sunbird-rc-claim-ms \
ghcr.io/sunbird-rc/sunbird-rc-digilocker-certificate-api ghcr.io/sunbird-rc/sunbird-rc-bulk-issuance ghcr.io/sunbird-rc/sunbird-rc-metrics \
ghcr.io/sunbird-rc/id-gen-service ghcr.io/sunbird-rc/encryption-service
RELEASE_VERSION = v2.0.0-rc1
IMAGES := ghcr.io/sunbird-rc/sunbird-rc-core ghcr.io/sunbird-rc/sunbird-rc-claim-ms \
ghcr.io/sunbird-rc/sunbird-rc-notification-service ghcr.io/sunbird-rc/sunbird-rc-metrics \
ghcr.io/sunbird-rc/id-gen-service ghcr.io/sunbird-rc/encryption-service \
ghcr.io/sunbird-rc/sunbird-rc-identity-service ghcr.io/sunbird-rc/sunbird-rc-credential-schema \
ghcr.io/sunbird-rc/sunbird-rc-credentials-service
build: java/registry/target/registry.jar
echo ${SOURCES}
rm -rf java/claim/target/*.jar
cd target && rm -rf * && jar xvf ../java/registry/target/registry.jar && cp ../java/Dockerfile ./ && docker build -t ghcr.io/sunbird-rc/sunbird-rc-core .
make -C java/claim
make -C services/certificate-api docker
make -C services/certificate-signer docker
make -C services/notification-service docker
make -C deps/keycloak build
make -C services/public-key-service docker
make -C services/context-proxy-service docker
make -C services/metrics docker
make -C services/digilocker-certificate-api docker
make -C services/bulk_issuance docker
make -C services/id-gen-service docker
make -C services/encryption-service docker
docker build -t ghcr.io/sunbird-rc/sunbird-rc-nginx .
make -C services/identity-service/ docker
make -C services/credential-schema docker
make -C services/credentials-service/ docker


java/registry/target/registry.jar: $(SOURCES)
echo $(SOURCES)
sh configure-dependencies.sh
cd java && ./mvnw clean install

test: build
@docker-compose down
@docker-compose -f docker-compose-v1.yml down
@rm -rf db-data* || echo "no permission to delete"
# test with distributed definition manager and native search
@docker-compose --env-file test_environments/test_with_distributedDefManager_nativeSearch.env up -d db keycloak registry certificate-signer certificate-api redis
@docker-compose -f docker-compose-v1.yml --env-file test_environments/test_with_distributedDefManager_nativeSearch.env up -d db keycloak registry certificate-signer certificate-api redis
@echo "Starting the test" && sh build/wait_for_port.sh 8080
@echo "Starting the test" && sh build/wait_for_port.sh 8081
@docker-compose ps
@docker-compose -f docker-compose-v1.yml ps
@curl -v http://localhost:8081/health
@cd java/apitest && ../mvnw -Pe2e test
@docker-compose down
@docker-compose -f docker-compose-v1.yml down
@rm -rf db-data-1 || echo "no permission to delete"
# test with kafka(async), events, notifications,
@docker-compose --env-file test_environments/test_with_asyncCreate_events_notifications.env up -d db es clickhouse redis keycloak registry certificate-signer certificate-api kafka zookeeper notification-ms metrics
@docker-compose -f docker-compose-v1.yml --env-file test_environments/test_with_asyncCreate_events_notifications.env up -d db es clickhouse redis keycloak registry certificate-signer certificate-api kafka zookeeper notification-ms metrics
@echo "Starting the test" && sh build/wait_for_port.sh 8080
@echo "Starting the test" && sh build/wait_for_port.sh 8081
@docker-compose ps
@docker-compose -f docker-compose-v1.yml ps
@curl -v http://localhost:8081/health
@cd java/apitest && MODE=async ../mvnw -Pe2e test
@docker-compose down
@docker-compose -f docker-compose-v1.yml down
@rm -rf db-data-2 || echo "no permission to delete"
# test with fusionauth
@docker-compose --env-file test_environments/test_with_fusionauth.env -f docker-compose.yml -f services/sample-fusionauth-service/docker-compose.yml up -d db es fusionauth fusionauthwrapper
sleep 20
@echo "Starting the test" && sh build/wait_for_port.sh 9011
@echo "Starting the test" && sh build/wait_for_port.sh 3990
sleep 20
@docker-compose --env-file test_environments/test_with_fusionauth.env -f docker-compose.yml -f services/sample-fusionauth-service/docker-compose.yml up -d --no-deps registry
@echo "Starting the test" && sh build/wait_for_port.sh 8081
@docker-compose -f docker-compose.yml -f services/sample-fusionauth-service/docker-compose.yml ps
@curl -v http://localhost:8081/health
@cd java/apitest && MODE=fusionauth ../mvnw -Pe2e test || echo 'Tests failed'
@docker-compose -f docker-compose.yml -f services/sample-fusionauth-service/docker-compose.yml down
@rm -rf db-data-3 || echo "no permission to delete"
make -C services/certificate-signer test
make -C services/public-key-service test
make -C services/context-proxy-service test
make -C services/bulk_issuance test
# make -C services/identity-service test
# make -C services/credential-schema test
# make -C services/credentials-service test

clean:
@rm -rf target || true
@rm java/registry/target/registry.jar || true

release: test
for image in $(IMAGES); \
do \
Expand All @@ -80,4 +63,7 @@ release: test
docker push $$image:latest;\
docker push $$image:$(RELEASE_VERSION);\
done
@cd tools/cli/ && npm publish
@cd tools/cli/ && npm publish

compose-init:
bash setup_vault.sh docker-compose.yml vault
31 changes: 28 additions & 3 deletions api-documentation/issue-api.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -184,11 +184,30 @@ paths:
'appliation/json':
schema:
$ref: '#/components/schemas/verifyResponse'
/revocation-list:
/credentials/revocation-list:
get:
tags:
- Revocation
summary: Complete list of revoked credentials (Need to be discussed).
summary: Complete list of revoked credentials (Need to be discussed)
parameters:
- name: issuerId
in: query
description: The ID of the issuer
required: true
schema:
type: string
- name: page
in: query
description: The page number
required: true
schema:
type: string
- name: limit
in: query
description: The limit of items per page
required: true
schema:
type: string
responses:
200:
description: OK
Expand All @@ -197,7 +216,13 @@ paths:
schema:
type: array
items:
type: object
type: object
404:
description: Not Found
content: {}
500:
description: Error
content: {}
components:
schemas:
revokedResponse:
Expand Down
1 change: 1 addition & 0 deletions deps/Readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Keycloak moved to https://github.com/Sunbird-RC/sunbird-rc-keycloak

This file was deleted.

Binary file not shown.

This file was deleted.

7 changes: 0 additions & 7 deletions deps/keycloak-mobile-number-login-spi/Makefile

This file was deleted.

21 changes: 0 additions & 21 deletions deps/keycloak-mobile-number-login-spi/README.md

This file was deleted.

2 changes: 0 additions & 2 deletions deps/keycloak-mobile-number-login-spi/build.sh

This file was deleted.

Loading

0 comments on commit ab7ea6c

Please sign in to comment.