-
Notifications
You must be signed in to change notification settings - Fork 3
PDA IAM
pace edited this page Nov 5, 2020
·
3 revisions
- Java - 8+
- Git
- Gradle -6.4.1
- Maven 3.1.1(or newer)
Note: Before installing the application, we need to create 2 AWS buckets one private and one public. A step by step process to get a development environment up and running.
Get the application from the git repository.
git clone https://github.com/PDA-Open-Source/PDA-IAM.git
cd PDA-IAM
Copy the below list of configuration and add it to application.properties file inside src/main/resources folder, insert the values with proper configuration details.
#Keycloak Configuration
keycloak.principal-attribute=preferred_username
keycloak.auth-server-url=http://localhost:8080/auth/ #Keycloak URL
keycloak.realm=master
keycloak-client-id=admin-cli
keycloak.credentials.secret= #keycloak client secret key
keycloak-public-key= #keycloak realm Public key
client.granttype=password # Keycloak Grant Type
admin-user-username=admin # Keycloak login username
admin-user-password=admin # Keycloak login password
keycloak.resource=account
keycloak.bearer-only = true
#SpringBoot Setting
spring.main.allow-bean-definition-overriding=true
server.port=9090
server.url=http://localhost:9090/
#PDA Notification or session service and entity service url
notification.server.url=http://localhost:9091/api/v2/
entity.server.url=http://localhost:9092/api/v1/
#Registry Configuration
registry-base-url=http://localhost:8090/ # Registery base url
#redis
spring.cache.type=redis
spring.redis.host=localhost
spring.redis.port=6379
spring.cache.redis.profile.ttl=300000
spring.cache.redis.keycloak.ttl=100
#encrypt/decrypt values
salt-value= #In case to change the value refer PDA-WEB wiki
iv-value= #In case to change the value refer PDA-WEB wiki
secret-key= #In case to change the value refer PDA-WEB wiki
key-size=128
iteration-count=1000
#Logging Configuration
logging.level.root=info
log.location=
#Email SMTP configuration
mail-smtp-auth=mail.smtp.auth
mail-smtp-starttls-enable=mail.smtp.starttls.enable
mail-smtp-host=mail.smtp.host
smtp-gmail-com=smtp.gmail.com
mail-smtp-port=mail.smtp.port
port=587
sourcemailid=""
sourceemailpassword=""
#Reset password configuration
subject-reset-pwd=confirmation for reset password
email-content-reset-pwd=you successfully change your password please login with new password
#Verify email and create registry entry
subject-for-sign-up=Welcome to Learning platform
email-content-for-sign-up=Please Click on this link to complete your registration
register-url-text=Complete Registration
link-expiration-time-text=This link will expire in 12 hours
link-expiration-time=720
#Email verification for password update
subject-for-email-udpate= PDA - Verify your email address
email-content-for-email-update=You have requested for email updation. Please click here to complete the process.
email-update-url-text=Update Email
email-template-path=PDA-IAM/src/main/resources/templates/emailTemplate.html
email-template-path-phone-update=PDA-IAM/src/main/resources/templates/emailTemplate-update-phone.html
email-update-success=PDA-IAM/src/main/resources/templates/EmailChangeSucessful.html
email-update-unsuccessful=PDA-IAM/src/main/resources/templates/EmailChangeUnsucessful.html
#AWS s3 Configuration
aws-accesskey=""
aws-secretkey=""
aws-s3-bucket-name=""
aws-s3-url=""
aws-region=""
aws-qrcode=qr-code/
#name of the private bucket
aws-s3-bucket-name-private=""
#url of the private bucket
aws-s3-url-private=""
#App Version Configuration
AppversionIosParticipantForced=1.1.0
AppversionIosTrainerForced=1.2.0
AppVersionAndroidParticipantForced=1.0.1
AppVesionAndroidTrainerForced=2.0.1.4
AppversionIosParticipantReco=1.5.0
AppversionIosTrainerReco=1.6.0
AppVersionAndroidParticipantReco=1.7.0
AppVesionAndroidTrainerReco=1.8.0
Note: Make sure to create profile-card and profile-picture folder in s3 bucket.
After adding the necessary configuration now let us run the service.
docker build -t <servicename>:<versionname> . #update version in docker-compose file
docker compose up -d
gradle clean build
java -jar build/libs/<name of the jar file>
Now we can check the application on the localhost and the port 9090 defined in application.properties file can access Swagger API document at http://localhost:9090/swagger-ui.html
wiki
Architecture
Configuration