All Projects → TulevaEE → onboarding-service

TulevaEE / onboarding-service

Licence: MIT license
Backend Onboarding Service for Tuleva

Programming Languages

groovy
2714 projects
java
68154 projects - #9 most used programming language
HTML
75241 projects

Projects that are alternatives of or similar to onboarding-service

job-dsl-sample
Jenkins Job DSL Sample Project
Stars: ✭ 32 (+52.38%)
Mutual labels:  spock
RISKIM
Assets' Risk Management Using Mean-Variance Opt Based On Mult-Factors Trending Prediction
Stars: ✭ 25 (+19.05%)
Mutual labels:  funds
spring-spock-integration-testing
How to inject Spock mocks into Spring integration tests
Stars: ✭ 17 (-19.05%)
Mutual labels:  spock
ark-invest-api
📈 API for tracking holdings and trades of ARK Invest funds
Stars: ✭ 49 (+133.33%)
Mutual labels:  funds
JGetFund
Mac OS 开机自动执行脚本,爬取基金数据。
Stars: ✭ 15 (-28.57%)
Mutual labels:  funds
spock
Automatically perform git commits, pushes, and other cli actions when Statamic content changes
Stars: ✭ 96 (+357.14%)
Mutual labels:  spock
bankster
Money Creation Made Easy
Stars: ✭ 30 (+42.86%)
Mutual labels:  funds
springmock
alternative spring mocking infrastructure
Stars: ✭ 22 (+4.76%)
Mutual labels:  spock
rebalance-app
💸 Optimal lazy portfolio rebalancing calculator (in Rust)
Stars: ✭ 37 (+76.19%)
Mutual labels:  funds
spring-boot-web-application-sample
Real World Spring Boot Web Application Example with tons of ready to use features
Stars: ✭ 143 (+580.95%)
Mutual labels:  spock
OtripleS
This is an open source schooling system, dedicated to provide a better experience for schools needing a management and communication and tutoring system all in one place. This project is aiming toward directing all the software development funds and hours to families in need, the idea of the project is to allow schools to use the system as long …
Stars: ✭ 273 (+1200%)
Mutual labels:  funds
junit2spock
JUnit test to Spock test converter
Stars: ✭ 15 (-28.57%)
Mutual labels:  spock
SmaRP
Shiny app for projecting retirement funds / benefits
Stars: ✭ 17 (-19.05%)
Mutual labels:  pension
gathering
A self hosted website for announcing group events
Stars: ✭ 39 (+85.71%)
Mutual labels:  spock
funblog
A simple blog software written in Haskell
Stars: ✭ 84 (+300%)
Mutual labels:  spock
geb-mobile
A geb navigator factory for mobile support for Appium, Selendroid and IosDriver
Stars: ✭ 18 (-14.29%)
Mutual labels:  spock
esteem
eSteem Mobile - Application for Android and iOS users, start earning cryptocurrency!
Stars: ✭ 88 (+319.05%)
Mutual labels:  funds
fishing-funds
基金,大盘,股票,虚拟货币状态栏显示小应用,基于Electron开发,支持MacOS,Windows,Linux客户端,数据源来自天天基金,蚂蚁基金,爱基金,腾讯证券,新浪基金等
Stars: ✭ 424 (+1919.05%)
Mutual labels:  funds
sensor.avanza stock
Custom component to get stock data from Avanza for Home Assistant
Stars: ✭ 30 (+42.86%)
Mutual labels:  funds

Onboarding-service

CircleCI Known Vulnerabilities codecov

Architecture

Tuleva Architecture

Prerequisites

  • JDK 17
  • Groovy
  • Git
  • Gradle
  • Lombok
  • IntelliJ
  • Docker

Tech stack

Database

PostgreSQL

Running locally with Docker: docker-compose up database -d

Spring Profile

IMPORTANT: Set your Spring active profile to dev - this will also run DB schema/dev data migration

Backend

Java 17, Spring Boot, Gradle, Spock for testing

Running locally: ./gradlew bootRun

Frontend

React, TypeScript, scss, custom bootstrap, react-testing-library

Exception Monitoring

Sentry

Analytics

Google Analytics / Mixpanel

Hosting

AWS Elastic BeanStalk: EC2 and ELB

Continuous Integration

CircleCI

Production Logs

Papertrail

API

Authentication: oAuth2 with Mobile-ID, ID-card and Smart-ID

Swagger UI

Postman API collection (outdated)

Build pipeline

Production: Merge GitHub pull request to master -> build in CircleCI -> auto-redeploy (if build is green)

How to add new pension funds?

  1. Add the new fund to the funds database table.

Development notes

Code style: Java, Kotlin

If you don't want to run epis-service, then you can mock TransferExchangeService.java, which calls epis-service.

Common Issues

error="unsupported_grant_type", error_description="Unsupported grant type: mobile_id"

Make sure you are running against the right backend environment (dev or prod).

  • If you do npm run develop your package.json must proxy to http://localhost:9000
  • If you do npm run develop-production your package.json must proxy to https://onboarding-service.tuleva.ee

Known Issues

  • Digital signing does not work in the dev environment. Use the production configuration to test it locally. See DigiDocConfiguration.digiDocConfigDev() and smartid.hostUrl, smartid.relyingPartyUUID, smartid.relyingPartyName config values in application.yml and change them to production values. Use VPN for testing.

Caveats

When updating Spring Boot, sometimes you need to remove all of the existing access tokens from the oauth_access_token database table. However, there's one special token granted for tuleva.ee which allows it to fetch Fund NAV values and register new users. In order to generate a new token, you need to: token by

curl --location --request POST 'https://pension.tuleva.ee/api/oauth/token' \
--header 'Authorization: Basic <base64 of client_id:client_secret>' \
--data-urlencode 'grant_type=client_credentials' \
--data-urlencode 'client_id=tuleva.ee'

and then update the token values in the WordPress Tuleva template.

Testing ID-card Locally

In order to test ID-card locally, you need to run nginx locally with the right certificates and the right domain names.

  1. Add tuleva certs to ./nginx (4 files)
  2. Update $frontend and $backend urls in etc/eb/.ebextensions/nginx/conf.d/01_ssl_proxy.conf
  3. Add to hosts file:
    127.0.0.1 id.tuleva.ee
    127.0.0.1 pension.tuleva.ee
    127.0.0.1 onboarding-service.tuleva.ee
    
  4. Run nginx with docker: docker-compose up nginx
  5. Add DANGEROUSLY_DISABLE_HOST_CHECK=true to .env in onboarding-client
  6. add server.servlet.session.cookie.domain: tuleva.ee to application.yml
  7. Test through https://pension.tuleva.ee
  8. Later, don't forget to clean up your hosts file

References

hwcrypto.js

hwcrypto Sequence Diagram

Test Authentication Methods

Test Mobile ID

Test ID Card

Test Smart ID

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].