Communicate service with Registry on another Docker server
In a project with a Jhipster microsservices structure, the Registry, the Gateway and the UAA are running in a Docker container and the other services that are also running in a container on the same server communicate with the Registry and authenticate, but I have services in other server, how can I communicate external services with the Registry and authenticate?
Docker server IP: 10.10.10.10
At first, I'm trying to make some changes to the Registry's application.yml and one of the services so that the connection / communication is by the server ip and not by the ip of the container.
My current setting is:
Register in container application.yml
eureka:
instance:
appname: jhipster-registry
instanceId: jhipsterRegistry:${spring.application.instance-id:${random.value}}
hostname: 10.10.10.10
prefer-ip-address: false
lease-renewal-interval-in-seconds: 5
lease-expiration-duration-in-seconds: 10
status-page-url-path: ${management.endpoints.web.base-path}/info
health-check-url-path: ${management.endpoints.web.base-path}/health
metadata-map:
zone: primary # This is needed for the load balancer
profile: ${spring.profiles.active}
version: ${info.project.version}
client:
enabled: true
fetch-registry: false
register-with-eureka: false
instance-info-replication-interval-seconds: 10
registry-fetch-interval-seconds: 10
service-url:
defaultZone: http://admin:${spring.security.user.password:admin}@localhost:${server.port}/eureka/
server:
# see discussion about enable-self-preservation:
# https://github.com/jhipster/generator-jhipster/issues/3654
enable-self-preservation: false
dashboard:
path: /registry
datacenter: JHipster-DataCenter
environment: JHipster-Environment
Service on another server application.yml
eureka:
instance:
prefer-ip-address: false
hostname: http://10.10.10.10
client:
service-url:
defaultZone: http://admin:${jhipster.registry.password}@10.10.10.10:8761/eureka/
docker spring-cloud netflix-eureka jhipster-registry
add a comment |
In a project with a Jhipster microsservices structure, the Registry, the Gateway and the UAA are running in a Docker container and the other services that are also running in a container on the same server communicate with the Registry and authenticate, but I have services in other server, how can I communicate external services with the Registry and authenticate?
Docker server IP: 10.10.10.10
At first, I'm trying to make some changes to the Registry's application.yml and one of the services so that the connection / communication is by the server ip and not by the ip of the container.
My current setting is:
Register in container application.yml
eureka:
instance:
appname: jhipster-registry
instanceId: jhipsterRegistry:${spring.application.instance-id:${random.value}}
hostname: 10.10.10.10
prefer-ip-address: false
lease-renewal-interval-in-seconds: 5
lease-expiration-duration-in-seconds: 10
status-page-url-path: ${management.endpoints.web.base-path}/info
health-check-url-path: ${management.endpoints.web.base-path}/health
metadata-map:
zone: primary # This is needed for the load balancer
profile: ${spring.profiles.active}
version: ${info.project.version}
client:
enabled: true
fetch-registry: false
register-with-eureka: false
instance-info-replication-interval-seconds: 10
registry-fetch-interval-seconds: 10
service-url:
defaultZone: http://admin:${spring.security.user.password:admin}@localhost:${server.port}/eureka/
server:
# see discussion about enable-self-preservation:
# https://github.com/jhipster/generator-jhipster/issues/3654
enable-self-preservation: false
dashboard:
path: /registry
datacenter: JHipster-DataCenter
environment: JHipster-Environment
Service on another server application.yml
eureka:
instance:
prefer-ip-address: false
hostname: http://10.10.10.10
client:
service-url:
defaultZone: http://admin:${jhipster.registry.password}@10.10.10.10:8761/eureka/
docker spring-cloud netflix-eureka jhipster-registry
add a comment |
In a project with a Jhipster microsservices structure, the Registry, the Gateway and the UAA are running in a Docker container and the other services that are also running in a container on the same server communicate with the Registry and authenticate, but I have services in other server, how can I communicate external services with the Registry and authenticate?
Docker server IP: 10.10.10.10
At first, I'm trying to make some changes to the Registry's application.yml and one of the services so that the connection / communication is by the server ip and not by the ip of the container.
My current setting is:
Register in container application.yml
eureka:
instance:
appname: jhipster-registry
instanceId: jhipsterRegistry:${spring.application.instance-id:${random.value}}
hostname: 10.10.10.10
prefer-ip-address: false
lease-renewal-interval-in-seconds: 5
lease-expiration-duration-in-seconds: 10
status-page-url-path: ${management.endpoints.web.base-path}/info
health-check-url-path: ${management.endpoints.web.base-path}/health
metadata-map:
zone: primary # This is needed for the load balancer
profile: ${spring.profiles.active}
version: ${info.project.version}
client:
enabled: true
fetch-registry: false
register-with-eureka: false
instance-info-replication-interval-seconds: 10
registry-fetch-interval-seconds: 10
service-url:
defaultZone: http://admin:${spring.security.user.password:admin}@localhost:${server.port}/eureka/
server:
# see discussion about enable-self-preservation:
# https://github.com/jhipster/generator-jhipster/issues/3654
enable-self-preservation: false
dashboard:
path: /registry
datacenter: JHipster-DataCenter
environment: JHipster-Environment
Service on another server application.yml
eureka:
instance:
prefer-ip-address: false
hostname: http://10.10.10.10
client:
service-url:
defaultZone: http://admin:${jhipster.registry.password}@10.10.10.10:8761/eureka/
docker spring-cloud netflix-eureka jhipster-registry
In a project with a Jhipster microsservices structure, the Registry, the Gateway and the UAA are running in a Docker container and the other services that are also running in a container on the same server communicate with the Registry and authenticate, but I have services in other server, how can I communicate external services with the Registry and authenticate?
Docker server IP: 10.10.10.10
At first, I'm trying to make some changes to the Registry's application.yml and one of the services so that the connection / communication is by the server ip and not by the ip of the container.
My current setting is:
Register in container application.yml
eureka:
instance:
appname: jhipster-registry
instanceId: jhipsterRegistry:${spring.application.instance-id:${random.value}}
hostname: 10.10.10.10
prefer-ip-address: false
lease-renewal-interval-in-seconds: 5
lease-expiration-duration-in-seconds: 10
status-page-url-path: ${management.endpoints.web.base-path}/info
health-check-url-path: ${management.endpoints.web.base-path}/health
metadata-map:
zone: primary # This is needed for the load balancer
profile: ${spring.profiles.active}
version: ${info.project.version}
client:
enabled: true
fetch-registry: false
register-with-eureka: false
instance-info-replication-interval-seconds: 10
registry-fetch-interval-seconds: 10
service-url:
defaultZone: http://admin:${spring.security.user.password:admin}@localhost:${server.port}/eureka/
server:
# see discussion about enable-self-preservation:
# https://github.com/jhipster/generator-jhipster/issues/3654
enable-self-preservation: false
dashboard:
path: /registry
datacenter: JHipster-DataCenter
environment: JHipster-Environment
Service on another server application.yml
eureka:
instance:
prefer-ip-address: false
hostname: http://10.10.10.10
client:
service-url:
defaultZone: http://admin:${jhipster.registry.password}@10.10.10.10:8761/eureka/
docker spring-cloud netflix-eureka jhipster-registry
docker spring-cloud netflix-eureka jhipster-registry
asked Nov 22 at 18:11
user2831852
196
196
add a comment |
add a comment |
active
oldest
votes
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53436315%2fcommunicate-service-with-registry-on-another-docker-server%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53436315%2fcommunicate-service-with-registry-on-another-docker-server%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown