1

I want to build a microservices software with JHipster. I'm running jhipster-registry:v3.2.4 into Docker, i also have a microservice application (create with generator 5.0.1) but i do no generate a gateway application.

I set the profiles in docker-compose.yml with: dev and native

I setted the JWT Secret in Docker Compose file.

I added configurations files into : central-config folder

I setted the jwt for my microservice into all possible *.yml files

but on the registry UI, when i'm trying to access microservices logs or metrics, i got an Exception : Invalid JWT Signature.

3logy
  • 2,634
  • 8
  • 46
  • 99

2 Answers2

1

As you use the native profile, you can use a config file by setting SPRING_CLOUD_CONFIG_SERVER_NATIVE_SEARCH_LOCATIONS=file:./config/ in your compose .yml and in a config folder, you add an application.yml file with

jhipster:
    security:
        authentication:
            jwt:
                secret: your secret
Wai Ha Lee
  • 8,598
  • 83
  • 57
  • 92
Gerald
  • 101
  • 1
  • 10
0

You must add;
jhipster:
 security:
  authentication:
   jwt:
    secret:
or
jhipster:
 security:
  authentication:
   jwt:
    base64-secret: (JHipster v5.3.0+)
in application.yml or application.properties.

A little reminder. Secret must be longer than 256 bits.