{"action":"created","comment":{"url":"https://api.github.com/repos/istio/istio.github.io/pulls/comments/209716742","pull_request_review_id":145784892,"id":209716742,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwOTcxNjc0Mg==","diff_hunk":"@@ -0,0 +1,290 @@\n+---\n+title: Multi-Cluster With Istio\n+description: Using Istio capablities to create a Multi-Cluster and share services between clusters.\n+publishdate: 2018-08-12\n+subtitle: Share services between seperated Istio Meshes\n+attribution: Yossi Mesika (IBM), Shriram Rajagopalan (VMware), Costin Manolach (Google) and Zack Butcher (Tetrate)\n+weight: 82\n+keywords: [multi-cluster]\n+---\n+\n+There are several ways to target integration between clusters. In Istio 0.8, for instance, we introduced the Istio Multicluster support that expand the services mesh of a local cluster with services from remote cluster(s). In this approach the user is installing only the critical components necessary to connect remote services to the local Istio mesh. The advantages of one mesh are clear yet there are some scenarios when this is not feasible to create a Multi-cluster topology. This is because it requires that the Pod/Service CIDR addresses will be unique across the connected clusters while some cloud providers (such as [IBM Cloud Kubernetes Service](https://www.ibm.com/cloud/container-service)) can not guarantee to that.\n+\n+In this blog post we describe another approach for Istio Multi-Cluster that leverages its own capabilities of routing and ingress/egress to support sharing services between clusters. We also share an example of a distributed Bookinfo app that demonstrates the use of this approach.\n+\n+Let's begin with the design.\n+\n+## Design principles\n+\n+Before diving into technical configuration YAMLs let's take a moment to explain the concept introduced here.\n+\n+Having different clusters with an Istio mesh running on each allows the operators to use Istio components to connect the clusters. T clusters can talk to each other as both have an Ingress and Egress Gateways allowing traffic to enter or exit the clusters. Once we have those we need to use Istio's routing capabilities to selectively route traffic with a remote destination to the remote ingress through the local egress. How can we do it?\n+\n+The clusters operator (you) explicitly exposes one or more services in a cluster under a common custom DNS suffix (e.g., _*.remote_) via the Ingress gateway. Access to remote clusters can be granted by adding an Istio _ServiceEntry_ object that points to the respective remote cluster's Ingress Gateway for all hosts associated with the remote cluster.\n+\n+Routing rules (Virtual Services) are setup such that traffic from a cluster to a remote cluster always traverses through the local egress gateway. Funneling all egress traffic through a dedicated egress gateway simplifies policy enforcement, traffic scrubbing, etc.\n+\n+We can use a [CoreDNS](https://coredns.io/) that has the [Kubernetes plugin](https://coredns.io/plugins/kubernetes/) to resolve host names with the custom DNS suffix. However, even though custom DNS names are used, there is no additional DNS setup required. CoreDNS resolves all hosts in with the _*.remote_ suffix to an invalid IP (e.g., 10.1.1.1), allowing traffic to exit the application and be captured by the sidecar. Once the traffic reaches the sidecar, routing is done through HTTP Authority headers or SNI names.\n+\n+For example, a client (curl command) in _Cluster A_ calls `http://service_b.remote`, which gets routed from the local proxy to the local Egress Gateway. From the Egress Gateway the request traverses to the remote Ingress Gateway of _Cluster B_, which then forwards the request to the appropriate local service `service_b`.\n+\n+Notice that while we describe above a Multi-Cluster of two clusters this approach can scale up to more than a pair.\n+\n+Let's dive into technical details.\n+\n+## Setting up a cross-cluster\n+\n+The configuration below shows how to configure _Cluster A_ to be part of the Multi-Cluster. Similar mirrored configuration should be deployed to _Cluster B_ with the relevant changes. It can be done only after Istio and CoreDNS have been installed on each cluster.\n+\n+We first configure the local Ingress Gateway to accept traffic to `*.svc.a.remote`. I.e. incoming traffic originated from _Cluster B_:","path":"content/blog/2018/istio-multicluster/index.md","position":39,"original_position":39,"commit_id":"6cadf710c0c0496f3b915baa494ddbccb72e1777","original_commit_id":"6cadf710c0c0496f3b915baa494ddbccb72e1777","user":{"login":"linsun","id":1588319,"node_id":"MDQ6VXNlcjE1ODgzMTk=","avatar_url":"https://avatars3.githubusercontent.com/u/1588319?v=4","gravatar_id":"","url":"https://api.github.com/users/linsun","html_url":"https://github.com/linsun","followers_url":"https://api.github.com/users/linsun/followers","following_url":"https://api.github.com/users/linsun/following{/other_user}","gists_url":"https://api.github.com/users/linsun/gists{/gist_id}","starred_url":"https://api.github.com/users/linsun/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/linsun/subscriptions","organizations_url":"https://api.github.com/users/linsun/orgs","repos_url":"https://api.github.com/users/linsun/repos","events_url":"https://api.github.com/users/linsun/events{/privacy}","received_events_url":"https://api.github.com/users/linsun/received_events","type":"User","site_admin":false},"body":"would be good to add \"From Cluster A, we first configure....\"","created_at":"2018-08-13T18:43:44Z","updated_at":"2018-08-13T18:43:44Z","html_url":"https://github.com/istio/istio.github.io/pull/2232#discussion_r209716742","pull_request_url":"https://api.github.com/repos/istio/istio.github.io/pulls/2232","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/istio/istio.github.io/pulls/comments/209716742"},"html":{"href":"https://github.com/istio/istio.github.io/pull/2232#discussion_r209716742"},"pull_request":{"href":"https://api.github.com/repos/istio/istio.github.io/pulls/2232"}}},"pull_request":{"url":"https://api.github.com/repos/istio/istio.github.io/pulls/2232","id":207836805,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA3ODM2ODA1","html_url":"https://github.com/istio/istio.github.io/pull/2232","diff_url":"https://github.com/istio/istio.github.io/pull/2232.diff","patch_url":"https://github.com/istio/istio.github.io/pull/2232.patch","issue_url":"https://api.github.com/repos/istio/istio.github.io/issues/2232","number":2232,"state":"open","locked":false,"title":"[WIP] Istio Multi-cluster blog","user":{"login":"ymesika","id":26809068,"node_id":"MDQ6VXNlcjI2ODA5MDY4","avatar_url":"https://avatars3.githubusercontent.com/u/26809068?v=4","gravatar_id":"","url":"https://api.github.com/users/ymesika","html_url":"https://github.com/ymesika","followers_url":"https://api.github.com/users/ymesika/followers","following_url":"https://api.github.com/users/ymesika/following{/other_user}","gists_url":"https://api.github.com/users/ymesika/gists{/gist_id}","starred_url":"https://api.github.com/users/ymesika/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ymesika/subscriptions","organizations_url":"https://api.github.com/users/ymesika/orgs","repos_url":"https://api.github.com/users/ymesika/repos","events_url":"https://api.github.com/users/ymesika/events{/privacy}","received_events_url":"https://api.github.com/users/ymesika/received_events","type":"User","site_admin":false},"body":"A new blog post about enabling Multi-Cluster by having separated Istio meshes and integration through Ingress and Egress gateways.\r\n\r\n@costinm @rshriram @ZackButcher \r\ncc @linsun  ","created_at":"2018-08-12T19:36:08Z","updated_at":"2018-08-13T18:43:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6df25508ca5cb24a670c54664517498d9f8fd665","assignee":null,"assignees":[],"requested_reviewers":[{"login":"frankbu","id":2752495,"node_id":"MDQ6VXNlcjI3NTI0OTU=","avatar_url":"https://avatars2.githubusercontent.com/u/2752495?v=4","gravatar_id":"","url":"https://api.github.com/users/frankbu","html_url":"https://github.com/frankbu","followers_url":"https://api.github.com/users/frankbu/followers","following_url":"https://api.github.com/users/frankbu/following{/other_user}","gists_url":"https://api.github.com/users/frankbu/gists{/gist_id}","starred_url":"https://api.github.com/users/frankbu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/frankbu/subscriptions","organizations_url":"https://api.github.com/users/frankbu/orgs","repos_url":"https://api.github.com/users/frankbu/repos","events_url":"https://api.github.com/users/frankbu/events{/privacy}","received_events_url":"https://api.github.com/users/frankbu/received_events","type":"User","site_admin":false},{"login":"rcaballeromx","id":10066027,"node_id":"MDQ6VXNlcjEwMDY2MDI3","avatar_url":"https://avatars1.githubusercontent.com/u/10066027?v=4","gravatar_id":"","url":"https://api.github.com/users/rcaballeromx","html_url":"https://github.com/rcaballeromx","followers_url":"https://api.github.com/users/rcaballeromx/followers","following_url":"https://api.github.com/users/rcaballeromx/following{/other_user}","gists_url":"https://api.github.com/users/rcaballeromx/gists{/gist_id}","starred_url":"https://api.github.com/users/rcaballeromx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rcaballeromx/subscriptions","organizations_url":"https://api.github.com/users/rcaballeromx/orgs","repos_url":"https://api.github.com/users/rcaballeromx/repos","events_url":"https://api.github.com/users/rcaballeromx/events{/privacy}","received_events_url":"https://api.github.com/users/rcaballeromx/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[{"id":884247475,"node_id":"MDU6TGFiZWw4ODQyNDc0NzU=","url":"https://api.github.com/repos/istio/istio.github.io/labels/cla:%20yes","name":"cla: yes","color":"bfdadc","default":false},{"id":961350981,"node_id":"MDU6TGFiZWw5NjEzNTA5ODE=","url":"https://api.github.com/repos/istio/istio.github.io/labels/do-not-merge/work-in-progress","name":"do-not-merge/work-in-progress","color":"ededed","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/istio/istio.github.io/pulls/2232/commits","review_comments_url":"https://api.github.com/repos/istio/istio.github.io/pulls/2232/comments","review_comment_url":"https://api.github.com/repos/istio/istio.github.io/pulls/comments{/number}","comments_url":"https://api.github.com/repos/istio/istio.github.io/issues/2232/comments","statuses_url":"https://api.github.com/repos/istio/istio.github.io/statuses/6cadf710c0c0496f3b915baa494ddbccb72e1777","head":{"label":"ymesika:multiclusterBlog","ref":"multiclusterBlog","sha":"6cadf710c0c0496f3b915baa494ddbccb72e1777","user":{"login":"ymesika","id":26809068,"node_id":"MDQ6VXNlcjI2ODA5MDY4","avatar_url":"https://avatars3.githubusercontent.com/u/26809068?v=4","gravatar_id":"","url":"https://api.github.com/users/ymesika","html_url":"https://github.com/ymesika","followers_url":"https://api.github.com/users/ymesika/followers","following_url":"https://api.github.com/users/ymesika/following{/other_user}","gists_url":"https://api.github.com/users/ymesika/gists{/gist_id}","starred_url":"https://api.github.com/users/ymesika/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ymesika/subscriptions","organizations_url":"https://api.github.com/users/ymesika/orgs","repos_url":"https://api.github.com/users/ymesika/repos","events_url":"https://api.github.com/users/ymesika/events{/privacy}","received_events_url":"https://api.github.com/users/ymesika/received_events","type":"User","site_admin":false},"repo":{"id":132437860,"node_id":"MDEwOlJlcG9zaXRvcnkxMzI0Mzc4NjA=","name":"istio.github.io","full_name":"ymesika/istio.github.io","owner":{"login":"ymesika","id":26809068,"node_id":"MDQ6VXNlcjI2ODA5MDY4","avatar_url":"https://avatars3.githubusercontent.com/u/26809068?v=4","gravatar_id":"","url":"https://api.github.com/users/ymesika","html_url":"https://github.com/ymesika","followers_url":"https://api.github.com/users/ymesika/followers","following_url":"https://api.github.com/users/ymesika/following{/other_user}","gists_url":"https://api.github.com/users/ymesika/gists{/gist_id}","starred_url":"https://api.github.com/users/ymesika/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ymesika/subscriptions","organizations_url":"https://api.github.com/users/ymesika/orgs","repos_url":"https://api.github.com/users/ymesika/repos","events_url":"https://api.github.com/users/ymesika/events{/privacy}","received_events_url":"https://api.github.com/users/ymesika/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ymesika/istio.github.io","description":"Source for the istio.io site","fork":true,"url":"https://api.github.com/repos/ymesika/istio.github.io","forks_url":"https://api.github.com/repos/ymesika/istio.github.io/forks","keys_url":"https://api.github.com/repos/ymesika/istio.github.io/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ymesika/istio.github.io/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ymesika/istio.github.io/teams","hooks_url":"https://api.github.com/repos/ymesika/istio.github.io/hooks","issue_events_url":"https://api.github.com/repos/ymesika/istio.github.io/issues/events{/number}","events_url":"https://api.github.com/repos/ymesika/istio.github.io/events","assignees_url":"https://api.github.com/repos/ymesika/istio.github.io/assignees{/user}","branches_url":"https://api.github.com/repos/ymesika/istio.github.io/branches{/branch}","tags_url":"https://api.github.com/repos/ymesika/istio.github.io/tags","blobs_url":"https://api.github.com/repos/ymesika/istio.github.io/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ymesika/istio.github.io/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ymesika/istio.github.io/git/refs{/sha}","trees_url":"https://api.github.com/repos/ymesika/istio.github.io/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ymesika/istio.github.io/statuses/{sha}","languages_url":"https://api.github.com/repos/ymesika/istio.github.io/languages","stargazers_url":"https://api.github.com/repos/ymesika/istio.github.io/stargazers","contributors_url":"https://api.github.com/repos/ymesika/istio.github.io/contributors","subscribers_url":"https://api.github.com/repos/ymesika/istio.github.io/subscribers","subscription_url":"https://api.github.com/repos/ymesika/istio.github.io/subscription","commits_url":"https://api.github.com/repos/ymesika/istio.github.io/commits{/sha}","git_commits_url":"https://api.github.com/repos/ymesika/istio.github.io/git/commits{/sha}","comments_url":"https://api.github.com/repos/ymesika/istio.github.io/comments{/number}","issue_comment_url":"https://api.github.com/repos/ymesika/istio.github.io/issues/comments{/number}","contents_url":"https://api.github.com/repos/ymesika/istio.github.io/contents/{+path}","compare_url":"https://api.github.com/repos/ymesika/istio.github.io/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ymesika/istio.github.io/merges","archive_url":"https://api.github.com/repos/ymesika/istio.github.io/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ymesika/istio.github.io/downloads","issues_url":"https://api.github.com/repos/ymesika/istio.github.io/issues{/number}","pulls_url":"https://api.github.com/repos/ymesika/istio.github.io/pulls{/number}","milestones_url":"https://api.github.com/repos/ymesika/istio.github.io/milestones{/number}","notifications_url":"https://api.github.com/repos/ymesika/istio.github.io/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ymesika/istio.github.io/labels{/name}","releases_url":"https://api.github.com/repos/ymesika/istio.github.io/releases{/id}","deployments_url":"https://api.github.com/repos/ymesika/istio.github.io/deployments","created_at":"2018-05-07T09:26:47Z","updated_at":"2018-05-09T06:01:34Z","pushed_at":"2018-08-12T19:32:19Z","git_url":"git://github.com/ymesika/istio.github.io.git","ssh_url":"git@github.com:ymesika/istio.github.io.git","clone_url":"https://github.com/ymesika/istio.github.io.git","svn_url":"https://github.com/ymesika/istio.github.io","homepage":"https://istio.io/","size":28789,"stargazers_count":0,"watchers_count":0,"language":"HTML","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"istio:release-1.0","ref":"release-1.0","sha":"217315e82bb00e7ec27132a534ded6dc081aeebd","user":{"login":"istio","id":23534644,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIzNTM0NjQ0","avatar_url":"https://avatars1.githubusercontent.com/u/23534644?v=4","gravatar_id":"","url":"https://api.github.com/users/istio","html_url":"https://github.com/istio","followers_url":"https://api.github.com/users/istio/followers","following_url":"https://api.github.com/users/istio/following{/other_user}","gists_url":"https://api.github.com/users/istio/gists{/gist_id}","starred_url":"https://api.github.com/users/istio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/istio/subscriptions","organizations_url":"https://api.github.com/users/istio/orgs","repos_url":"https://api.github.com/users/istio/repos","events_url":"https://api.github.com/users/istio/events{/privacy}","received_events_url":"https://api.github.com/users/istio/received_events","type":"Organization","site_admin":false},"repo":{"id":82706976,"node_id":"MDEwOlJlcG9zaXRvcnk4MjcwNjk3Ng==","name":"istio.github.io","full_name":"istio/istio.github.io","owner":{"login":"istio","id":23534644,"node_id":"MDEyOk9yZ2FuaXphdGlvbjIzNTM0NjQ0","avatar_url":"https://avatars1.githubusercontent.com/u/23534644?v=4","gravatar_id":"","url":"https://api.github.com/users/istio","html_url":"https://github.com/istio","followers_url":"https://api.github.com/users/istio/followers","following_url":"https://api.github.com/users/istio/following{/other_user}","gists_url":"https://api.github.com/users/istio/gists{/gist_id}","starred_url":"https://api.github.com/users/istio/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/istio/subscriptions","organizations_url":"https://api.github.com/users/istio/orgs","repos_url":"https://api.github.com/users/istio/repos","events_url":"https://api.github.com/users/istio/events{/privacy}","received_events_url":"https://api.github.com/users/istio/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/istio/istio.github.io","description":"Source for the istio.io site","fork":false,"url":"https://api.github.com/repos/istio/istio.github.io","forks_url":"https://api.github.com/repos/istio/istio.github.io/forks","keys_url":"https://api.github.com/repos/istio/istio.github.io/keys{/key_id}","collaborators_url":"https://api.github.com/repos/istio/istio.github.io/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/istio/istio.github.io/teams","hooks_url":"https://api.github.com/repos/istio/istio.github.io/hooks","issue_events_url":"https://api.github.com/repos/istio/istio.github.io/issues/events{/number}","events_url":"https://api.github.com/repos/istio/istio.github.io/events","assignees_url":"https://api.github.com/repos/istio/istio.github.io/assignees{/user}","branches_url":"https://api.github.com/repos/istio/istio.github.io/branches{/branch}","tags_url":"https://api.github.com/repos/istio/istio.github.io/tags","blobs_url":"https://api.github.com/repos/istio/istio.github.io/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/istio/istio.github.io/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/istio/istio.github.io/git/refs{/sha}","trees_url":"https://api.github.com/repos/istio/istio.github.io/git/trees{/sha}","statuses_url":"https://api.github.com/repos/istio/istio.github.io/statuses/{sha}","languages_url":"https://api.github.com/repos/istio/istio.github.io/languages","stargazers_url":"https://api.github.com/repos/istio/istio.github.io/stargazers","contributors_url":"https://api.github.com/repos/istio/istio.github.io/contributors","subscribers_url":"https://api.github.com/repos/istio/istio.github.io/subscribers","subscription_url":"https://api.github.com/repos/istio/istio.github.io/subscription","commits_url":"https://api.github.com/repos/istio/istio.github.io/commits{/sha}","git_commits_url":"https://api.github.com/repos/istio/istio.github.io/git/commits{/sha}","comments_url":"https://api.github.com/repos/istio/istio.github.io/comments{/number}","issue_comment_url":"https://api.github.com/repos/istio/istio.github.io/issues/comments{/number}","contents_url":"https://api.github.com/repos/istio/istio.github.io/contents/{+path}","compare_url":"https://api.github.com/repos/istio/istio.github.io/compare/{base}...{head}","merges_url":"https://api.github.com/repos/istio/istio.github.io/merges","archive_url":"https://api.github.com/repos/istio/istio.github.io/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/istio/istio.github.io/downloads","issues_url":"https://api.github.com/repos/istio/istio.github.io/issues{/number}","pulls_url":"https://api.github.com/repos/istio/istio.github.io/pulls{/number}","milestones_url":"https://api.github.com/repos/istio/istio.github.io/milestones{/number}","notifications_url":"https://api.github.com/repos/istio/istio.github.io/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/istio/istio.github.io/labels{/name}","releases_url":"https://api.github.com/repos/istio/istio.github.io/releases{/id}","deployments_url":"https://api.github.com/repos/istio/istio.github.io/deployments","created_at":"2017-02-21T17:19:49Z","updated_at":"2018-08-13T16:25:39Z","pushed_at":"2018-08-13T16:45:37Z","git_url":"git://github.com/istio/istio.github.io.git","ssh_url":"git@github.com:istio/istio.github.io.git","clone_url":"https://github.com/istio/istio.github.io.git","svn_url":"https://github.com/istio/istio.github.io","homepage":"https://istio.io/","size":29233,"stargazers_count":98,"watchers_count":98,"language":"HTML","has_issues":true,"has_projects":false,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":296,"mirror_url":null,"archived":false,"open_issues_count":66,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":296,"open_issues":66,"watchers":98,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/istio/istio.github.io/pulls/2232"},"html":{"href":"https://github.com/istio/istio.github.io/pull/2232"},"issue":{"href":"https://api.github.com/repos/istio/istio.github.io/issues/2232"},"comments":{"href":"https://api.github.com/repos/istio/istio.github.io/issues/2232/comments"},"review_comments":{"href":"https://api.github.com/repos/istio/istio.github.io/pulls/2232/comments"},"review_comment":{"href":"https://api.github.com/repos/istio/istio.github.io/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/istio/istio.github.io/pulls/2232/commits"},"statuses":{"href":"https://api.github.com/repos/istio/istio.github.io/statuses/6cadf710c0c0496f3b915baa494ddbccb72e1777"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"linsun"}}