diff --git a/404.html b/404.html index 492fe50a..117ec1d0 100644 --- a/404.html +++ b/404.html @@ -9,7 +9,7 @@ - + diff --git a/assets/js/01cb08ea.90a8ab9b.js b/assets/js/01cb08ea.58ce9e89.js similarity index 99% rename from assets/js/01cb08ea.90a8ab9b.js rename to assets/js/01cb08ea.58ce9e89.js index b838622a..6d6f76a3 100644 --- a/assets/js/01cb08ea.90a8ab9b.js +++ b/assets/js/01cb08ea.58ce9e89.js @@ -1 +1 @@ -"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[3747],{2264:(e,o,n)=>{n.r(o),n.d(o,{assets:()=>d,contentTitle:()=>a,default:()=>l,frontMatter:()=>s,metadata:()=>t,toc:()=>c});const t=JSON.parse('{"id":"myzrok/custom-domains/index","title":"Custom Domains","description":"Overview","source":"@site/../docs/myzrok/custom-domains/index.mdx","sourceDirName":"myzrok/custom-domains","slug":"/myzrok/custom-domains/","permalink":"/docs/myzrok/custom-domains/","draft":false,"unlisted":false,"editUrl":"https://github.com/openziti/zrok/blob/main/docs/../docs/myzrok/custom-domains/index.mdx","tags":[],"version":"current","frontMatter":{"title":"Custom Domains"},"sidebar":"tutorialSidebar","previous":{"title":"myzrok","permalink":"/docs/category/myzrok"}}');var r=n(4848),i=n(8453);const s={title:"Custom Domains"},a=void 0,d={},c=[{value:"Overview",id:"overview",level:2},{value:"Prerequisites",id:"prerequisites",level:3},{value:"Create Your Custom Domain",id:"create-your-custom-domain",level:3},{value:"Creating DNS Records",id:"creating-dns-records",level:3},{value:"Finalizing Your Custom Domain",id:"finalizing-your-custom-domain",level:3},{value:"Start Sharing!",id:"start-sharing",level:3}];function h(e){const o={a:"a",admonition:"admonition",code:"code",em:"em",h2:"h2",h3:"h3",img:"img",li:"li",ol:"ol",p:"p",pre:"pre",strong:"strong",...(0,i.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(o.h2,{id:"overview",children:"Overview"}),"\n",(0,r.jsxs)(o.p,{children:[(0,r.jsx)(o.a,{href:"https://myzrok.io",children:"myzrok.io"})," is a hosted zrok-as-a-service offering that provides a way for you bring a custom DNS name for zrok shares.\nFor example, let's say you own the domain ",(0,r.jsx)(o.code,{children:"foo.example.io"}),", you can leverage zrok custom domains to\ncreate ephemeral shares such as: ",(0,r.jsx)(o.code,{children:"https://vw8jbg4ijz5g.foo.example.io"}),"\nor ",(0,r.jsx)(o.a,{href:"/docs/concepts/sharing-reserved",children:"reserved shares"})," such as ",(0,r.jsx)(o.code,{children:"https://myshare.foo.example.io"}),"."]}),"\n",(0,r.jsxs)(o.p,{children:["Custom domains require a Pro subscription with ",(0,r.jsx)(o.a,{href:"https://myzrok.io",children:"myzrok.io"}),".\nIf you don't already have an account, you can sign up for one ",(0,r.jsx)(o.a,{href:"https://myzrok.io",children:"here"}),"."]}),"\n",(0,r.jsxs)(o.p,{children:[(0,r.jsx)(o.a,{href:"https://myzrok.io",children:"myzrok.io"})," provides a guided setup with just a few easy steps!"]}),"\n",(0,r.jsxs)(o.ol,{children:["\n",(0,r.jsx)(o.li,{children:"Bring your own custom domain name"}),"\n",(0,r.jsx)(o.li,{children:"Create DNS records for certificate validation and traffic routing"}),"\n",(0,r.jsx)(o.li,{children:"Wait for zrok to validate your records and finalize configuration"}),"\n",(0,r.jsx)(o.li,{children:"Start sharing!"}),"\n"]}),"\n",(0,r.jsx)(o.p,{children:"Detailed setup instructions are documented below."}),"\n",(0,r.jsx)(o.h3,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,r.jsx)(o.admonition,{type:"note",children:(0,r.jsxs)(o.p,{children:["In order to create a custom domain in zrok, ",(0,r.jsx)(o.strong,{children:"you must already own the domain you want to use."})]})}),"\n",(0,r.jsx)(o.p,{children:"During the setup process you will need to create DNS records to validate ownership and to allow a certificate to be issued\non behalf of your domain. Once you have your domain registered, you can begin the process of setting up your custom\ndomain with zrok."}),"\n",(0,r.jsx)(o.h3,{id:"create-your-custom-domain",children:"Create Your Custom Domain"}),"\n",(0,r.jsx)(o.p,{children:"Log into the myzrok console and access the domains page by clicking on the globe icon in the left navigation menu."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_domains_page",src:n(2956).A+"",width:"1022",height:"581"})}),"\n",(0,r.jsx)(o.p,{children:"Click the CREATE button on the top right of the page to get started.\nWhen you click the create button you\u2019ll be presented with a form to allow you to enable your custom domain.\nEnter your domain into the form field and click CREATE. This will begin the process for setting up your custom domain.\nA new managed TLS certificate will be created to host traffic on your domain's behalf."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_add_domain",src:n(675).A+"",width:"844",height:"344"})}),"\n",(0,r.jsxs)(o.p,{children:["This may take a few minutes.\nYou may close the form at this time and come back when your domain is ",(0,r.jsx)(o.em,{children:"pending validation."}),"\nOnce your certificate is ready, you\u2019ll be presented with instructions on how to set up your DNS records."]}),"\n",(0,r.jsx)(o.h3,{id:"creating-dns-records",children:"Creating DNS Records"}),"\n",(0,r.jsx)(o.p,{children:"zrok will host and manage a TLS certificate for the custom domain on your behalf.\nThis process requires a DNS validation record to be created in order to prove ownership of the domain.\nFollow the prompts in the UI to create a CNAME DNS record with the name and value specified in the UI."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_add_cname",src:n(8881).A+"",width:"847",height:"402"})}),"\n",(0,r.jsx)(o.p,{children:"Next, create an A record to direct all DNS requests for your domain to a set of static IPs that are hosted by zrok."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_add_a_record",src:n(6212).A+"",width:"830",height:"527"})}),"\n",(0,r.jsx)(o.p,{children:"After you\u2019ve created your records, you can verify that they are configured properly using the instructions provided in the form."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_verify_dns",src:n(1752).A+"",width:"829",height:"528"})}),"\n",(0,r.jsxs)(o.p,{children:["If the ",(0,r.jsx)(o.code,{children:"nslookup"})," command returns the IP addresses supplied for the A-record entry, then DNS for your domain is resolving properly."]}),"\n",(0,r.jsx)(o.pre,{children:(0,r.jsx)(o.code,{children:"nslookup test.foo.example.io\nServer:\t\t192.168.86.194\nAddress:\t192.168.86.194#53\n\nNon-authoritative answer:\nName:\ttest.foo.example.io\nAddress: 99.83.220.186\nName:\ttest.foo.example.io\nAddress: 52.223.6.108\n"})}),"\n",(0,r.jsx)(o.p,{children:"Once you have created your DNS records, it will take zrok a few minutes to validate that they exist.\nYou can safely close the form until your certificate has been issued."}),"\n",(0,r.jsx)(o.h3,{id:"finalizing-your-custom-domain",children:"Finalizing Your Custom Domain"}),"\n",(0,r.jsx)(o.p,{children:"After your records have been validated and your certificate has been issued, click the FINALIZE button within 72 hours to complete your custom domain setup."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_finalize",src:n(5101).A+"",width:"818",height:"224"})}),"\n",(0,r.jsx)(o.p,{children:"From here, myzrok.io will complete the last few steps of creating your custom domain.\nThis should only take a minute, but if you need to close the form you can find the instructions on how to share your frontend when you return."}),"\n",(0,r.jsx)(o.h3,{id:"start-sharing",children:"Start Sharing!"}),"\n",(0,r.jsx)(o.p,{children:"Once the Finalize stage has completed, you can start sharing with your custom DNS."}),"\n",(0,r.jsxs)(o.p,{children:["In order to create shares that utilize your custom DNS, you will need to specify the ",(0,r.jsx)(o.code,{children:"--frontend"})," flag when creating a share,\nor update your environment configuration to use this new frontend by default."]}),"\n",(0,r.jsx)(o.pre,{children:(0,r.jsx)(o.code,{children:"zrok share public --frontend foo-example--goPIhgtJtz\n"})}),"\n",(0,r.jsx)(o.p,{children:"You can set the custom frontend as the environment default by running:"}),"\n",(0,r.jsx)(o.pre,{children:(0,r.jsx)(o.code,{children:"zrok config set defaultFrontend foo-example--goPIhgtJtz\n"})}),"\n",(0,r.jsxs)(o.p,{children:["To validate which frontend is being used, use the ",(0,r.jsx)(o.code,{children:"zrok status"})," command, which will identify the default frontend being used:"]}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"zrok_status",src:n(2679).A+"",width:"404",height:"220"})})]})}function l(e={}){const{wrapper:o}={...(0,i.R)(),...e.components};return o?(0,r.jsx)(o,{...e,children:(0,r.jsx)(h,{...e})}):h(e)}},6212:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_add_a_record-550b91f870f6e1df4903220bfa78ae25.png"},8881:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_add_cname-3cbbf4526443142174bab2d22224764a.png"},675:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_add_domain-bcf860ac29b46cfe5981db391bcbc521.png"},2956:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_domains_page-6d92a9076e1bca9640eb301eb6716e5f.png"},5101:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_finalize-71899efbaf429d9be596363607550730.png"},1752:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_verify_dns-2f721e1a96f56f4f09f3b0b16ea8c1c5.png"},2679:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/zrok_status-0ce131c6d8bba0df50b0f2a577707f0a.png"},8453:(e,o,n)=>{n.d(o,{R:()=>s,x:()=>a});var t=n(6540);const r={},i=t.createContext(r);function s(e){const o=t.useContext(i);return t.useMemo((function(){return"function"==typeof e?e(o):{...o,...e}}),[o,e])}function a(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:s(e.components),t.createElement(i.Provider,{value:o},e.children)}}}]); \ No newline at end of file +"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[3747],{2264:(e,o,n)=>{n.r(o),n.d(o,{assets:()=>d,contentTitle:()=>a,default:()=>l,frontMatter:()=>s,metadata:()=>t,toc:()=>c});const t=JSON.parse('{"id":"myzrok/custom-domains/index","title":"Custom Domains","description":"Overview","source":"@site/../docs/myzrok/custom-domains/index.mdx","sourceDirName":"myzrok/custom-domains","slug":"/myzrok/custom-domains/","permalink":"/docs/myzrok/custom-domains/","draft":false,"unlisted":false,"editUrl":"https://github.com/openziti/zrok/blob/main/docs/../docs/myzrok/custom-domains/index.mdx","tags":[],"version":"current","frontMatter":{"title":"Custom Domains"},"sidebar":"tutorialSidebar","previous":{"title":"myzrok","permalink":"/docs/category/myzrok"}}');var r=n(4848),i=n(8453);const s={title:"Custom Domains"},a=void 0,d={},c=[{value:"Overview",id:"overview",level:2},{value:"Prerequisites",id:"prerequisites",level:3},{value:"Create Your Custom Domain",id:"create-your-custom-domain",level:3},{value:"Creating DNS Records",id:"creating-dns-records",level:3},{value:"Finalizing Your Custom Domain",id:"finalizing-your-custom-domain",level:3},{value:"Start Sharing!",id:"start-sharing",level:3}];function h(e){const o={a:"a",admonition:"admonition",code:"code",em:"em",h2:"h2",h3:"h3",img:"img",li:"li",ol:"ol",p:"p",pre:"pre",strong:"strong",...(0,i.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(o.h2,{id:"overview",children:"Overview"}),"\n",(0,r.jsxs)(o.p,{children:[(0,r.jsx)(o.a,{href:"https://myzrok.io",children:"myzrok.io"})," is a hosted zrok-as-a-service offering that provides a way for you bring a custom DNS name for zrok shares.\nFor example, let's say you own the domain ",(0,r.jsx)(o.code,{children:"foo.example.io"}),", you can leverage zrok custom domains to\ncreate ephemeral shares such as: ",(0,r.jsx)(o.code,{children:"https://vw8jbg4ijz5g.foo.example.io"}),"\nor ",(0,r.jsx)(o.a,{href:"/docs/concepts/sharing-reserved",children:"reserved shares"})," such as ",(0,r.jsx)(o.code,{children:"https://toaster.foo.example.io"}),"."]}),"\n",(0,r.jsxs)(o.p,{children:["Custom domains require a Pro subscription with ",(0,r.jsx)(o.a,{href:"https://myzrok.io",children:"myzrok.io"}),".\nIf you don't already have an account, you can sign up for one ",(0,r.jsx)(o.a,{href:"https://myzrok.io",children:"here"}),"."]}),"\n",(0,r.jsxs)(o.p,{children:[(0,r.jsx)(o.a,{href:"https://myzrok.io",children:"myzrok.io"})," provides a guided setup with just a few easy steps!"]}),"\n",(0,r.jsxs)(o.ol,{children:["\n",(0,r.jsx)(o.li,{children:"Bring your own custom domain name"}),"\n",(0,r.jsx)(o.li,{children:"Create DNS records for certificate validation and traffic routing"}),"\n",(0,r.jsx)(o.li,{children:"Wait for zrok to validate your records and finalize configuration"}),"\n",(0,r.jsx)(o.li,{children:"Start sharing!"}),"\n"]}),"\n",(0,r.jsx)(o.p,{children:"Detailed setup instructions are documented below."}),"\n",(0,r.jsx)(o.h3,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,r.jsx)(o.admonition,{type:"note",children:(0,r.jsxs)(o.p,{children:["In order to create a custom domain in zrok, ",(0,r.jsx)(o.strong,{children:"you must already own the domain you want to use."})]})}),"\n",(0,r.jsx)(o.p,{children:"During the setup process you will need to create DNS records to validate ownership and to allow a certificate to be issued\non behalf of your domain. Once you have your domain registered, you can begin the process of setting up your custom\ndomain with zrok."}),"\n",(0,r.jsx)(o.h3,{id:"create-your-custom-domain",children:"Create Your Custom Domain"}),"\n",(0,r.jsx)(o.p,{children:"Log into the myzrok console and access the domains page by clicking on the globe icon in the left navigation menu."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_domains_page",src:n(2956).A+"",width:"1022",height:"581"})}),"\n",(0,r.jsx)(o.p,{children:"Click the CREATE button on the top right of the page to get started.\nWhen you click the create button you\u2019ll be presented with a form to allow you to enable your custom domain.\nEnter your domain into the form field and click CREATE. This will begin the process for setting up your custom domain.\nA new managed TLS certificate will be created to host traffic on your domain's behalf."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_add_domain",src:n(675).A+"",width:"844",height:"344"})}),"\n",(0,r.jsxs)(o.p,{children:["This may take a few minutes.\nYou may close the form at this time and come back when your domain is ",(0,r.jsx)(o.em,{children:"pending validation."}),"\nOnce your certificate is ready, you\u2019ll be presented with instructions on how to set up your DNS records."]}),"\n",(0,r.jsx)(o.h3,{id:"creating-dns-records",children:"Creating DNS Records"}),"\n",(0,r.jsx)(o.p,{children:"zrok will host and manage a TLS certificate for the custom domain on your behalf.\nThis process requires a DNS validation record to be created in order to prove ownership of the domain.\nFollow the prompts in the UI to create a CNAME DNS record with the name and value specified in the UI."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_add_cname",src:n(8881).A+"",width:"847",height:"402"})}),"\n",(0,r.jsx)(o.p,{children:"Next, create an A record to direct all DNS requests for your domain to a set of static IPs that are hosted by zrok."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_add_a_record",src:n(6212).A+"",width:"830",height:"527"})}),"\n",(0,r.jsx)(o.p,{children:"After you\u2019ve created your records, you can verify that they are configured properly using the instructions provided in the form."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_verify_dns",src:n(1752).A+"",width:"829",height:"528"})}),"\n",(0,r.jsxs)(o.p,{children:["If the ",(0,r.jsx)(o.code,{children:"nslookup"})," command returns the IP addresses supplied for the A-record entry, then DNS for your domain is resolving properly."]}),"\n",(0,r.jsx)(o.pre,{children:(0,r.jsx)(o.code,{children:"nslookup test.foo.example.io\nServer:\t\t192.168.86.194\nAddress:\t192.168.86.194#53\n\nNon-authoritative answer:\nName:\ttest.foo.example.io\nAddress: 99.83.220.186\nName:\ttest.foo.example.io\nAddress: 52.223.6.108\n"})}),"\n",(0,r.jsx)(o.p,{children:"Once you have created your DNS records, it will take zrok a few minutes to validate that they exist.\nYou can safely close the form until your certificate has been issued."}),"\n",(0,r.jsx)(o.h3,{id:"finalizing-your-custom-domain",children:"Finalizing Your Custom Domain"}),"\n",(0,r.jsx)(o.p,{children:"After your records have been validated and your certificate has been issued, click the FINALIZE button within 72 hours to complete your custom domain setup."}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"myzrok_finalize",src:n(5101).A+"",width:"818",height:"224"})}),"\n",(0,r.jsx)(o.p,{children:"From here, myzrok.io will complete the last few steps of creating your custom domain.\nThis should only take a minute, but if you need to close the form you can find the instructions on how to share your frontend when you return."}),"\n",(0,r.jsx)(o.h3,{id:"start-sharing",children:"Start Sharing!"}),"\n",(0,r.jsx)(o.p,{children:"Once the Finalize stage has completed, you can start sharing with your custom DNS."}),"\n",(0,r.jsxs)(o.p,{children:["In order to create shares that utilize your custom DNS, you will need to specify the ",(0,r.jsx)(o.code,{children:"--frontend"})," flag when creating a share,\nor update your environment configuration to use this new frontend by default."]}),"\n",(0,r.jsx)(o.pre,{children:(0,r.jsx)(o.code,{children:"zrok share public --frontend foo-example--goPIhgtJtz\n"})}),"\n",(0,r.jsx)(o.p,{children:"You can set the custom frontend as the environment default by running:"}),"\n",(0,r.jsx)(o.pre,{children:(0,r.jsx)(o.code,{children:"zrok config set defaultFrontend foo-example--goPIhgtJtz\n"})}),"\n",(0,r.jsxs)(o.p,{children:["To validate which frontend is being used, use the ",(0,r.jsx)(o.code,{children:"zrok status"})," command, which will identify the default frontend being used:"]}),"\n",(0,r.jsx)(o.p,{children:(0,r.jsx)(o.img,{alt:"zrok_status",src:n(2679).A+"",width:"404",height:"220"})})]})}function l(e={}){const{wrapper:o}={...(0,i.R)(),...e.components};return o?(0,r.jsx)(o,{...e,children:(0,r.jsx)(h,{...e})}):h(e)}},6212:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_add_a_record-550b91f870f6e1df4903220bfa78ae25.png"},8881:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_add_cname-3cbbf4526443142174bab2d22224764a.png"},675:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_add_domain-bcf860ac29b46cfe5981db391bcbc521.png"},2956:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_domains_page-6d92a9076e1bca9640eb301eb6716e5f.png"},5101:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_finalize-71899efbaf429d9be596363607550730.png"},1752:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/myzrok_verify_dns-2f721e1a96f56f4f09f3b0b16ea8c1c5.png"},2679:(e,o,n)=>{n.d(o,{A:()=>t});const t=n.p+"assets/images/zrok_status-0ce131c6d8bba0df50b0f2a577707f0a.png"},8453:(e,o,n)=>{n.d(o,{R:()=>s,x:()=>a});var t=n(6540);const r={},i=t.createContext(r);function s(e){const o=t.useContext(i);return t.useMemo((function(){return"function"==typeof e?e(o):{...o,...e}}),[o,e])}function a(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:s(e.components),t.createElement(i.Provider,{value:o},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/2da89d45.2c84f779.js b/assets/js/2da89d45.2c84f779.js deleted file mode 100644 index 15e3e9d6..00000000 --- a/assets/js/2da89d45.2c84f779.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[6332],{2452:(e,n,r)=>{r.r(n),r.d(n,{assets:()=>l,contentTitle:()=>a,default:()=>u,frontMatter:()=>c,metadata:()=>s,toc:()=>d});const s=JSON.parse('{"id":"guides/docker-share/index","title":"Getting Started with Docker","description":"Overview","source":"@site/../docs/guides/docker-share/index.mdx","sourceDirName":"guides/docker-share","slug":"/guides/docker-share/","permalink":"/docs/guides/docker-share/","draft":false,"unlisted":false,"editUrl":"https://github.com/openziti/zrok/blob/main/docs/../docs/guides/docker-share/index.mdx","tags":[],"version":"current","frontMatter":{"title":"Getting Started with Docker"},"sidebar":"tutorialSidebar","previous":{"title":"Permission Modes","permalink":"/docs/guides/permission-modes"},"next":{"title":"Public Share","permalink":"/docs/guides/docker-share/docker_public_share_guide"}}');var t=r(4848),o=r(8453),i=r(4971);const c={title:"Getting Started with Docker"},a=void 0,l={},d=[{value:"Overview",id:"overview",level:2},{value:"Permanent Public Share",id:"permanent-public-share",level:2},{value:"Temporary Public Share",id:"temporary-public-share",level:2}];function h(e){const n={a:"a",code:"code",h2:"h2",li:"li",ol:"ol",p:"p",pre:"pre",...(0,o.R)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(n.h2,{id:"overview",children:"Overview"}),"\n",(0,t.jsxs)(n.p,{children:["To follow the guides in this section you will need ",(0,t.jsx)(n.a,{href:"https://docs.docker.com/get-docker/",children:"Docker"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["You have the option to enable a ",(0,t.jsx)(n.code,{children:"zrok"})," account on the Docker host and mount it on the container or you can use the provided Docker Compose project files (",(0,t.jsx)(n.code,{children:"compose.yml"}),") to enable a separate ",(0,t.jsx)(n.code,{children:"zrok"})," environment for each project."]}),"\n",(0,t.jsxs)(n.p,{children:["This page provides ",(0,t.jsx)(n.code,{children:"docker"})," and ",(0,t.jsx)(n.code,{children:"docker compose"})," examples of mounting the host's ",(0,t.jsx)(n.code,{children:"zrok"})," environment on the container. You'll need to first ",(0,t.jsx)(n.a,{href:"/docs/getting-started/#installing-the-zrok-command",children:"enable zrok on the Docker host"})," to use this approach."]}),"\n",(0,t.jsx)(n.h2,{id:"permanent-public-share",children:"Permanent Public Share"}),"\n",(0,t.jsxs)(n.p,{children:["Let's say you have a ",(0,t.jsx)(n.code,{children:"compose.yml"})," file that defines a web app known within the project's bridge network as ",(0,t.jsx)(n.code,{children:"https://myapp:8080"})," and you want to publish it as a reliable, public site."]}),"\n",(0,t.jsxs)(n.ol,{children:["\n",(0,t.jsxs)(n.li,{children:["\n",(0,t.jsxs)(n.p,{children:["Reserve a subdomain by running ",(0,t.jsx)(n.code,{children:'zrok reserve public --unique-name "myapp" https://myapp:8080'})," on the Docker host."]}),"\n"]}),"\n",(0,t.jsxs)(n.li,{children:["\n",(0,t.jsxs)(n.p,{children:["Merge this YAML with ",(0,t.jsx)(n.code,{children:"compose.yml"})," or save it in the same directory as ",(0,t.jsx)(n.code,{children:"compose.override.yml"})," to let ",(0,t.jsx)(n.code,{children:"docker compose up"})," merge it for you."]}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-yaml",children:'services:\n zrok:\n image: openziti/zrok\n restart: unless-stopped\n user: "${UID}"\n volumes:\n - ${HOME}/.zrok:/home/ziggy/.zrok\n environment:\n PFXLOG_NO_JSON: "true"\n command: share reserved "myapp" --headless\n'})}),"\n"]}),"\n"]}),"\n",(0,t.jsxs)(n.p,{children:["The reserved share will be available at ",(0,t.jsx)(n.code,{children:"https://myapp.share.zrok.io"})," each time the ",(0,t.jsx)(n.code,{children:"zrok"})," container starts up."]}),"\n",(0,t.jsx)(n.h2,{id:"temporary-public-share",children:"Temporary Public Share"}),"\n",(0,t.jsxs)(n.p,{children:["Let's say you have a web server running on the host's private network at ",(0,t.jsx)(n.code,{children:"https://10.11.12.13:8080"}),". With one additional ",(0,t.jsx)(n.code,{children:"docker"})," command, you can share the web server publicly as long as the ",(0,t.jsx)(n.code,{children:"zrok"})," container stays running."]}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-bash",metastring:'title="BASH"',children:'docker run \\\n --rm \\\n --network=host \\\n --volume ~/.zrok:/home/ziggy/.zrok \\\n --user "${UID:-1000}:${GID:-1000}" \\\n openziti/zrok share public \\\n --headless \\\n https://10.11.12.13:8080\n'})}),"\n",(0,t.jsxs)(i.A,{children:[(0,t.jsx)("summary",{children:"PowerShell"}),(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-powershell",children:'docker.exe run `\n --rm `\n --network "host" `\n --volume "${env:USERPROFILE}\\.zrok:/.zrok" `\n --user "1000" `\n openziti/zrok share public `\n --headless `\n https://10.11.12.13:8080\n'})})]}),"\n",(0,t.jsxs)(i.A,{children:[(0,t.jsx)("summary",{children:"Command Prompt (batch)"}),(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-cmd",children:'docker.exe run ^\n --rm ^\n --network "host" ^\n --volume "%USERPROFILE%\\.zrok:/.zrok" ^\n --user "1000" ^\n openziti/zrok share public ^\n --headless ^\n https://10.11.12.13:8080\n'})})]}),"\n",(0,t.jsxs)(i.A,{children:[(0,t.jsx)("summary",{children:"Windows Subsystem for Linux (WSL)"}),(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-bash",children:'docker run \\\n --rm \\\n --network "host" \\\n --volume "/mnt/c/Users/$(powershell.exe -Command \'Write-Output $env:USERNAME\' | tr -d \'\\r\')/.zrok:/home/ziggy/.zrok" \\\n --user "${UID:-1000}:${GID:-1000}" \\\n openziti/zrok share public \\\n --headless \\\n https://10.11.12.13:8080\n'})})]}),"\n",(0,t.jsx)(n.p,{children:"The public share URL appears near the beginning of the container's log."}),"\n",(0,t.jsx)(n.p,{children:"Let's break down those options and arguments."}),"\n",(0,t.jsxs)(n.ol,{children:["\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"--rm"})," don't save this container because it's providing a temporary public share that's destroyed when the container stops"]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"--network=host"})," shares the host's network with the container so that the container can reach the web server directly. This is always necessary when the web server is listening only on the host's loopback interface, e.g., ",(0,t.jsx)(n.code,{children:"https://::1:8080"}),", and may not be strictly necessary if the target is routeable from the default Docker bridge."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"--volume ~/.zrok:/home/ziggy/.zrok"})," mounts the ",(0,t.jsx)(n.code,{children:"zrok"})," configuration from the Docker host into the container."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:'--user "${UID:-1000}:${GID:-1000}"'})," sets the container's user to the current user on the Docker host to avoid permission issues with reading the mounted ",(0,t.jsx)(n.code,{children:"zrok"})," configuration (defaults to ",(0,t.jsx)(n.code,{children:"1000:1000"}),")."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"openziti/zrok"})," is the ",(0,t.jsx)(n.code,{children:"zrok"})," Docker image."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"share public"})," is the ",(0,t.jsx)(n.code,{children:"zrok"})," command to share the target publicly until zrok exits."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"--headless"})," runs the ",(0,t.jsx)(n.code,{children:"zrok"})," command without the interactive terminal UI."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"https://10.11.12.13:8080"})," is the target web server to share."]}),"\n"]})]})}function u(e={}){const{wrapper:n}={...(0,o.R)(),...e.components};return n?(0,t.jsx)(n,{...e,children:(0,t.jsx)(h,{...e})}):h(e)}},4971:(e,n,r)=>{r.d(n,{A:()=>k});var s=r(6540),t=r(8215),o=r(5066),i=r(3427),c=r(2303),a=r(1422);const l={details:"details_lb9f",isBrowser:"isBrowser_bmU9",collapsibleContent:"collapsibleContent_i85q"};var d=r(4848);function h(e){return!!e&&("SUMMARY"===e.tagName||h(e.parentElement))}function u(e,n){return!!e&&(e===n||u(e.parentElement,n))}function p(e){let{summary:n,children:r,...t}=e;(0,i.A)().collectAnchor(t.id);const p=(0,c.A)(),m=(0,s.useRef)(null),{collapsed:x,setCollapsed:j}=(0,a.u)({initialState:!t.open}),[k,g]=(0,s.useState)(t.open),b=s.isValidElement(n)?n:(0,d.jsx)("summary",{children:n??"Details"});return(0,d.jsxs)("details",{...t,ref:m,open:k,"data-collapsed":x,className:(0,o.A)(l.details,p&&l.isBrowser,t.className),onMouseDown:e=>{h(e.target)&&e.detail>1&&e.preventDefault()},onClick:e=>{e.stopPropagation();const n=e.target;h(n)&&u(n,m.current)&&(e.preventDefault(),x?(j(!1),g(!0)):j(!0))},children:[b,(0,d.jsx)(a.N,{lazy:!1,collapsed:x,disableSSRStyle:!0,onCollapseTransitionEnd:e=>{j(e),g(!e)},children:(0,d.jsx)("div",{className:l.collapsibleContent,children:r})})]})}const m={details:"details_b_Ee"},x="alert alert--info";function j(e){let{...n}=e;return(0,d.jsx)(p,{...n,className:(0,t.A)(x,m.details,n.className)})}function k(e){const n=s.Children.toArray(e.children),r=n.find((e=>s.isValidElement(e)&&"summary"===e.type)),t=(0,d.jsx)(d.Fragment,{children:n.filter((e=>e!==r))});return(0,d.jsx)(j,{...e,summary:r,children:t})}},8453:(e,n,r)=>{r.d(n,{R:()=>i,x:()=>c});var s=r(6540);const t={},o=s.createContext(t);function i(e){const n=s.useContext(o);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:i(e.components),s.createElement(o.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/2da89d45.c53388d7.js b/assets/js/2da89d45.c53388d7.js new file mode 100644 index 00000000..b93c5d5e --- /dev/null +++ b/assets/js/2da89d45.c53388d7.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[6332],{2452:(e,n,r)=>{r.r(n),r.d(n,{assets:()=>l,contentTitle:()=>a,default:()=>u,frontMatter:()=>c,metadata:()=>s,toc:()=>d});const s=JSON.parse('{"id":"guides/docker-share/index","title":"Getting Started with Docker","description":"Overview","source":"@site/../docs/guides/docker-share/index.mdx","sourceDirName":"guides/docker-share","slug":"/guides/docker-share/","permalink":"/docs/guides/docker-share/","draft":false,"unlisted":false,"editUrl":"https://github.com/openziti/zrok/blob/main/docs/../docs/guides/docker-share/index.mdx","tags":[],"version":"current","frontMatter":{"title":"Getting Started with Docker"},"sidebar":"tutorialSidebar","previous":{"title":"Permission Modes","permalink":"/docs/guides/permission-modes"},"next":{"title":"Public Share","permalink":"/docs/guides/docker-share/docker_public_share_guide"}}');var t=r(4848),o=r(8453),i=r(4971);const c={title:"Getting Started with Docker"},a=void 0,l={},d=[{value:"Overview",id:"overview",level:2},{value:"Permanent Public Share",id:"permanent-public-share",level:2},{value:"Temporary Public Share",id:"temporary-public-share",level:2}];function h(e){const n={a:"a",code:"code",h2:"h2",li:"li",ol:"ol",p:"p",pre:"pre",...(0,o.R)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(n.h2,{id:"overview",children:"Overview"}),"\n",(0,t.jsxs)(n.p,{children:["To follow the guides in this section you will need ",(0,t.jsx)(n.a,{href:"https://docs.docker.com/get-docker/",children:"Docker"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["You have the option to enable a ",(0,t.jsx)(n.code,{children:"zrok"})," account on the Docker host and mount it on the container or you can use the provided Docker Compose project files (",(0,t.jsx)(n.code,{children:"compose.yml"}),") to enable a separate ",(0,t.jsx)(n.code,{children:"zrok"})," environment for each project."]}),"\n",(0,t.jsxs)(n.p,{children:["This page provides ",(0,t.jsx)(n.code,{children:"docker"})," and ",(0,t.jsx)(n.code,{children:"docker compose"})," examples of mounting the host's ",(0,t.jsx)(n.code,{children:"zrok"})," environment on the container. You'll need to first ",(0,t.jsx)(n.a,{href:"/docs/getting-started/#installing-the-zrok-command",children:"enable zrok on the Docker host"})," to use this approach."]}),"\n",(0,t.jsx)(n.h2,{id:"permanent-public-share",children:"Permanent Public Share"}),"\n",(0,t.jsxs)(n.p,{children:["Let's say you have a ",(0,t.jsx)(n.code,{children:"compose.yml"})," file that defines a web app known within the project's bridge network as ",(0,t.jsx)(n.code,{children:"https://toaster:8080"})," and you want to publish it as a reliable, public site."]}),"\n",(0,t.jsxs)(n.ol,{children:["\n",(0,t.jsxs)(n.li,{children:["\n",(0,t.jsxs)(n.p,{children:["Reserve a subdomain by running ",(0,t.jsx)(n.code,{children:'zrok reserve public --unique-name "toaster" https:toasterpp:8080'})," on the Docker host."]}),"\n"]}),"\n",(0,t.jsxs)(n.li,{children:["\n",(0,t.jsxs)(n.p,{children:["Merge this YAML with ",(0,t.jsx)(n.code,{children:"compose.yml"})," or save it in the same directory as ",(0,t.jsx)(n.code,{children:"compose.override.yml"})," to let ",(0,t.jsx)(n.code,{children:"docker compose up"})," merge it for you."]}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-yaml",children:'services:\n zrok:\n image: openziti/zrok\n restart: unless-stopped\n user: "${UID}"\n volumes:\n - ${HOME}/.zrok:/home/ziggy/.zrok\n environment:\n PFXLOG_NO_JSON: "true"\n command: share reserved "toaster" --headless\n'})}),"\n"]}),"\n"]}),"\n",(0,t.jsxs)(n.p,{children:["The reserved share will be available at ",(0,t.jsx)(n.code,{children:"https://toaster.share.zrok.io"})," each time the ",(0,t.jsx)(n.code,{children:"zrok"})," container starts up."]}),"\n",(0,t.jsx)(n.h2,{id:"temporary-public-share",children:"Temporary Public Share"}),"\n",(0,t.jsxs)(n.p,{children:["Let's say you have a web server running on the host's private network at ",(0,t.jsx)(n.code,{children:"https://10.11.12.13:8080"}),". With one additional ",(0,t.jsx)(n.code,{children:"docker"})," command, you can share the web server publicly as long as the ",(0,t.jsx)(n.code,{children:"zrok"})," container stays running."]}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-bash",metastring:'title="BASH"',children:'docker run \\\n --rm \\\n --network=host \\\n --volume ~/.zrok:/home/ziggy/.zrok \\\n --user "${UID:-1000}:${GID:-1000}" \\\n openziti/zrok share public \\\n --headless \\\n https://10.11.12.13:8080\n'})}),"\n",(0,t.jsxs)(i.A,{children:[(0,t.jsx)("summary",{children:"PowerShell"}),(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-powershell",children:'docker.exe run `\n --rm `\n --network "host" `\n --volume "${env:USERPROFILE}\\.zrok:/.zrok" `\n --user "1000" `\n openziti/zrok share public `\n --headless `\n https://10.11.12.13:8080\n'})})]}),"\n",(0,t.jsxs)(i.A,{children:[(0,t.jsx)("summary",{children:"Command Prompt (batch)"}),(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-cmd",children:'docker.exe run ^\n --rm ^\n --network "host" ^\n --volume "%USERPROFILE%\\.zrok:/.zrok" ^\n --user "1000" ^\n openziti/zrok share public ^\n --headless ^\n https://10.11.12.13:8080\n'})})]}),"\n",(0,t.jsxs)(i.A,{children:[(0,t.jsx)("summary",{children:"Windows Subsystem for Linux (WSL)"}),(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-bash",children:'docker run \\\n --rm \\\n --network "host" \\\n --volume "/mnt/c/Users/$(powershell.exe -Command \'Write-Output $env:USERNAME\' | tr -d \'\\r\')/.zrok:/home/ziggy/.zrok" \\\n --user "${UID:-1000}:${GID:-1000}" \\\n openziti/zrok share public \\\n --headless \\\n https://10.11.12.13:8080\n'})})]}),"\n",(0,t.jsx)(n.p,{children:"The public share URL appears near the beginning of the container's log."}),"\n",(0,t.jsx)(n.p,{children:"Let's break down those options and arguments."}),"\n",(0,t.jsxs)(n.ol,{children:["\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"--rm"})," don't save this container because it's providing a temporary public share that's destroyed when the container stops"]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"--network=host"})," shares the host's network with the container so that the container can reach the web server directly. This is always necessary when the web server is listening only on the host's loopback interface, e.g., ",(0,t.jsx)(n.code,{children:"https://::1:8080"}),", and may not be strictly necessary if the target is routeable from the default Docker bridge."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"--volume ~/.zrok:/home/ziggy/.zrok"})," mounts the ",(0,t.jsx)(n.code,{children:"zrok"})," configuration from the Docker host into the container."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:'--user "${UID:-1000}:${GID:-1000}"'})," sets the container's user to the current user on the Docker host to avoid permission issues with reading the mounted ",(0,t.jsx)(n.code,{children:"zrok"})," configuration (defaults to ",(0,t.jsx)(n.code,{children:"1000:1000"}),")."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"openziti/zrok"})," is the ",(0,t.jsx)(n.code,{children:"zrok"})," Docker image."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"share public"})," is the ",(0,t.jsx)(n.code,{children:"zrok"})," command to share the target publicly until zrok exits."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"--headless"})," runs the ",(0,t.jsx)(n.code,{children:"zrok"})," command without the interactive terminal UI."]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"https://10.11.12.13:8080"})," is the target web server to share."]}),"\n"]})]})}function u(e={}){const{wrapper:n}={...(0,o.R)(),...e.components};return n?(0,t.jsx)(n,{...e,children:(0,t.jsx)(h,{...e})}):h(e)}},4971:(e,n,r)=>{r.d(n,{A:()=>k});var s=r(6540),t=r(8215),o=r(5066),i=r(3427),c=r(2303),a=r(1422);const l={details:"details_lb9f",isBrowser:"isBrowser_bmU9",collapsibleContent:"collapsibleContent_i85q"};var d=r(4848);function h(e){return!!e&&("SUMMARY"===e.tagName||h(e.parentElement))}function u(e,n){return!!e&&(e===n||u(e.parentElement,n))}function p(e){let{summary:n,children:r,...t}=e;(0,i.A)().collectAnchor(t.id);const p=(0,c.A)(),m=(0,s.useRef)(null),{collapsed:x,setCollapsed:j}=(0,a.u)({initialState:!t.open}),[k,g]=(0,s.useState)(t.open),b=s.isValidElement(n)?n:(0,d.jsx)("summary",{children:n??"Details"});return(0,d.jsxs)("details",{...t,ref:m,open:k,"data-collapsed":x,className:(0,o.A)(l.details,p&&l.isBrowser,t.className),onMouseDown:e=>{h(e.target)&&e.detail>1&&e.preventDefault()},onClick:e=>{e.stopPropagation();const n=e.target;h(n)&&u(n,m.current)&&(e.preventDefault(),x?(j(!1),g(!0)):j(!0))},children:[b,(0,d.jsx)(a.N,{lazy:!1,collapsed:x,disableSSRStyle:!0,onCollapseTransitionEnd:e=>{j(e),g(!e)},children:(0,d.jsx)("div",{className:l.collapsibleContent,children:r})})]})}const m={details:"details_b_Ee"},x="alert alert--info";function j(e){let{...n}=e;return(0,d.jsx)(p,{...n,className:(0,t.A)(x,m.details,n.className)})}function k(e){const n=s.Children.toArray(e.children),r=n.find((e=>s.isValidElement(e)&&"summary"===e.type)),t=(0,d.jsx)(d.Fragment,{children:n.filter((e=>e!==r))});return(0,d.jsx)(j,{...e,summary:r,children:t})}},8453:(e,n,r)=>{r.d(n,{R:()=>i,x:()=>c});var s=r(6540);const t={},o=s.createContext(t);function i(e){const n=s.useContext(o);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:i(e.components),s.createElement(o.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/2e812224.6dc7f702.js b/assets/js/2e812224.6dc7f702.js new file mode 100644 index 00000000..ea87de1b --- /dev/null +++ b/assets/js/2e812224.6dc7f702.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[8471],{8611:(e,r,n)=>{n.r(r),n.d(r,{assets:()=>c,contentTitle:()=>a,default:()=>h,frontMatter:()=>t,metadata:()=>s,toc:()=>d});const s=JSON.parse('{"id":"guides/docker-share/docker_public_share_guide","title":"Docker Compose Public Share","description":"Goal","source":"@site/../docs/guides/docker-share/docker_public_share_guide.md","sourceDirName":"guides/docker-share","slug":"/guides/docker-share/docker_public_share_guide","permalink":"/docs/guides/docker-share/docker_public_share_guide","draft":false,"unlisted":false,"editUrl":"https://github.com/openziti/zrok/blob/main/docs/../docs/guides/docker-share/docker_public_share_guide.md","tags":[],"version":"current","sidebarPosition":10,"frontMatter":{"title":"Docker Compose Public Share","sidebar_position":10,"sidebar_label":"Public Share"},"sidebar":"tutorialSidebar","previous":{"title":"Getting Started with Docker","permalink":"/docs/guides/docker-share/"},"next":{"title":"Private Share","permalink":"/docs/guides/docker-share/docker_private_share_guide"}}');var o=n(4848),i=n(8453);const t={title:"Docker Compose Public Share",sidebar_position:10,sidebar_label:"Public Share"},a=void 0,c={},d=[{value:"Goal",id:"goal",level:2},{value:"Overview",id:"overview",level:2},{value:"Walkthrough Video",id:"walkthrough-video",level:2},{value:"How it Works",id:"how-it-works",level:2},{value:"Create the Docker Project",id:"create-the-docker-project",level:2},{value:"Proxy Any Web Server",id:"proxy-any-web-server",level:2},{value:"Require Authentication",id:"require-authentication",level:2},{value:"OAuth Email",id:"oauth-email",level:3},{value:"Caddy is Powerful",id:"caddy-is-powerful",level:2}];function l(e){const r={a:"a",code:"code",h2:"h2",h3:"h3",li:"li",ol:"ol",p:"p",pre:"pre",...(0,i.R)(),...e.components};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(r.h2,{id:"goal",children:"Goal"}),"\n",(0,o.jsx)(r.p,{children:"Publicly share a Docker Compose service with a separate zrok environment and a permanent zrok share URL."}),"\n",(0,o.jsx)(r.h2,{id:"overview",children:"Overview"}),"\n",(0,o.jsx)(r.p,{children:"With zrok, you can publicly share a service that's running in Docker. You need a zrok public share running somewhere that it can reach the service you're sharing. As long as that public share is running and your service is available, anyone with the address can use your service."}),"\n",(0,o.jsxs)(r.p,{children:["Here's a short article with an overview of ",(0,o.jsx)(r.a,{href:"/docs/concepts/sharing-public",children:"public sharing with zrok"}),"."]}),"\n",(0,o.jsx)(r.h2,{id:"walkthrough-video",children:"Walkthrough Video"}),"\n",(0,o.jsx)("iframe",{width:"100%",height:"315",src:"https://www.youtube.com/embed/ycov--9ZtB4",title:"YouTube video player",frameborder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",allowfullscreen:!0}),"\n",(0,o.jsx)(r.h2,{id:"how-it-works",children:"How it Works"}),"\n",(0,o.jsx)(r.p,{children:"The Docker Compose project uses your zrok account token to reserve a public subdomain and keep sharing the backend\ntarget."}),"\n",(0,o.jsx)(r.p,{children:"When the project runs it will:"}),"\n",(0,o.jsxs)(r.ol,{children:["\n",(0,o.jsxs)(r.li,{children:["enable a zrok environment unless ",(0,o.jsx)(r.code,{children:"/mnt/.zrok/environment.json"})," exists in the ",(0,o.jsx)(r.code,{children:"zrok_env"})," volume"]}),"\n",(0,o.jsxs)(r.li,{children:["reserve a public subdomain for the service unless ",(0,o.jsx)(r.code,{children:"/mnt/.zrok/reserved.json"})," exists"]}),"\n",(0,o.jsxs)(r.li,{children:["start sharing the target specified in the ",(0,o.jsx)(r.code,{children:"ZROK_TARGET"})," environment variable"]}),"\n"]}),"\n",(0,o.jsx)(r.h2,{id:"create-the-docker-project",children:"Create the Docker Project"}),"\n",(0,o.jsxs)(r.ol,{children:["\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Make a folder on your computer to use as a Docker Compose project for your zrok public share with a reserved subdomain and switch to the new directory in your terminal."}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsxs)(r.p,{children:["Download ",(0,o.jsxs)(r.a,{href:"pathname:///zrok-public-reserved/compose.yml",children:["the reserved public share ",(0,o.jsx)(r.code,{children:"compose.yml"})," project file"]})," into the same directory."]}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsxs)(r.p,{children:["Copy your zrok account's enable token from the zrok web console to your clipboard and paste it in a file named ",(0,o.jsx)(r.code,{children:".env"})," in the same folder like this:"]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",metastring:'title=".env"',children:'ZROK_ENABLE_TOKEN="8UL9-48rN0ua"\n'})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Name the Share"}),"\n",(0,o.jsxs)(r.p,{children:["This unique name becomes part of the domain name of the share, e.g. ",(0,o.jsx)(r.code,{children:"https://toaster.share.zrok.io"}),". A random name is generated if you don't specify one."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",metastring:'title=".env"',children:'ZROK_UNIQUE_NAME="toaster"\n'})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsxs)(r.p,{children:["Run the Compose project to start sharing the built-in demo web server. Be sure to ",(0,o.jsx)(r.code,{children:"--detach"})," so the project runs in the background if you want it to auto-restart when your computer reboots."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose up --detach\n"})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsxs)(r.p,{children:["Get the public share URL from the output of the ",(0,o.jsx)(r.code,{children:"zrok-share"})," service or by peeking in the zrok console where the share will appear in the graph."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose logs zrok-share\n"})}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-buttonless",metastring:'title="Output"',children:"zrok-public-share-1 | https://w6r1vesearkj.share.zrok.io/\n"})}),"\n"]}),"\n"]}),"\n",(0,o.jsx)(r.p,{children:"This concludes the minimum steps to begin sharing the demo web server. Read on to learn how to pivot to sharing any website or web service by leveraging additional zrok backend modes."}),"\n",(0,o.jsx)(r.h2,{id:"proxy-any-web-server",children:"Proxy Any Web Server"}),"\n",(0,o.jsxs)(r.p,{children:["The simplest way to share your existing HTTP server is to set ",(0,o.jsx)(r.code,{children:"ZROK_TARGET"})," (e.g. ",(0,o.jsx)(r.code,{children:"https://example.com"}),") in the environment of the ",(0,o.jsx)(r.code,{children:"docker compose up"})," command. When you restart the share will auto-configure for that URL."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",metastring:'title=".env"',children:'ZROK_TARGET="http://example.com:8080"\n'})}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose down && docker compose up\n"})}),"\n",(0,o.jsx)(r.h2,{id:"require-authentication",children:"Require Authentication"}),"\n",(0,o.jsx)(r.p,{children:"You can require a password or an OAuth login with certain email addresses."}),"\n",(0,o.jsx)(r.h3,{id:"oauth-email",children:"OAuth Email"}),"\n",(0,o.jsxs)(r.p,{children:["You can allow specific email addresse patterns by setting ",(0,o.jsx)(r.code,{children:"ZROK_OAUTH_PROVIDER"})," to ",(0,o.jsx)(r.code,{children:"github"})," or ",(0,o.jsx)(r.code,{children:"google"})," and\n",(0,o.jsx)(r.code,{children:"ZROK_OAUTH_EMAILS"}),". Read more about the OAuth features in ",(0,o.jsx)(r.a,{href:"https://blog.openziti.io/the-zrok-oauth-public-frontend",children:"this blog\npost"}),"."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",metastring:'title=".env"',children:'ZROK_OAUTH_PROVIDER="github"\nZROK_OAUTH_EMAILS="alice@example.com *@acme.example.com"\n'})}),"\n",(0,o.jsx)(r.h2,{id:"caddy-is-powerful",children:"Caddy is Powerful"}),"\n",(0,o.jsxs)(r.p,{children:["The reserved public share project uses zrok's default backend mode, ",(0,o.jsx)(r.code,{children:"proxy"}),". Another backend mode, ",(0,o.jsx)(r.code,{children:"caddy"}),", accepts a path to ",(0,o.jsx)(r.a,{href:"https://caddyserver.com/docs/caddyfile",children:"a Caddyfile"})," as the value of ",(0,o.jsx)(r.code,{children:"ZROK_TARGET"})," (",(0,o.jsx)(r.a,{href:"https://github.com/openziti/zrok/tree/main/etc/caddy",children:"zrok Caddyfile examples"}),")."]}),"\n",(0,o.jsxs)(r.p,{children:["Caddy is the most powerful and flexible backend mode in zrok. You must reserve a new public subdomain whenever you switch the backend mode, so using ",(0,o.jsx)(r.code,{children:"caddy"})," reduces the risk that you'll have to share a new frontend URL with your users."]}),"\n",(0,o.jsx)(r.p,{children:"With Caddy, you can balance the workload for websites or web services or share static sites and files or all of the above at the same time. You can update the Caddyfile and restart the Docker Compose project to start sharing the new configuration with the same reserved public subdomain."}),"\n",(0,o.jsxs)(r.ol,{children:["\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Create a Caddyfile. This example demonstrates proxying two HTTP servers with a weighted round-robin load balancer."}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-console",metastring:'title="Caddyfile"',children:"http:// {\n # zrok requires this bind address template\n bind {{ .ZrokBindAddress }}\n reverse_proxy /* {\n to http://httpbin1:8080 http://httpbin2:8080\n lb_policy weighted_round_robin 3 2\n }\n}\n"})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsxs)(r.p,{children:["Create a file ",(0,o.jsx)(r.code,{children:"compose.override.yml"}),". This example adds two ",(0,o.jsx)(r.code,{children:"httpbin"})," containers for load balancing, and mounts the Caddyfile into the container."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-yaml",metastring:'title="compose.override.yml"',children:"services:\n httpbin1:\n image: mccutchen/go-httpbin\n expose: 8080\n httpbin2:\n image: mccutchen/go-httpbin\n expose: 8080\n zrok-share:\n volumes:\n - ./Caddyfile:/mnt/.zrok/Caddyfile\n"})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Start a new Docker Compose project or delete the existing state volume."}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose down --volumes\n"})}),"\n"]}),"\n"]}),"\n",(0,o.jsxs)(r.p,{children:["If you prefer to keep using the same zrok environment with the new share then delete ",(0,o.jsx)(r.code,{children:"/mnt/.zrok/reserved.json"})," instead of the entire volume."]}),"\n",(0,o.jsxs)(r.ol,{children:["\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Run the project to load the new configuration."}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose up --detach\n"})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Note the new reserved share URL from the log."}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose logs zrok-share\n"})}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-buttonless",metastring:'title="Output"',children:"INFO: zrok public URL: https://88s803f2qvao.share.zrok.io/\n"})}),"\n"]}),"\n"]})]})}function h(e={}){const{wrapper:r}={...(0,i.R)(),...e.components};return r?(0,o.jsx)(r,{...e,children:(0,o.jsx)(l,{...e})}):l(e)}},8453:(e,r,n)=>{n.d(r,{R:()=>t,x:()=>a});var s=n(6540);const o={},i=s.createContext(o);function t(e){const r=s.useContext(i);return s.useMemo((function(){return"function"==typeof e?e(r):{...r,...e}}),[r,e])}function a(e){let r;return r=e.disableParentContext?"function"==typeof e.components?e.components(o):e.components||o:t(e.components),s.createElement(i.Provider,{value:r},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/2e812224.77794a5c.js b/assets/js/2e812224.77794a5c.js deleted file mode 100644 index 462710a6..00000000 --- a/assets/js/2e812224.77794a5c.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[8471],{8611:(e,r,n)=>{n.r(r),n.d(r,{assets:()=>c,contentTitle:()=>a,default:()=>h,frontMatter:()=>t,metadata:()=>s,toc:()=>d});const s=JSON.parse('{"id":"guides/docker-share/docker_public_share_guide","title":"Docker Compose Public Share","description":"Goal","source":"@site/../docs/guides/docker-share/docker_public_share_guide.md","sourceDirName":"guides/docker-share","slug":"/guides/docker-share/docker_public_share_guide","permalink":"/docs/guides/docker-share/docker_public_share_guide","draft":false,"unlisted":false,"editUrl":"https://github.com/openziti/zrok/blob/main/docs/../docs/guides/docker-share/docker_public_share_guide.md","tags":[],"version":"current","sidebarPosition":10,"frontMatter":{"title":"Docker Compose Public Share","sidebar_position":10,"sidebar_label":"Public Share"},"sidebar":"tutorialSidebar","previous":{"title":"Getting Started with Docker","permalink":"/docs/guides/docker-share/"},"next":{"title":"Private Share","permalink":"/docs/guides/docker-share/docker_private_share_guide"}}');var o=n(4848),i=n(8453);const t={title:"Docker Compose Public Share",sidebar_position:10,sidebar_label:"Public Share"},a=void 0,c={},d=[{value:"Goal",id:"goal",level:2},{value:"Overview",id:"overview",level:2},{value:"Walkthrough Video",id:"walkthrough-video",level:2},{value:"How it Works",id:"how-it-works",level:2},{value:"Create the Docker Project",id:"create-the-docker-project",level:2},{value:"Proxy Any Web Server",id:"proxy-any-web-server",level:2},{value:"Require Authentication",id:"require-authentication",level:2},{value:"OAuth Email",id:"oauth-email",level:3},{value:"Caddy is Powerful",id:"caddy-is-powerful",level:2}];function l(e){const r={a:"a",code:"code",h2:"h2",h3:"h3",li:"li",ol:"ol",p:"p",pre:"pre",...(0,i.R)(),...e.components};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(r.h2,{id:"goal",children:"Goal"}),"\n",(0,o.jsx)(r.p,{children:"Publicly share a Docker Compose service with a separate zrok environment and a permanent zrok share URL."}),"\n",(0,o.jsx)(r.h2,{id:"overview",children:"Overview"}),"\n",(0,o.jsx)(r.p,{children:"With zrok, you can publicly share a service that's running in Docker. You need a zrok public share running somewhere that it can reach the service you're sharing. As long as that public share is running and your service is available, anyone with the address can use your service."}),"\n",(0,o.jsxs)(r.p,{children:["Here's a short article with an overview of ",(0,o.jsx)(r.a,{href:"/docs/concepts/sharing-public",children:"public sharing with zrok"}),"."]}),"\n",(0,o.jsx)(r.h2,{id:"walkthrough-video",children:"Walkthrough Video"}),"\n",(0,o.jsx)("iframe",{width:"100%",height:"315",src:"https://www.youtube.com/embed/ycov--9ZtB4",title:"YouTube video player",frameborder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",allowfullscreen:!0}),"\n",(0,o.jsx)(r.h2,{id:"how-it-works",children:"How it Works"}),"\n",(0,o.jsx)(r.p,{children:"The Docker Compose project uses your zrok account token to reserve a public subdomain and keep sharing the backend\ntarget."}),"\n",(0,o.jsx)(r.p,{children:"When the project runs it will:"}),"\n",(0,o.jsxs)(r.ol,{children:["\n",(0,o.jsxs)(r.li,{children:["enable a zrok environment unless ",(0,o.jsx)(r.code,{children:"/mnt/.zrok/environment.json"})," exists in the ",(0,o.jsx)(r.code,{children:"zrok_env"})," volume"]}),"\n",(0,o.jsxs)(r.li,{children:["reserve a public subdomain for the service unless ",(0,o.jsx)(r.code,{children:"/mnt/.zrok/reserved.json"})," exists"]}),"\n",(0,o.jsxs)(r.li,{children:["start sharing the target specified in the ",(0,o.jsx)(r.code,{children:"ZROK_TARGET"})," environment variable"]}),"\n"]}),"\n",(0,o.jsx)(r.h2,{id:"create-the-docker-project",children:"Create the Docker Project"}),"\n",(0,o.jsxs)(r.ol,{children:["\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Make a folder on your computer to use as a Docker Compose project for your zrok public share with a reserved subdomain and switch to the new directory in your terminal."}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsxs)(r.p,{children:["Download ",(0,o.jsxs)(r.a,{href:"pathname:///zrok-public-reserved/compose.yml",children:["the reserved public share ",(0,o.jsx)(r.code,{children:"compose.yml"})," project file"]})," into the same directory."]}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsxs)(r.p,{children:["Copy your zrok account's enable token from the zrok web console to your clipboard and paste it in a file named ",(0,o.jsx)(r.code,{children:".env"})," in the same folder like this:"]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",metastring:'title=".env"',children:'ZROK_ENABLE_TOKEN="8UL9-48rN0ua"\n'})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Name the Share"}),"\n",(0,o.jsxs)(r.p,{children:["This unique name becomes part of the domain name of the share, e.g. ",(0,o.jsx)(r.code,{children:"https://my-prod-app.in.zrok.io"}),". A random name is generated if you don't specify one."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",metastring:'title=".env"',children:'ZROK_UNIQUE_NAME="my-prod-app"\n'})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsxs)(r.p,{children:["Run the Compose project to start sharing the built-in demo web server. Be sure to ",(0,o.jsx)(r.code,{children:"--detach"})," so the project runs in the background if you want it to auto-restart when your computer reboots."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose up --detach\n"})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsxs)(r.p,{children:["Get the public share URL from the output of the ",(0,o.jsx)(r.code,{children:"zrok-share"})," service or by peeking in the zrok console where the share will appear in the graph."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose logs zrok-share\n"})}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-buttonless",metastring:'title="Output"',children:"zrok-public-share-1 | https://w6r1vesearkj.in.zrok.io/\n"})}),"\n"]}),"\n"]}),"\n",(0,o.jsx)(r.p,{children:"This concludes the minimum steps to begin sharing the demo web server. Read on to learn how to pivot to sharing any website or web service by leveraging additional zrok backend modes."}),"\n",(0,o.jsx)(r.h2,{id:"proxy-any-web-server",children:"Proxy Any Web Server"}),"\n",(0,o.jsxs)(r.p,{children:["The simplest way to share your existing HTTP server is to set ",(0,o.jsx)(r.code,{children:"ZROK_TARGET"})," (e.g. ",(0,o.jsx)(r.code,{children:"https://example.com"}),") in the environment of the ",(0,o.jsx)(r.code,{children:"docker compose up"})," command. When you restart the share will auto-configure for that URL."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",metastring:'title=".env"',children:'ZROK_TARGET="http://example.com:8080"\n'})}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose down && docker compose up\n"})}),"\n",(0,o.jsx)(r.h2,{id:"require-authentication",children:"Require Authentication"}),"\n",(0,o.jsx)(r.p,{children:"You can require a password or an OAuth login with certain email addresses."}),"\n",(0,o.jsx)(r.h3,{id:"oauth-email",children:"OAuth Email"}),"\n",(0,o.jsxs)(r.p,{children:["You can allow specific email addresse patterns by setting ",(0,o.jsx)(r.code,{children:"ZROK_OAUTH_PROVIDER"})," to ",(0,o.jsx)(r.code,{children:"github"})," or ",(0,o.jsx)(r.code,{children:"google"})," and\n",(0,o.jsx)(r.code,{children:"ZROK_OAUTH_EMAILS"}),". Read more about the OAuth features in ",(0,o.jsx)(r.a,{href:"https://blog.openziti.io/the-zrok-oauth-public-frontend",children:"this blog\npost"}),"."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",metastring:'title=".env"',children:'ZROK_OAUTH_PROVIDER="github"\nZROK_OAUTH_EMAILS="alice@example.com *@acme.example.com"\n'})}),"\n",(0,o.jsx)(r.h2,{id:"caddy-is-powerful",children:"Caddy is Powerful"}),"\n",(0,o.jsxs)(r.p,{children:["The reserved public share project uses zrok's default backend mode, ",(0,o.jsx)(r.code,{children:"proxy"}),". Another backend mode, ",(0,o.jsx)(r.code,{children:"caddy"}),", accepts a path to ",(0,o.jsx)(r.a,{href:"https://caddyserver.com/docs/caddyfile",children:"a Caddyfile"})," as the value of ",(0,o.jsx)(r.code,{children:"ZROK_TARGET"})," (",(0,o.jsx)(r.a,{href:"https://github.com/openziti/zrok/tree/main/etc/caddy",children:"zrok Caddyfile examples"}),")."]}),"\n",(0,o.jsxs)(r.p,{children:["Caddy is the most powerful and flexible backend mode in zrok. You must reserve a new public subdomain whenever you switch the backend mode, so using ",(0,o.jsx)(r.code,{children:"caddy"})," reduces the risk that you'll have to share a new frontend URL with your users."]}),"\n",(0,o.jsx)(r.p,{children:"With Caddy, you can balance the workload for websites or web services or share static sites and files or all of the above at the same time. You can update the Caddyfile and restart the Docker Compose project to start sharing the new configuration with the same reserved public subdomain."}),"\n",(0,o.jsxs)(r.ol,{children:["\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Create a Caddyfile. This example demonstrates proxying two HTTP servers with a weighted round-robin load balancer."}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-console",metastring:'title="Caddyfile"',children:"http:// {\n # zrok requires this bind address template\n bind {{ .ZrokBindAddress }}\n reverse_proxy /* {\n to http://httpbin1:8080 http://httpbin2:8080\n lb_policy weighted_round_robin 3 2\n }\n}\n"})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsxs)(r.p,{children:["Create a file ",(0,o.jsx)(r.code,{children:"compose.override.yml"}),". This example adds two ",(0,o.jsx)(r.code,{children:"httpbin"})," containers for load balancing, and mounts the Caddyfile into the container."]}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-yaml",metastring:'title="compose.override.yml"',children:"services:\n httpbin1:\n image: mccutchen/go-httpbin\n expose: 8080\n httpbin2:\n image: mccutchen/go-httpbin\n expose: 8080\n zrok-share:\n volumes:\n - ./Caddyfile:/mnt/.zrok/Caddyfile\n"})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Start a new Docker Compose project or delete the existing state volume."}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose down --volumes\n"})}),"\n"]}),"\n"]}),"\n",(0,o.jsxs)(r.p,{children:["If you prefer to keep using the same zrok environment with the new share then delete ",(0,o.jsx)(r.code,{children:"/mnt/.zrok/reserved.json"})," instead of the entire volume."]}),"\n",(0,o.jsxs)(r.ol,{children:["\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Run the project to load the new configuration."}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose up --detach\n"})}),"\n"]}),"\n",(0,o.jsxs)(r.li,{children:["\n",(0,o.jsx)(r.p,{children:"Note the new reserved share URL from the log."}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-bash",children:"docker compose logs zrok-share\n"})}),"\n",(0,o.jsx)(r.pre,{children:(0,o.jsx)(r.code,{className:"language-buttonless",metastring:'title="Output"',children:"INFO: zrok public URL: https://88s803f2qvao.in.zrok.io/\n"})}),"\n"]}),"\n"]})]})}function h(e={}){const{wrapper:r}={...(0,i.R)(),...e.components};return r?(0,o.jsx)(r,{...e,children:(0,o.jsx)(l,{...e})}):l(e)}},8453:(e,r,n)=>{n.d(r,{R:()=>t,x:()=>a});var s=n(6540);const o={},i=s.createContext(o);function t(e){const r=s.useContext(i);return s.useMemo((function(){return"function"==typeof e?e(r):{...r,...e}}),[r,e])}function a(e){let r;return r=e.disableParentContext?"function"==typeof e.components?e.components(o):e.components||o:t(e.components),s.createElement(i.Provider,{value:r},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/6272ba0e.80d989e8.js b/assets/js/6272ba0e.e147ca1e.js similarity index 74% rename from assets/js/6272ba0e.80d989e8.js rename to assets/js/6272ba0e.e147ca1e.js index 918e12a0..a8f04177 100644 --- a/assets/js/6272ba0e.80d989e8.js +++ b/assets/js/6272ba0e.e147ca1e.js @@ -1 +1 @@ -"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[7242],{2816:(e,r,s)=>{s.r(r),s.d(r,{assets:()=>d,contentTitle:()=>i,default:()=>l,frontMatter:()=>a,metadata:()=>n,toc:()=>c});const n=JSON.parse('{"id":"concepts/sharing-reserved","title":"Reserved Shares","description":"By default, a public or private share is assigned a share token when you create a share using the zrok share command. The zrok share command is the bridge between your local environment and the users you are sharing with. When you terminate the zrok share, the bridge is eliminated and the share token is deleted. If you run zrok share again, you will be allocated a brand new share token.","source":"@site/../docs/concepts/sharing-reserved.md","sourceDirName":"concepts","slug":"/concepts/sharing-reserved","permalink":"/docs/concepts/sharing-reserved","draft":false,"unlisted":false,"editUrl":"https://github.com/openziti/zrok/blob/main/docs/../docs/concepts/sharing-reserved.md","tags":[],"version":"current","sidebarPosition":10,"frontMatter":{"sidebar_position":10},"sidebar":"tutorialSidebar","previous":{"title":"Public Shares","permalink":"/docs/concepts/sharing-public"},"next":{"title":"Sharing HTTP Servers","permalink":"/docs/concepts/http"}}');var t=s(4848),o=s(8453);const a={sidebar_position:10},i="Reserved Shares",d={},c=[{value:"Unique Names",id:"unique-names",level:2}];function h(e){const r={code:"code",em:"em",h1:"h1",h2:"h2",header:"header",p:"p",pre:"pre",...(0,o.R)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(r.header,{children:(0,t.jsx)(r.h1,{id:"reserved-shares",children:"Reserved Shares"})}),"\n",(0,t.jsxs)(r.p,{children:["By default, a ",(0,t.jsx)(r.code,{children:"public"})," or ",(0,t.jsx)(r.code,{children:"private"})," share is assigned a ",(0,t.jsx)(r.em,{children:"share token"})," when you create a share using the ",(0,t.jsx)(r.code,{children:"zrok share"})," command. The ",(0,t.jsx)(r.code,{children:"zrok share"})," command is the bridge between your local environment and the users you are sharing with. When you terminate the ",(0,t.jsx)(r.code,{children:"zrok share"}),", the bridge is eliminated and the ",(0,t.jsx)(r.em,{children:"share token"})," is deleted. If you run ",(0,t.jsx)(r.code,{children:"zrok share"})," again, you will be allocated a brand new ",(0,t.jsx)(r.em,{children:"share token"}),"."]}),"\n",(0,t.jsxs)(r.p,{children:["You can use a ",(0,t.jsx)(r.code,{children:"reserved"})," share to persist your ",(0,t.jsx)(r.em,{children:"share token"})," across multiple runs of the ",(0,t.jsx)(r.code,{children:"zrok share"})," bridge. When you use a ",(0,t.jsx)(r.code,{children:"reserved"})," share, the share token will not be deleted between multiple runs of ",(0,t.jsx)(r.code,{children:"zrok share"}),"."]}),"\n",(0,t.jsxs)(r.p,{children:["To use a ",(0,t.jsx)(r.code,{children:"reserved"})," share, you will first run the ",(0,t.jsx)(r.code,{children:"zrok reserve"})," command to create the reserved share (see ",(0,t.jsx)(r.code,{children:"zrok reserve --help"})," for details). Once you've created your ",(0,t.jsx)(r.code,{children:"reserved"})," share, you will use the ",(0,t.jsx)(r.code,{children:"zrok share reserved"})," command (see ",(0,t.jsx)(r.code,{children:"--help"})," for details) to run the bridge for the shared resource."]}),"\n",(0,t.jsxs)(r.p,{children:["This pattern works for both ",(0,t.jsx)(r.code,{children:"public"})," and ",(0,t.jsx)(r.code,{children:"private"})," shares, and for all resource types supported by ",(0,t.jsx)(r.code,{children:"zrok"}),"."]}),"\n",(0,t.jsxs)(r.p,{children:["To delete your ",(0,t.jsx)(r.code,{children:"reserved"})," share use the ",(0,t.jsx)(r.code,{children:"zrok release"})," command or click the delete button in the share's ",(0,t.jsx)(r.em,{children:"Actions"})," tab in the web console."]}),"\n",(0,t.jsx)(r.h2,{id:"unique-names",children:"Unique Names"}),"\n",(0,t.jsxs)(r.p,{children:["The default is to generate a random ",(0,t.jsx)(r.em,{children:"share token"})," and you may specify a ",(0,t.jsx)(r.em,{children:"unique name"}),"."]}),"\n",(0,t.jsx)(r.p,{children:'This reserves public share token "myshare."'}),"\n",(0,t.jsx)(r.pre,{children:(0,t.jsx)(r.code,{className:"language-bash",metastring:'title="Reserve with the Command Line"',children:'zrok reserve public 80 --unique-name "myshare"\n'})}),"\n",(0,t.jsxs)(r.p,{children:["This shares ",(0,t.jsx)(r.code,{children:"127.0.0.1:80"})," as ",(0,t.jsx)(r.code,{children:"https://myshare.zrok.example.com"})," where ",(0,t.jsx)(r.code,{children:"https://{token}.zrok.example.com"})," is the frontend's template."]}),"\n",(0,t.jsx)(r.pre,{children:(0,t.jsx)(r.code,{className:"language-bash",metastring:'title="Share a Reserved Token"',children:'zrok share reserved "myshare"\n'})})]})}function l(e={}){const{wrapper:r}={...(0,o.R)(),...e.components};return r?(0,t.jsx)(r,{...e,children:(0,t.jsx)(h,{...e})}):h(e)}},8453:(e,r,s)=>{s.d(r,{R:()=>a,x:()=>i});var n=s(6540);const t={},o=n.createContext(t);function a(e){const r=n.useContext(o);return n.useMemo((function(){return"function"==typeof e?e(r):{...r,...e}}),[r,e])}function i(e){let r;return r=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:a(e.components),n.createElement(o.Provider,{value:r},e.children)}}}]); \ No newline at end of file +"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[7242],{2816:(e,r,s)=>{s.r(r),s.d(r,{assets:()=>d,contentTitle:()=>i,default:()=>l,frontMatter:()=>a,metadata:()=>n,toc:()=>c});const n=JSON.parse('{"id":"concepts/sharing-reserved","title":"Reserved Shares","description":"By default, a public or private share is assigned a share token when you create a share using the zrok share command. The zrok share command is the bridge between your local environment and the users you are sharing with. When you terminate the zrok share, the bridge is eliminated and the share token is deleted. If you run zrok share again, you will be allocated a brand new share token.","source":"@site/../docs/concepts/sharing-reserved.md","sourceDirName":"concepts","slug":"/concepts/sharing-reserved","permalink":"/docs/concepts/sharing-reserved","draft":false,"unlisted":false,"editUrl":"https://github.com/openziti/zrok/blob/main/docs/../docs/concepts/sharing-reserved.md","tags":[],"version":"current","sidebarPosition":10,"frontMatter":{"sidebar_position":10},"sidebar":"tutorialSidebar","previous":{"title":"Public Shares","permalink":"/docs/concepts/sharing-public"},"next":{"title":"Sharing HTTP Servers","permalink":"/docs/concepts/http"}}');var t=s(4848),o=s(8453);const a={sidebar_position:10},i="Reserved Shares",d={},c=[{value:"Unique Names",id:"unique-names",level:2}];function h(e){const r={code:"code",em:"em",h1:"h1",h2:"h2",header:"header",p:"p",pre:"pre",...(0,o.R)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(r.header,{children:(0,t.jsx)(r.h1,{id:"reserved-shares",children:"Reserved Shares"})}),"\n",(0,t.jsxs)(r.p,{children:["By default, a ",(0,t.jsx)(r.code,{children:"public"})," or ",(0,t.jsx)(r.code,{children:"private"})," share is assigned a ",(0,t.jsx)(r.em,{children:"share token"})," when you create a share using the ",(0,t.jsx)(r.code,{children:"zrok share"})," command. The ",(0,t.jsx)(r.code,{children:"zrok share"})," command is the bridge between your local environment and the users you are sharing with. When you terminate the ",(0,t.jsx)(r.code,{children:"zrok share"}),", the bridge is eliminated and the ",(0,t.jsx)(r.em,{children:"share token"})," is deleted. If you run ",(0,t.jsx)(r.code,{children:"zrok share"})," again, you will be allocated a brand new ",(0,t.jsx)(r.em,{children:"share token"}),"."]}),"\n",(0,t.jsxs)(r.p,{children:["You can use a ",(0,t.jsx)(r.code,{children:"reserved"})," share to persist your ",(0,t.jsx)(r.em,{children:"share token"})," across multiple runs of the ",(0,t.jsx)(r.code,{children:"zrok share"})," bridge. When you use a ",(0,t.jsx)(r.code,{children:"reserved"})," share, the share token will not be deleted between multiple runs of ",(0,t.jsx)(r.code,{children:"zrok share"}),"."]}),"\n",(0,t.jsxs)(r.p,{children:["To use a ",(0,t.jsx)(r.code,{children:"reserved"})," share, you will first run the ",(0,t.jsx)(r.code,{children:"zrok reserve"})," command to create the reserved share (see ",(0,t.jsx)(r.code,{children:"zrok reserve --help"})," for details). Once you've created your ",(0,t.jsx)(r.code,{children:"reserved"})," share, you will use the ",(0,t.jsx)(r.code,{children:"zrok share reserved"})," command (see ",(0,t.jsx)(r.code,{children:"--help"})," for details) to run the bridge for the shared resource."]}),"\n",(0,t.jsxs)(r.p,{children:["This pattern works for both ",(0,t.jsx)(r.code,{children:"public"})," and ",(0,t.jsx)(r.code,{children:"private"})," shares, and for all resource types supported by ",(0,t.jsx)(r.code,{children:"zrok"}),"."]}),"\n",(0,t.jsxs)(r.p,{children:["To delete your ",(0,t.jsx)(r.code,{children:"reserved"})," share use the ",(0,t.jsx)(r.code,{children:"zrok release"})," command or click the delete button in the share's ",(0,t.jsx)(r.em,{children:"Actions"})," tab in the web console."]}),"\n",(0,t.jsx)(r.h2,{id:"unique-names",children:"Unique Names"}),"\n",(0,t.jsxs)(r.p,{children:["The default is to generate a random ",(0,t.jsx)(r.em,{children:"share token"})," and you may instead specify a ",(0,t.jsx)(r.em,{children:"unique name"}),". The unique name must be lowercase alphanumeric, between 4 and 32 characters in length."]}),"\n",(0,t.jsx)(r.p,{children:'This reserves public share token "toaster".'}),"\n",(0,t.jsx)(r.pre,{children:(0,t.jsx)(r.code,{className:"language-bash",metastring:'title="Reserve with the Command Line"',children:'zrok reserve public 80 --unique-name "toaster"\n'})}),"\n",(0,t.jsxs)(r.p,{children:["This shares ",(0,t.jsx)(r.code,{children:"127.0.0.1:80"})," as ",(0,t.jsx)(r.code,{children:"https://toaster.zrok.example.com"})," where ",(0,t.jsx)(r.code,{children:"https://{token}.zrok.example.com"})," is the frontend's template."]}),"\n",(0,t.jsx)(r.pre,{children:(0,t.jsx)(r.code,{className:"language-bash",metastring:'title="Share a Reserved Token"',children:'zrok share reserved "toaster"\n'})})]})}function l(e={}){const{wrapper:r}={...(0,o.R)(),...e.components};return r?(0,t.jsx)(r,{...e,children:(0,t.jsx)(h,{...e})}):h(e)}},8453:(e,r,s)=>{s.d(r,{R:()=>a,x:()=>i});var n=s(6540);const t={},o=n.createContext(t);function a(e){const r=n.useContext(o);return n.useMemo((function(){return"function"==typeof e?e(r):{...r,...e}}),[r,e])}function i(e){let r;return r=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:a(e.components),n.createElement(o.Provider,{value:r},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/cda0d2e5.19e28221.js b/assets/js/cda0d2e5.19e28221.js new file mode 100644 index 00000000..08b9b72b --- /dev/null +++ b/assets/js/cda0d2e5.19e28221.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[2757],{633:(e,r,n)=>{n.d(r,{Ay:()=>a,RM:()=>t});var s=n(4848),i=n(8453);const t=[];function o(e){const r={a:"a",code:"code",li:"li",ol:"ol",p:"p",pre:"pre",...(0,i.R)(),...e.components};return(0,s.jsxs)(r.ol,{children:["\n",(0,s.jsxs)(r.li,{children:["\n",(0,s.jsxs)(r.p,{children:["Set up ",(0,s.jsx)(r.code,{children:"zrok"}),"'s Linux package repository by following ",(0,s.jsx)(r.a,{href:"/docs/guides/install/linux#install-zrok-from-the-repository",children:"the Linux install guide"}),", or run this one-liner to complete the repo setup and install packages."]}),"\n",(0,s.jsx)(r.pre,{children:(0,s.jsx)(r.code,{className:"language-bash",children:"curl -sSLf https://get.openziti.io/install.bash \\\n| sudo bash -s zrok-share\n"})}),"\n"]}),"\n",(0,s.jsxs)(r.li,{children:["\n",(0,s.jsxs)(r.p,{children:["If you set up the repository by following the guide, then also install the ",(0,s.jsx)(r.code,{children:"zrok-share"})," package. This package provides the systemd service."]}),"\n",(0,s.jsx)(r.pre,{children:(0,s.jsx)(r.code,{className:"language-bash",metastring:'title="Ubuntu, Debian"',children:"sudo apt install zrok-share\n"})}),"\n",(0,s.jsx)(r.pre,{children:(0,s.jsx)(r.code,{className:"language-bash",metastring:'title="Fedora, Rocky"',children:"sudo dnf install zrok-share\n"})}),"\n"]}),"\n"]})}function a(e={}){const{wrapper:r}={...(0,i.R)(),...e.components};return r?(0,s.jsx)(r,{...e,children:(0,s.jsx)(o,{...e})}):o(e)}},4888:(e,r,n)=>{n.r(r),n.d(r,{assets:()=>v,contentTitle:()=>x,default:()=>f,frontMatter:()=>b,metadata:()=>s,toc:()=>k});const s=JSON.parse('{"id":"guides/frontdoor","title":"zrok frontdoor","description":"zrok frontdoor is the heavy-duty front door to your app or site. It makes your website or app available to your online audience through the shield of zrok.io\'s hardened, managed frontends.","source":"@site/../docs/guides/frontdoor.mdx","sourceDirName":"guides","slug":"/guides/frontdoor","permalink":"/docs/guides/frontdoor","draft":false,"unlisted":false,"editUrl":"https://github.com/openziti/zrok/blob/main/docs/../docs/guides/frontdoor.mdx","tags":[],"version":"current","sidebarPosition":20,"frontMatter":{"title":"zrok frontdoor","sidebar_label":"frontdoor","sidebar_position":20,"hide_table_of_contents":true},"sidebar":"tutorialSidebar","previous":{"title":"Windows","permalink":"/docs/guides/install/windows"},"next":{"title":"Permission Modes","permalink":"/docs/guides/permission-modes"}}');var i=n(4848),t=n(8453),o=n(9028),a=n(9365),l=n(633),d=n(397),c=n(3902);const h=[{value:"Installation",id:"installation",level:2},...l.RM,{value:"Enable",id:"enable",level:2},{value:"Name your Share",id:"name-your-share",level:2},{value:"Use Cases",id:"use-cases",level:2},{value:"Proxy a Web Server",id:"proxy-a-web-server",level:3},{value:"Serve Static Files",id:"serve-static-files",level:3},{value:"Caddy Server",id:"caddy-server",level:3},{value:"Network Drive",id:"network-drive",level:3},{value:"Authentication",id:"authentication",level:2},{value:"OAuth",id:"oauth",level:3},{value:"Password",id:"password",level:3},{value:"Start the Service",id:"start-the-service",level:2},{value:"Compatibility",id:"compatibility",level:2},{value:"Package Contents",id:"package-contents",level:2}];function u(e){const r={a:"a",code:"code",h2:"h2",h3:"h3",li:"li",p:"p",pre:"pre",ul:"ul",...(0,t.R)(),...e.components},{Details:n}=r;return n||function(e,r){throw new Error("Expected "+(r?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}("Details",!0),(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(r.h2,{id:"installation",children:"Installation"}),"\n",(0,i.jsx)(l.Ay,{}),"\n",(0,i.jsxs)(n,{children:[(0,i.jsx)("summary",{children:"Ansible Playbook"}),(0,i.jsxs)(c.A,{title:"Set up package repository and install zrok-share",children:[d.A,"\n- name: Install zrok-share package\ngather_facts: false\nhosts: all \nbecome: true\ntasks:\n- name: Install zrok-share\n ansible.builtin.package:\n name: zrok-share\n state: present\n\n- name: Copy env config from Ansible controller to target\n copy:\n dest: /opt/openziti/etc/zrok/zrok-share.env\n src: /opt/openziti/etc/zrok/zrok-share.env\n\n- name: Enable and restart service\n systemd:\n name: zrok-share\n enabled: yes\n state: restarted\n daemon_reload: yes\n\n- name: Wait for service\n systemd:\n name: zrok-share\n state: started\n register: service_status\n until: service_status.status.ActiveState == 'active'\n retries: 30\n delay: 1\n"]})]}),"\n",(0,i.jsx)(r.h2,{id:"enable",children:"Enable"}),"\n",(0,i.jsx)(r.p,{children:"Save the enable token from the zrok console in the configuration file."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_ENABLE_TOKEN="14cbfca9772f"\n'})}),"\n",(0,i.jsx)(r.h2,{id:"name-your-share",children:"Name your Share"}),"\n",(0,i.jsxs)(r.p,{children:["This unique name becomes part of the domain name of the share, e.g. ",(0,i.jsx)(r.code,{children:"https://toaster.share.zrok.io"}),". A random name is generated if you don't specify one. The name must be lowercase alphanumeric, between 4 and 32 characters in length."]}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_UNIQUE_NAME="toaster"\n'})}),"\n",(0,i.jsx)(r.h2,{id:"use-cases",children:"Use Cases"}),"\n",(0,i.jsxs)(r.p,{children:["You may change the target for the current backend mode, e.g. ",(0,i.jsx)(r.code,{children:"proxy"}),", by editing the configuration file and restarting the service. The reserved subdomain will remain the same."]}),"\n",(0,i.jsxs)(r.p,{children:["You may switch between backend modes or change authentication options by deleting ",(0,i.jsx)(r.code,{children:"/var/lib/zrok-share/.zrok/reserved.json"})," and restarting the service. A new subdomain will be reserved."]}),"\n",(0,i.jsx)(r.h3,{id:"proxy-a-web-server",children:"Proxy a Web Server"}),"\n",(0,i.jsx)(r.p,{children:"Proxy a reserved subdomain to an existing web server. The web server could be on a private network or on the same host as zrok."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_TARGET="http://127.0.0.1:3000"\nZROK_BACKEND_MODE="proxy"\n'})}),"\n",(0,i.jsxs)(r.p,{children:["If your HTTPS server has an unverifiable TLS server certificate then you must set ",(0,i.jsx)(r.code,{children:"--insecure"}),"."]}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_INSECURE="--insecure"\n'})}),"\n",(0,i.jsx)(r.h3,{id:"serve-static-files",children:"Serve Static Files"}),"\n",(0,i.jsxs)(r.p,{children:["Run zrok's embedded web server to serve the files in a directory. If there's an ",(0,i.jsx)(r.code,{children:"index.html"})," file in the directory then visitors will see that web page in their browser, otherwise they'll see a generated index of the files. The directory must be readable by 'other', e.g. ",(0,i.jsx)(r.code,{children:"chmod -R o+rX /var/www/html"}),"."]}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_TARGET="/var/www/html"\nZROK_BACKEND_MODE="web"\n'})}),"\n",(0,i.jsx)(r.h3,{id:"caddy-server",children:"Caddy Server"}),"\n",(0,i.jsx)(r.p,{children:"Use zrok's built-in Caddy server to serve static files or as a reverse proxy to multiple web servers with various HTTP routes or as a load-balanced set. A sample Caddyfile is available in the path shown."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_TARGET="/opt/openziti/etc/zrok/multiple_upstream.Caddyfile"\nZROK_BACKEND_MODE="caddy"\n'})}),"\n",(0,i.jsx)(r.h3,{id:"network-drive",children:"Network Drive"}),"\n",(0,i.jsxs)(r.p,{children:["This uses zrok's ",(0,i.jsx)(r.code,{children:"drive"})," backend mode to serve a directory of static files as a virtual network drive. The directory must be readable by 'other', e.g. ",(0,i.jsx)(r.code,{children:"chmod -R o+rX /usr/share/doc"}),"."]}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_TARGET="/usr/share/doc"\nZROK_BACKEND_MODE="drive"\n'})}),"\n",(0,i.jsxs)(r.p,{children:[(0,i.jsx)(r.a,{href:"https://blog.openziti.io/zrok-drives-an-early-preview",children:"Learn more about this feature in this blog post"}),"."]}),"\n",(0,i.jsx)(r.h2,{id:"authentication",children:"Authentication"}),"\n",(0,i.jsx)(r.p,{children:"You can limit access to certain email addresses with OAuth or require a password."}),"\n",(0,i.jsx)(r.h3,{id:"oauth",children:"OAuth"}),"\n",(0,i.jsx)(r.p,{children:"You can require that visitors authenticate with an email address that matches at least one of the suffixes you specify. Add the following to the configuration file."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_OAUTH_PROVIDER="github" # or google\nZROK_OAUTH_EMAILS="alice@example.com *@acme.example.com"\n'})}),"\n",(0,i.jsx)(r.h3,{id:"password",children:"Password"}),"\n",(0,i.jsx)(r.p,{children:"Enable HTTP basic authentication by adding the following to the configuration file."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_BASIC_AUTH="user:passwd"\n'})}),"\n",(0,i.jsx)(r.h2,{id:"start-the-service",children:"Start the Service"}),"\n",(0,i.jsx)(r.p,{children:"Start the service, and check the zrok console or the service log for the reserved subdomain."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="run now and at startup"',children:"sudo systemctl enable --now zrok-share.service\n"})}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="run now"',children:"sudo systemctl restart zrok-share.service\n"})}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",children:"journalctl -u zrok-share.service\n"})}),"\n",(0,i.jsx)(r.h2,{id:"compatibility",children:"Compatibility"}),"\n",(0,i.jsxs)(r.p,{children:["The Linux distribution must have a package manager that understands the ",(0,i.jsx)(r.code,{children:".deb"})," or ",(0,i.jsx)(r.code,{children:".rpm"})," format and be running systemd v232 or newer. The service was tested with:"]}),"\n",(0,i.jsxs)(r.ul,{children:["\n",(0,i.jsx)(r.li,{children:"Ubuntu 20.04, 22.04, 23.04"}),"\n",(0,i.jsx)(r.li,{children:"Debian 11 12"}),"\n",(0,i.jsx)(r.li,{children:"Rocky 8, 9"}),"\n",(0,i.jsx)(r.li,{children:"Fedora 37, 38"}),"\n"]}),"\n",(0,i.jsx)(r.h2,{id:"package-contents",children:"Package Contents"}),"\n",(0,i.jsxs)(r.p,{children:["The files included in the ",(0,i.jsx)(r.code,{children:"zrok-share"})," package are sourced ",(0,i.jsx)(r.a,{href:"https://github.com/openziti/zrok/tree/main/nfpm",children:"here in GitHub"}),"."]})]})}function p(e={}){const{wrapper:r}={...(0,t.R)(),...e.components};return r?(0,i.jsx)(r,{...e,children:(0,i.jsx)(u,{...e})}):u(e)}var m=n(1122),g=n(6025);const b={title:"zrok frontdoor",sidebar_label:"frontdoor",sidebar_position:20,hide_table_of_contents:!0},x=void 0,v={},k=[{value:"Overview",id:"overview",level:2},{value:"Choose your OS",id:"choose-your-os",level:2},{value:"Goal",id:"goal",level:2},{value:"How it Works",id:"how-it-works",level:2},...h,{value:"Concepts",id:"concepts",level:2}];function j(e){const r={a:"a",code:"code",h2:"h2",li:"li",ol:"ol",p:"p",strong:"strong",...(0,t.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(r.p,{children:[(0,i.jsx)(r.strong,{children:"zrok frontdoor"})," is the heavy-duty front door to your app or site. It makes your website or app available to your online audience through the shield of zrok.io's hardened, managed frontends."]}),"\n",(0,i.jsx)("iframe",{width:"100%",height:"315",src:"https://www.youtube.com/embed/5Vi8GKuTi_I",title:"YouTube video player",frameborder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",allowfullscreen:!0}),"\n",(0,i.jsx)(r.h2,{id:"overview",children:"Overview"}),"\n",(0,i.jsxs)(r.p,{children:["zrok frontends are the parts of zrok that proxy incoming public web traffic to zrok backend shares via OpenZiti. When you use zrok with a ",(0,i.jsx)(r.code,{children:"zrok.io"})," frontend, you're using ",(0,i.jsx)(r.strong,{children:"zrok frontdoor"}),". ",(0,i.jsx)(r.code,{children:"zrok.io"})," is zrok-as-a-service by NetFoundry, the team behind OpenZiti. You need a free account to use ",(0,i.jsx)(r.strong,{children:"zrok frontdoor"}),"."]}),"\n",(0,i.jsx)(m.A,{alt:"frontdoor diagram",sources:{light:(0,g.Ay)("/img/zrok-frontdoor-light-mode.svg"),dark:(0,g.Ay)("/img/zrok-frontdoor-dark-mode.svg")}}),"\n",(0,i.jsx)(r.h2,{id:"choose-your-os",children:"Choose your OS"}),"\n",(0,i.jsx)(r.p,{children:"Choose between installing the Linux package or running zrok with Docker (Linux, macOS, or Windows)."}),"\n","\n",(0,i.jsxs)(o.A,{queryString:"os",values:[{label:"Linux",value:"Linux"},{label:"Docker",value:"Docker"}],children:[(0,i.jsxs)(a.A,{value:"Linux",children:[(0,i.jsxs)(r.p,{children:["On Linux, zrok frontdoor is implemented natively as a system service provided by the ",(0,i.jsx)(r.code,{children:"zrok-share"})," DEB or RPM package."]}),(0,i.jsx)(r.h2,{id:"goal",children:"Goal"}),(0,i.jsx)(r.p,{children:"Proxy a reserved public subdomain to a backend target with an always-on Linux system service."}),(0,i.jsx)(r.h2,{id:"how-it-works",children:"How it Works"}),(0,i.jsxs)(r.p,{children:["The ",(0,i.jsx)(r.code,{children:"zrok-share"})," package creates a ",(0,i.jsx)(r.code,{children:"zrok-share.service"})," unit in systemd. The administrator edits the service's configuration file to specify the:"]}),(0,i.jsxs)(r.ol,{children:["\n",(0,i.jsx)(r.li,{children:"zrok account token"}),"\n",(0,i.jsxs)(r.li,{children:["target URL or files to be shared and backend mode, e.g. ",(0,i.jsx)(r.code,{children:"proxy"})]}),"\n",(0,i.jsx)(r.li,{children:"authentication options, if wanted"}),"\n"]}),(0,i.jsx)(r.p,{children:"When the service starts it will:"}),(0,i.jsxs)(r.ol,{children:["\n",(0,i.jsxs)(r.li,{children:["enable the zrok environment unless ",(0,i.jsx)(r.code,{children:"/var/lib/zrok-share/.zrok/environment.json"})," exists"]}),"\n",(0,i.jsxs)(r.li,{children:["reserve a public subdomain for the service unless ",(0,i.jsx)(r.code,{children:"/var/lib/zrok-share/.zrok/reserved.json"})," exists"]}),"\n",(0,i.jsxs)(r.li,{children:["start sharing the target specified as ",(0,i.jsx)(r.code,{children:"ZROK_TARGET"})," in the environment file"]}),"\n"]}),(0,i.jsx)(p,{})]}),(0,i.jsx)(a.A,{value:"Docker",children:(0,i.jsxs)(r.p,{children:["On macOS and Windows, zrok frontdoor is implemented as a Docker Compose project which reserves a public subdomain for your website or service and manages a zrok environment that's separate from the Docker host. ",(0,i.jsx)(r.a,{href:"/docs/guides/docker-share/docker_public_share_guide",children:"Link to the Docker Public Share Guide"})]})})]}),"\n",(0,i.jsx)(r.h2,{id:"concepts",children:"Concepts"}),"\n",(0,i.jsxs)(r.p,{children:["Overview of ",(0,i.jsx)(r.a,{href:"/docs/concepts/sharing-reserved",children:"zrok reserved shares"})]})]})}function f(e={}){const{wrapper:r}={...(0,t.R)(),...e.components};return r?(0,i.jsx)(r,{...e,children:(0,i.jsx)(j,{...e})}):j(e)}},3902:(e,r,n)=>{n.d(r,{A:()=>o});n(6540);var s=n(382),i=n(1432),t=n(4848);const o=e=>{let{title:r,children:n}=e;const o=n.map((e=>"string"==typeof e?e.trim():s.Ay.dump(e).trim())).join("\n\n");return(0,t.jsx)("div",{children:(0,t.jsx)(i.A,{language:"yaml",title:r,children:o})})}},9028:(e,r,n)=>{n.d(r,{A:()=>a});var s=n(6540),i=n(1470),t=n(159),o=n(4848);const a=function(e){const[r,n]=(0,s.useState)(null);return(0,s.useEffect)((()=>{["Mac OS","Windows"].includes(t.wH)?n("Docker"):n("Linux")}),[]),(0,o.jsx)(o.Fragment,{children:(0,o.jsx)(i.A,{...e,defaultValue:r,children:e.children})})}},397:(e,r,n)=>{n.d(r,{A:()=>s});const s=[{name:"Set up zrok Package Repo",gather_facts:!0,hosts:"all",become:!0,tasks:[{name:"Set up apt repo",when:'ansible_os_family == "Debian"',block:[{name:"Install playbook dependencies","ansible.builtin.package":{name:["gnupg"],state:"present"}},{name:"Fetch armored pubkey","ansible.builtin.uri":{url:"https://get.openziti.io/tun/package-repos.gpg",return_content:"yes"},register:"armored_pubkey"},{name:"Dearmor pubkey","ansible.builtin.shell":'gpg --dearmor --output /usr/share/keyrings/openziti.gpg <<< "{{ armored_pubkey.content }}"\n',args:{creates:"/usr/share/keyrings/openziti.gpg",executable:"/bin/bash"}},{name:"Set pubkey filemode","ansible.builtin.file":{path:"/usr/share/keyrings/openziti.gpg",mode:"a+rX"}},{name:"Install OpenZiti repo deb source","ansible.builtin.copy":{dest:"/etc/apt/sources.list.d/openziti-release.list",content:"deb [signed-by=/usr/share/keyrings/openziti.gpg] https://packages.openziti.org/zitipax-openziti-deb-stable debian main\n"}},{name:"Refresh Repo Sources","ansible.builtin.apt":{update_cache:"yes",cache_valid_time:3600}}]},{name:"Set up yum repo",when:'ansible_os_family == "RedHat"',block:[{name:"Install OpenZiti repo rpm source","ansible.builtin.yum_repository":{name:"OpenZitiRelease",description:"OpenZiti Release",baseurl:"https://packages.openziti.org/zitipax-openziti-rpm-stable/redhat/$basearch",enabled:"yes",gpgkey:"https://packages.openziti.org/zitipax-openziti-rpm-stable/redhat/$basearch/repodata/repomd.xml.key",repo_gpgcheck:"yes",gpgcheck:"no"}}]}]}]}}]); \ No newline at end of file diff --git a/assets/js/cda0d2e5.e386cd05.js b/assets/js/cda0d2e5.e386cd05.js deleted file mode 100644 index d92bb1a8..00000000 --- a/assets/js/cda0d2e5.e386cd05.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[2757],{633:(e,r,n)=>{n.d(r,{Ay:()=>a,RM:()=>t});var s=n(4848),i=n(8453);const t=[];function o(e){const r={a:"a",code:"code",li:"li",ol:"ol",p:"p",pre:"pre",...(0,i.R)(),...e.components};return(0,s.jsxs)(r.ol,{children:["\n",(0,s.jsxs)(r.li,{children:["\n",(0,s.jsxs)(r.p,{children:["Set up ",(0,s.jsx)(r.code,{children:"zrok"}),"'s Linux package repository by following ",(0,s.jsx)(r.a,{href:"/docs/guides/install/linux#install-zrok-from-the-repository",children:"the Linux install guide"}),", or run this one-liner to complete the repo setup and install packages."]}),"\n",(0,s.jsx)(r.pre,{children:(0,s.jsx)(r.code,{className:"language-bash",children:"curl -sSLf https://get.openziti.io/install.bash \\\n| sudo bash -s zrok-share\n"})}),"\n"]}),"\n",(0,s.jsxs)(r.li,{children:["\n",(0,s.jsxs)(r.p,{children:["If you set up the repository by following the guide, then also install the ",(0,s.jsx)(r.code,{children:"zrok-share"})," package. This package provides the systemd service."]}),"\n",(0,s.jsx)(r.pre,{children:(0,s.jsx)(r.code,{className:"language-bash",metastring:'title="Ubuntu, Debian"',children:"sudo apt install zrok-share\n"})}),"\n",(0,s.jsx)(r.pre,{children:(0,s.jsx)(r.code,{className:"language-bash",metastring:'title="Fedora, Rocky"',children:"sudo dnf install zrok-share\n"})}),"\n"]}),"\n"]})}function a(e={}){const{wrapper:r}={...(0,i.R)(),...e.components};return r?(0,s.jsx)(r,{...e,children:(0,s.jsx)(o,{...e})}):o(e)}},4888:(e,r,n)=>{n.r(r),n.d(r,{assets:()=>v,contentTitle:()=>x,default:()=>y,frontMatter:()=>b,metadata:()=>s,toc:()=>k});const s=JSON.parse('{"id":"guides/frontdoor","title":"zrok frontdoor","description":"zrok frontdoor is the heavy-duty front door to your app or site. It makes your website or app available to your online audience through the shield of zrok.io\'s hardened, managed frontends.","source":"@site/../docs/guides/frontdoor.mdx","sourceDirName":"guides","slug":"/guides/frontdoor","permalink":"/docs/guides/frontdoor","draft":false,"unlisted":false,"editUrl":"https://github.com/openziti/zrok/blob/main/docs/../docs/guides/frontdoor.mdx","tags":[],"version":"current","sidebarPosition":20,"frontMatter":{"title":"zrok frontdoor","sidebar_label":"frontdoor","sidebar_position":20,"hide_table_of_contents":true},"sidebar":"tutorialSidebar","previous":{"title":"Windows","permalink":"/docs/guides/install/windows"},"next":{"title":"Permission Modes","permalink":"/docs/guides/permission-modes"}}');var i=n(4848),t=n(8453),o=n(9028),a=n(9365),l=n(633),d=n(397),c=n(3902);const h=[{value:"Installation",id:"installation",level:2},...l.RM,{value:"Enable",id:"enable",level:2},{value:"Name your Share",id:"name-your-share",level:2},{value:"Use Cases",id:"use-cases",level:2},{value:"Proxy a Web Server",id:"proxy-a-web-server",level:3},{value:"Serve Static Files",id:"serve-static-files",level:3},{value:"Caddy Server",id:"caddy-server",level:3},{value:"Network Drive",id:"network-drive",level:3},{value:"Authentication",id:"authentication",level:2},{value:"OAuth",id:"oauth",level:3},{value:"Password",id:"password",level:3},{value:"Start the Service",id:"start-the-service",level:2},{value:"Compatibility",id:"compatibility",level:2},{value:"Package Contents",id:"package-contents",level:2}];function p(e){const r={a:"a",code:"code",h2:"h2",h3:"h3",li:"li",p:"p",pre:"pre",ul:"ul",...(0,t.R)(),...e.components},{Details:n}=r;return n||function(e,r){throw new Error("Expected "+(r?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}("Details",!0),(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(r.h2,{id:"installation",children:"Installation"}),"\n",(0,i.jsx)(l.Ay,{}),"\n",(0,i.jsxs)(n,{children:[(0,i.jsx)("summary",{children:"Ansible Playbook"}),(0,i.jsxs)(c.A,{title:"Set up package repository and install zrok-share",children:[d.A,"\n- name: Install zrok-share package\ngather_facts: false\nhosts: all \nbecome: true\ntasks:\n- name: Install zrok-share\n ansible.builtin.package:\n name: zrok-share\n state: present\n\n- name: Copy env config from Ansible controller to target\n copy:\n dest: /opt/openziti/etc/zrok/zrok-share.env\n src: /opt/openziti/etc/zrok/zrok-share.env\n\n- name: Enable and restart service\n systemd:\n name: zrok-share\n enabled: yes\n state: restarted\n daemon_reload: yes\n\n- name: Wait for service\n systemd:\n name: zrok-share\n state: started\n register: service_status\n until: service_status.status.ActiveState == 'active'\n retries: 30\n delay: 1\n"]})]}),"\n",(0,i.jsx)(r.h2,{id:"enable",children:"Enable"}),"\n",(0,i.jsx)(r.p,{children:"Save the enable token from the zrok console in the configuration file."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_ENABLE_TOKEN="14cbfca9772f"\n'})}),"\n",(0,i.jsx)(r.h2,{id:"name-your-share",children:"Name your Share"}),"\n",(0,i.jsxs)(r.p,{children:["This unique name becomes part of the domain name of the share, e.g. ",(0,i.jsx)(r.code,{children:"https://my-prod-app.in.zrok.io"}),". A random name is generated if you don't specify one."]}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_UNIQUE_NAME="my-prod-app"\n'})}),"\n",(0,i.jsx)(r.h2,{id:"use-cases",children:"Use Cases"}),"\n",(0,i.jsxs)(r.p,{children:["You may change the target for the current backend mode, e.g. ",(0,i.jsx)(r.code,{children:"proxy"}),", by editing the configuration file and restarting the service. The reserved subdomain will remain the same."]}),"\n",(0,i.jsxs)(r.p,{children:["You may switch between backend modes or change authentication options by deleting ",(0,i.jsx)(r.code,{children:"/var/lib/zrok-share/.zrok/reserved.json"})," and restarting the service. A new subdomain will be reserved."]}),"\n",(0,i.jsx)(r.h3,{id:"proxy-a-web-server",children:"Proxy a Web Server"}),"\n",(0,i.jsx)(r.p,{children:"Proxy a reserved subdomain to an existing web server. The web server could be on a private network or on the same host as zrok."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_TARGET="http://127.0.0.1:3000"\nZROK_BACKEND_MODE="proxy"\n'})}),"\n",(0,i.jsxs)(r.p,{children:["If your HTTPS server has an unverifiable TLS server certificate then you must set ",(0,i.jsx)(r.code,{children:"--insecure"}),"."]}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_INSECURE="--insecure"\n'})}),"\n",(0,i.jsx)(r.h3,{id:"serve-static-files",children:"Serve Static Files"}),"\n",(0,i.jsxs)(r.p,{children:["Run zrok's embedded web server to serve the files in a directory. If there's an ",(0,i.jsx)(r.code,{children:"index.html"})," file in the directory then visitors will see that web page in their browser, otherwise they'll see a generated index of the files. The directory must be readable by 'other', e.g. ",(0,i.jsx)(r.code,{children:"chmod -R o+rX /var/www/html"}),"."]}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_TARGET="/var/www/html"\nZROK_BACKEND_MODE="web"\n'})}),"\n",(0,i.jsx)(r.h3,{id:"caddy-server",children:"Caddy Server"}),"\n",(0,i.jsx)(r.p,{children:"Use zrok's built-in Caddy server to serve static files or as a reverse proxy to multiple web servers with various HTTP routes or as a load-balanced set. A sample Caddyfile is available in the path shown."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_TARGET="/opt/openziti/etc/zrok/multiple_upstream.Caddyfile"\nZROK_BACKEND_MODE="caddy"\n'})}),"\n",(0,i.jsx)(r.h3,{id:"network-drive",children:"Network Drive"}),"\n",(0,i.jsxs)(r.p,{children:["This uses zrok's ",(0,i.jsx)(r.code,{children:"drive"})," backend mode to serve a directory of static files as a virtual network drive. The directory must be readable by 'other', e.g. ",(0,i.jsx)(r.code,{children:"chmod -R o+rX /usr/share/doc"}),"."]}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_TARGET="/usr/share/doc"\nZROK_BACKEND_MODE="drive"\n'})}),"\n",(0,i.jsxs)(r.p,{children:[(0,i.jsx)(r.a,{href:"https://blog.openziti.io/zrok-drives-an-early-preview",children:"Learn more about this feature in this blog post"}),"."]}),"\n",(0,i.jsx)(r.h2,{id:"authentication",children:"Authentication"}),"\n",(0,i.jsx)(r.p,{children:"You can limit access to certain email addresses with OAuth or require a password."}),"\n",(0,i.jsx)(r.h3,{id:"oauth",children:"OAuth"}),"\n",(0,i.jsx)(r.p,{children:"You can require that visitors authenticate with an email address that matches at least one of the suffixes you specify. Add the following to the configuration file."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_OAUTH_PROVIDER="github" # or google\nZROK_OAUTH_EMAILS="alice@example.com *@acme.example.com"\n'})}),"\n",(0,i.jsx)(r.h3,{id:"password",children:"Password"}),"\n",(0,i.jsx)(r.p,{children:"Enable HTTP basic authentication by adding the following to the configuration file."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="/opt/openziti/etc/zrok/zrok-share.env"',children:'ZROK_BASIC_AUTH="user:passwd"\n'})}),"\n",(0,i.jsx)(r.h2,{id:"start-the-service",children:"Start the Service"}),"\n",(0,i.jsx)(r.p,{children:"Start the service, and check the zrok console or the service log for the reserved subdomain."}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="run now and at startup"',children:"sudo systemctl enable --now zrok-share.service\n"})}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",metastring:'title="run now"',children:"sudo systemctl restart zrok-share.service\n"})}),"\n",(0,i.jsx)(r.pre,{children:(0,i.jsx)(r.code,{className:"language-bash",children:"journalctl -u zrok-share.service\n"})}),"\n",(0,i.jsx)(r.h2,{id:"compatibility",children:"Compatibility"}),"\n",(0,i.jsxs)(r.p,{children:["The Linux distribution must have a package manager that understands the ",(0,i.jsx)(r.code,{children:".deb"})," or ",(0,i.jsx)(r.code,{children:".rpm"})," format and be running systemd v232 or newer. The service was tested with:"]}),"\n",(0,i.jsxs)(r.ul,{children:["\n",(0,i.jsx)(r.li,{children:"Ubuntu 20.04, 22.04, 23.04"}),"\n",(0,i.jsx)(r.li,{children:"Debian 11 12"}),"\n",(0,i.jsx)(r.li,{children:"Rocky 8, 9"}),"\n",(0,i.jsx)(r.li,{children:"Fedora 37, 38"}),"\n"]}),"\n",(0,i.jsx)(r.h2,{id:"package-contents",children:"Package Contents"}),"\n",(0,i.jsxs)(r.p,{children:["The files included in the ",(0,i.jsx)(r.code,{children:"zrok-share"})," package are sourced ",(0,i.jsx)(r.a,{href:"https://github.com/openziti/zrok/tree/main/nfpm",children:"here in GitHub"}),"."]})]})}function u(e={}){const{wrapper:r}={...(0,t.R)(),...e.components};return r?(0,i.jsx)(r,{...e,children:(0,i.jsx)(p,{...e})}):p(e)}var m=n(1122),g=n(6025);const b={title:"zrok frontdoor",sidebar_label:"frontdoor",sidebar_position:20,hide_table_of_contents:!0},x=void 0,v={},k=[{value:"Overview",id:"overview",level:2},{value:"Choose your OS",id:"choose-your-os",level:2},{value:"Goal",id:"goal",level:2},{value:"How it Works",id:"how-it-works",level:2},...h,{value:"Concepts",id:"concepts",level:2}];function j(e){const r={a:"a",code:"code",h2:"h2",li:"li",ol:"ol",p:"p",strong:"strong",...(0,t.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(r.p,{children:[(0,i.jsx)(r.strong,{children:"zrok frontdoor"})," is the heavy-duty front door to your app or site. It makes your website or app available to your online audience through the shield of zrok.io's hardened, managed frontends."]}),"\n",(0,i.jsx)("iframe",{width:"100%",height:"315",src:"https://www.youtube.com/embed/5Vi8GKuTi_I",title:"YouTube video player",frameborder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share",allowfullscreen:!0}),"\n",(0,i.jsx)(r.h2,{id:"overview",children:"Overview"}),"\n",(0,i.jsxs)(r.p,{children:["zrok frontends are the parts of zrok that proxy incoming public web traffic to zrok backend shares via OpenZiti. When you use zrok with a ",(0,i.jsx)(r.code,{children:"zrok.io"})," frontend, you're using ",(0,i.jsx)(r.strong,{children:"zrok frontdoor"}),". ",(0,i.jsx)(r.code,{children:"zrok.io"})," is zrok-as-a-service by NetFoundry, the team behind OpenZiti. You need a free account to use ",(0,i.jsx)(r.strong,{children:"zrok frontdoor"}),"."]}),"\n",(0,i.jsx)(m.A,{alt:"frontdoor diagram",sources:{light:(0,g.Ay)("/img/zrok-frontdoor-light-mode.svg"),dark:(0,g.Ay)("/img/zrok-frontdoor-dark-mode.svg")}}),"\n",(0,i.jsx)(r.h2,{id:"choose-your-os",children:"Choose your OS"}),"\n",(0,i.jsx)(r.p,{children:"Choose between installing the Linux package or running zrok with Docker (Linux, macOS, or Windows)."}),"\n","\n",(0,i.jsxs)(o.A,{queryString:"os",values:[{label:"Linux",value:"Linux"},{label:"Docker",value:"Docker"}],children:[(0,i.jsxs)(a.A,{value:"Linux",children:[(0,i.jsxs)(r.p,{children:["On Linux, zrok frontdoor is implemented natively as a system service provided by the ",(0,i.jsx)(r.code,{children:"zrok-share"})," DEB or RPM package."]}),(0,i.jsx)(r.h2,{id:"goal",children:"Goal"}),(0,i.jsx)(r.p,{children:"Proxy a reserved public subdomain to a backend target with an always-on Linux system service."}),(0,i.jsx)(r.h2,{id:"how-it-works",children:"How it Works"}),(0,i.jsxs)(r.p,{children:["The ",(0,i.jsx)(r.code,{children:"zrok-share"})," package creates a ",(0,i.jsx)(r.code,{children:"zrok-share.service"})," unit in systemd. The administrator edits the service's configuration file to specify the:"]}),(0,i.jsxs)(r.ol,{children:["\n",(0,i.jsx)(r.li,{children:"zrok account token"}),"\n",(0,i.jsxs)(r.li,{children:["target URL or files to be shared and backend mode, e.g. ",(0,i.jsx)(r.code,{children:"proxy"})]}),"\n",(0,i.jsx)(r.li,{children:"authentication options, if wanted"}),"\n"]}),(0,i.jsx)(r.p,{children:"When the service starts it will:"}),(0,i.jsxs)(r.ol,{children:["\n",(0,i.jsxs)(r.li,{children:["enable the zrok environment unless ",(0,i.jsx)(r.code,{children:"/var/lib/zrok-share/.zrok/environment.json"})," exists"]}),"\n",(0,i.jsxs)(r.li,{children:["reserve a public subdomain for the service unless ",(0,i.jsx)(r.code,{children:"/var/lib/zrok-share/.zrok/reserved.json"})," exists"]}),"\n",(0,i.jsxs)(r.li,{children:["start sharing the target specified as ",(0,i.jsx)(r.code,{children:"ZROK_TARGET"})," in the environment file"]}),"\n"]}),(0,i.jsx)(u,{})]}),(0,i.jsx)(a.A,{value:"Docker",children:(0,i.jsxs)(r.p,{children:["On macOS and Windows, zrok frontdoor is implemented as a Docker Compose project which reserves a public subdomain for your website or service and manages a zrok environment that's separate from the Docker host. ",(0,i.jsx)(r.a,{href:"/docs/guides/docker-share/docker_public_share_guide",children:"Link to the Docker Public Share Guide"})]})})]}),"\n",(0,i.jsx)(r.h2,{id:"concepts",children:"Concepts"}),"\n",(0,i.jsxs)(r.p,{children:["Overview of ",(0,i.jsx)(r.a,{href:"/docs/concepts/sharing-reserved",children:"zrok reserved shares"})]})]})}function y(e={}){const{wrapper:r}={...(0,t.R)(),...e.components};return r?(0,i.jsx)(r,{...e,children:(0,i.jsx)(j,{...e})}):j(e)}},3902:(e,r,n)=>{n.d(r,{A:()=>o});n(6540);var s=n(382),i=n(1432),t=n(4848);const o=e=>{let{title:r,children:n}=e;const o=n.map((e=>"string"==typeof e?e.trim():s.Ay.dump(e).trim())).join("\n\n");return(0,t.jsx)("div",{children:(0,t.jsx)(i.A,{language:"yaml",title:r,children:o})})}},9028:(e,r,n)=>{n.d(r,{A:()=>a});var s=n(6540),i=n(1470),t=n(159),o=n(4848);const a=function(e){const[r,n]=(0,s.useState)(null);return(0,s.useEffect)((()=>{["Mac OS","Windows"].includes(t.wH)?n("Docker"):n("Linux")}),[]),(0,o.jsx)(o.Fragment,{children:(0,o.jsx)(i.A,{...e,defaultValue:r,children:e.children})})}},397:(e,r,n)=>{n.d(r,{A:()=>s});const s=[{name:"Set up zrok Package Repo",gather_facts:!0,hosts:"all",become:!0,tasks:[{name:"Set up apt repo",when:'ansible_os_family == "Debian"',block:[{name:"Install playbook dependencies","ansible.builtin.package":{name:["gnupg"],state:"present"}},{name:"Fetch armored pubkey","ansible.builtin.uri":{url:"https://get.openziti.io/tun/package-repos.gpg",return_content:"yes"},register:"armored_pubkey"},{name:"Dearmor pubkey","ansible.builtin.shell":'gpg --dearmor --output /usr/share/keyrings/openziti.gpg <<< "{{ armored_pubkey.content }}"\n',args:{creates:"/usr/share/keyrings/openziti.gpg",executable:"/bin/bash"}},{name:"Set pubkey filemode","ansible.builtin.file":{path:"/usr/share/keyrings/openziti.gpg",mode:"a+rX"}},{name:"Install OpenZiti repo deb source","ansible.builtin.copy":{dest:"/etc/apt/sources.list.d/openziti-release.list",content:"deb [signed-by=/usr/share/keyrings/openziti.gpg] https://packages.openziti.org/zitipax-openziti-deb-stable debian main\n"}},{name:"Refresh Repo Sources","ansible.builtin.apt":{update_cache:"yes",cache_valid_time:3600}}]},{name:"Set up yum repo",when:'ansible_os_family == "RedHat"',block:[{name:"Install OpenZiti repo rpm source","ansible.builtin.yum_repository":{name:"OpenZitiRelease",description:"OpenZiti Release",baseurl:"https://packages.openziti.org/zitipax-openziti-rpm-stable/redhat/$basearch",enabled:"yes",gpgkey:"https://packages.openziti.org/zitipax-openziti-rpm-stable/redhat/$basearch/repodata/repomd.xml.key",repo_gpgcheck:"yes",gpgcheck:"no"}}]}]}]}}]); \ No newline at end of file diff --git a/assets/js/runtime~main.1b33b3df.js b/assets/js/runtime~main.3f6596aa.js similarity index 62% rename from assets/js/runtime~main.1b33b3df.js rename to assets/js/runtime~main.3f6596aa.js index fd75b379..ae2397c0 100644 --- a/assets/js/runtime~main.1b33b3df.js +++ b/assets/js/runtime~main.3f6596aa.js @@ -1 +1 @@ -(()=>{"use strict";var e,a,c,d,f,b={},t={};function r(e){var a=t[e];if(void 0!==a)return a.exports;var c=t[e]={id:e,loaded:!1,exports:{}};return b[e].call(c.exports,c,c.exports,r),c.loaded=!0,c.exports}r.m=b,r.c=t,r.amdO={},e=[],r.O=(a,c,d,f)=>{if(!c){var b=1/0;for(i=0;i=f)&&Object.keys(r.O).every((e=>r.O[e](c[o])))?c.splice(o--,1):(t=!1,f0&&e[i-1][2]>f;i--)e[i]=e[i-1];e[i]=[c,d,f]},r.n=e=>{var a=e&&e.__esModule?()=>e.default:()=>e;return r.d(a,{a:a}),a},c=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,r.t=function(e,d){if(1&d&&(e=this(e)),8&d)return e;if("object"==typeof e&&e){if(4&d&&e.__esModule)return e;if(16&d&&"function"==typeof e.then)return e}var f=Object.create(null);r.r(f);var b={};a=a||[null,c({}),c([]),c(c)];for(var t=2&d&&e;"object"==typeof t&&!~a.indexOf(t);t=c(t))Object.getOwnPropertyNames(t).forEach((a=>b[a]=()=>e[a]));return b.default=()=>e,r.d(f,b),f},r.d=(e,a)=>{for(var c in a)r.o(a,c)&&!r.o(e,c)&&Object.defineProperty(e,c,{enumerable:!0,get:a[c]})},r.f={},r.e=e=>Promise.all(Object.keys(r.f).reduce(((a,c)=>(r.f[c](e,a),a)),[])),r.u=e=>"assets/js/"+({37:"ebc0e2a0",277:"4f1777fd",351:"3fab0acb",429:"50ef9c44",471:"7dd0c8d0",598:"9939c4f4",627:"d087459a",714:"b6569025",749:"21880a4d",826:"bc32cbb6",887:"c015c796",957:"c141421f",1057:"bbbe662c",1235:"a7456010",1346:"d3a54718",1595:"1ddd36f2",1769:"aad6478e",1831:"80941509",1864:"8a9ffb5d",1939:"7f5ec875",2138:"1a4e3797",2256:"11b43341",2634:"c4f5d8e4",2757:"cda0d2e5",2759:"1ba5bc99",2867:"6a6a5bbc",3165:"c88279fc",3373:"6e881e32",3423:"e1dfe4fe",3434:"bfe99541",3574:"4cb7be2f",3588:"288b1075",3747:"01cb08ea",3786:"c304be44",3921:"36b94792",3929:"8a10c423",3979:"2c440c24",4074:"5cd0a723",4247:"d768dc0f",4277:"27b0284c",4466:"7d0a541a",4470:"f888b719",4504:"b36bb0c9",4717:"392083ed",4909:"bc747cac",4927:"47881d5c",5117:"8dbf8f84",5689:"685bed1a",5695:"f8f494be",5742:"aba21aa0",5955:"8b4ddd1a",6063:"6ad1709d",6289:"ce04f2ae",6332:"2da89d45",6381:"1f91e8db",6475:"033e8fc8",6595:"0c1cdb3d",6878:"1dd31738",6946:"2cc2e835",6969:"14eb3368",6974:"bf372175",7098:"a7bd4aaa",7216:"0c66edb9",7242:"6272ba0e",7499:"07d0b302",7599:"f7af5a99",7752:"339d500a",8051:"adf8dca1",8173:"0efac3c3",8240:"28f20845",8301:"81fb89b8",8401:"17896441",8436:"4277b6a0",8471:"2e812224",8582:"20595907",8675:"54fa7005",8746:"25ef1bb8",8875:"17f4c24e",9002:"ecf841c3",9025:"75b20590",9033:"901ef07d",9048:"a94703ab",9148:"35a60099",9253:"e2c4d679",9355:"600b2345",9471:"48341697",9476:"7452427d",9576:"61ea36d9",9631:"9af26a4e",9647:"5e95c892",9851:"e3e0bfdc",9905:"ef8afbfd"}[e]||e)+"."+{37:"5671cf6f",277:"7a01d5ed",351:"d2be5705",382:"a8e40f63",416:"36a683d5",429:"7c0dd56b",471:"b0b509b1",598:"0a8ed6f3",627:"5b953d23",714:"6245889e",749:"2545a6d9",826:"ac399eaf",887:"32854b4b",957:"94fe8bc5",962:"3828f828",1057:"0376698e",1235:"7b4b0a20",1346:"adbe71c6",1595:"031ba1fd",1769:"8dd329a2",1831:"76c5af9c",1864:"77502c26",1939:"bb718edf",2138:"b404fedf",2237:"1d1b868c",2256:"99cef784",2634:"ff3bb442",2757:"e386cd05",2759:"1ceac7e5",2867:"7ff8dd0a",3165:"70a81d0d",3373:"58f05075",3423:"d8120f8e",3434:"bd20f5d0",3574:"a83087ce",3588:"7fdf1033",3747:"90a8ab9b",3786:"6d7fbd06",3921:"799856c4",3929:"bf9ed799",3979:"89c5dd72",4074:"ff1769bd",4247:"7eb1170c",4277:"24ca90bb",4466:"bebc18c0",4470:"6fe13079",4504:"32b884d9",4717:"30911eae",4909:"7ee6980c",4927:"beaba6e5",5117:"b796122d",5394:"216a6dc4",5689:"cba82c70",5695:"f6c4378a",5742:"9ac6642b",5955:"c9cbe2e9",6063:"68cc20aa",6289:"4cc27842",6332:"2c84f779",6381:"2ff8779a",6475:"550a98dd",6595:"93ac86f2",6878:"b424452b",6946:"42c85917",6969:"a2fb3a9b",6974:"6ce3604a",7098:"6c642da0",7216:"a1604a49",7242:"80d989e8",7499:"de243ccc",7599:"8573f403",7752:"749f941d",8051:"b0b219c1",8158:"900dc11d",8173:"3f261e03",8240:"b3a7ec46",8301:"8e503f5a",8401:"1409512a",8436:"4bd27697",8471:"77794a5c",8582:"3e569479",8585:"e93703b4",8675:"cf645e57",8746:"5af8d370",8875:"17d254d5",8913:"83bce4ad",9002:"7d4c9847",9025:"c44edc33",9033:"08f99ecd",9048:"43814358",9148:"7bc9aad5",9253:"dd14fdd8",9355:"18130102",9471:"f4018882",9476:"951c0809",9576:"f59265a3",9631:"b4a6cf60",9647:"6794ea18",9851:"c7a4408d",9905:"dbcbe2ba"}[e]+".js",r.miniCssF=e=>{},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,a)=>Object.prototype.hasOwnProperty.call(e,a),d={},f="website:",r.l=(e,a,c,b)=>{if(d[e])d[e].push(a);else{var t,o;if(void 0!==c)for(var n=document.getElementsByTagName("script"),i=0;i{t.onerror=t.onload=null,clearTimeout(s);var f=d[e];if(delete d[e],t.parentNode&&t.parentNode.removeChild(t),f&&f.forEach((e=>e(c))),a)return a(c)},s=setTimeout(l.bind(null,void 0,{type:"timeout",target:t}),12e4);t.onerror=l.bind(null,t.onerror),t.onload=l.bind(null,t.onload),o&&document.head.appendChild(t)}},r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.p="/",r.gca=function(e){return e={17896441:"8401",20595907:"8582",48341697:"9471",80941509:"1831",ebc0e2a0:"37","4f1777fd":"277","3fab0acb":"351","50ef9c44":"429","7dd0c8d0":"471","9939c4f4":"598",d087459a:"627",b6569025:"714","21880a4d":"749",bc32cbb6:"826",c015c796:"887",c141421f:"957",bbbe662c:"1057",a7456010:"1235",d3a54718:"1346","1ddd36f2":"1595",aad6478e:"1769","8a9ffb5d":"1864","7f5ec875":"1939","1a4e3797":"2138","11b43341":"2256",c4f5d8e4:"2634",cda0d2e5:"2757","1ba5bc99":"2759","6a6a5bbc":"2867",c88279fc:"3165","6e881e32":"3373",e1dfe4fe:"3423",bfe99541:"3434","4cb7be2f":"3574","288b1075":"3588","01cb08ea":"3747",c304be44:"3786","36b94792":"3921","8a10c423":"3929","2c440c24":"3979","5cd0a723":"4074",d768dc0f:"4247","27b0284c":"4277","7d0a541a":"4466",f888b719:"4470",b36bb0c9:"4504","392083ed":"4717",bc747cac:"4909","47881d5c":"4927","8dbf8f84":"5117","685bed1a":"5689",f8f494be:"5695",aba21aa0:"5742","8b4ddd1a":"5955","6ad1709d":"6063",ce04f2ae:"6289","2da89d45":"6332","1f91e8db":"6381","033e8fc8":"6475","0c1cdb3d":"6595","1dd31738":"6878","2cc2e835":"6946","14eb3368":"6969",bf372175:"6974",a7bd4aaa:"7098","0c66edb9":"7216","6272ba0e":"7242","07d0b302":"7499",f7af5a99:"7599","339d500a":"7752",adf8dca1:"8051","0efac3c3":"8173","28f20845":"8240","81fb89b8":"8301","4277b6a0":"8436","2e812224":"8471","54fa7005":"8675","25ef1bb8":"8746","17f4c24e":"8875",ecf841c3:"9002","75b20590":"9025","901ef07d":"9033",a94703ab:"9048","35a60099":"9148",e2c4d679:"9253","600b2345":"9355","7452427d":"9476","61ea36d9":"9576","9af26a4e":"9631","5e95c892":"9647",e3e0bfdc:"9851",ef8afbfd:"9905"}[e]||e,r.p+r.u(e)},(()=>{var e={5354:0,1869:0};r.f.j=(a,c)=>{var d=r.o(e,a)?e[a]:void 0;if(0!==d)if(d)c.push(d[2]);else if(/^(1869|5354)$/.test(a))e[a]=0;else{var f=new Promise(((c,f)=>d=e[a]=[c,f]));c.push(d[2]=f);var b=r.p+r.u(a),t=new Error;r.l(b,(c=>{if(r.o(e,a)&&(0!==(d=e[a])&&(e[a]=void 0),d)){var f=c&&("load"===c.type?"missing":c.type),b=c&&c.target&&c.target.src;t.message="Loading chunk "+a+" failed.\n("+f+": "+b+")",t.name="ChunkLoadError",t.type=f,t.request=b,d[1](t)}}),"chunk-"+a,a)}},r.O.j=a=>0===e[a];var a=(a,c)=>{var d,f,b=c[0],t=c[1],o=c[2],n=0;if(b.some((a=>0!==e[a]))){for(d in t)r.o(t,d)&&(r.m[d]=t[d]);if(o)var i=o(r)}for(a&&a(c);n{"use strict";var e,a,d,c,b,f={},t={};function r(e){var a=t[e];if(void 0!==a)return a.exports;var d=t[e]={id:e,loaded:!1,exports:{}};return f[e].call(d.exports,d,d.exports,r),d.loaded=!0,d.exports}r.m=f,r.c=t,r.amdO={},e=[],r.O=(a,d,c,b)=>{if(!d){var f=1/0;for(i=0;i=b)&&Object.keys(r.O).every((e=>r.O[e](d[o])))?d.splice(o--,1):(t=!1,b0&&e[i-1][2]>b;i--)e[i]=e[i-1];e[i]=[d,c,b]},r.n=e=>{var a=e&&e.__esModule?()=>e.default:()=>e;return r.d(a,{a:a}),a},d=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,r.t=function(e,c){if(1&c&&(e=this(e)),8&c)return e;if("object"==typeof e&&e){if(4&c&&e.__esModule)return e;if(16&c&&"function"==typeof e.then)return e}var b=Object.create(null);r.r(b);var f={};a=a||[null,d({}),d([]),d(d)];for(var t=2&c&&e;"object"==typeof t&&!~a.indexOf(t);t=d(t))Object.getOwnPropertyNames(t).forEach((a=>f[a]=()=>e[a]));return f.default=()=>e,r.d(b,f),b},r.d=(e,a)=>{for(var d in a)r.o(a,d)&&!r.o(e,d)&&Object.defineProperty(e,d,{enumerable:!0,get:a[d]})},r.f={},r.e=e=>Promise.all(Object.keys(r.f).reduce(((a,d)=>(r.f[d](e,a),a)),[])),r.u=e=>"assets/js/"+({37:"ebc0e2a0",277:"4f1777fd",351:"3fab0acb",429:"50ef9c44",471:"7dd0c8d0",598:"9939c4f4",627:"d087459a",714:"b6569025",749:"21880a4d",826:"bc32cbb6",887:"c015c796",957:"c141421f",1057:"bbbe662c",1235:"a7456010",1346:"d3a54718",1595:"1ddd36f2",1769:"aad6478e",1831:"80941509",1864:"8a9ffb5d",1939:"7f5ec875",2138:"1a4e3797",2256:"11b43341",2634:"c4f5d8e4",2757:"cda0d2e5",2759:"1ba5bc99",2867:"6a6a5bbc",3165:"c88279fc",3373:"6e881e32",3423:"e1dfe4fe",3434:"bfe99541",3574:"4cb7be2f",3588:"288b1075",3747:"01cb08ea",3786:"c304be44",3921:"36b94792",3929:"8a10c423",3979:"2c440c24",4074:"5cd0a723",4247:"d768dc0f",4277:"27b0284c",4466:"7d0a541a",4470:"f888b719",4504:"b36bb0c9",4717:"392083ed",4909:"bc747cac",4927:"47881d5c",5117:"8dbf8f84",5689:"685bed1a",5695:"f8f494be",5742:"aba21aa0",5955:"8b4ddd1a",6063:"6ad1709d",6289:"ce04f2ae",6332:"2da89d45",6381:"1f91e8db",6475:"033e8fc8",6595:"0c1cdb3d",6878:"1dd31738",6946:"2cc2e835",6969:"14eb3368",6974:"bf372175",7098:"a7bd4aaa",7216:"0c66edb9",7242:"6272ba0e",7499:"07d0b302",7599:"f7af5a99",7752:"339d500a",8051:"adf8dca1",8173:"0efac3c3",8240:"28f20845",8301:"81fb89b8",8401:"17896441",8436:"4277b6a0",8471:"2e812224",8582:"20595907",8675:"54fa7005",8746:"25ef1bb8",8875:"17f4c24e",9002:"ecf841c3",9025:"75b20590",9033:"901ef07d",9048:"a94703ab",9148:"35a60099",9253:"e2c4d679",9355:"600b2345",9471:"48341697",9476:"7452427d",9576:"61ea36d9",9631:"9af26a4e",9647:"5e95c892",9851:"e3e0bfdc",9905:"ef8afbfd"}[e]||e)+"."+{37:"5671cf6f",277:"7a01d5ed",351:"d2be5705",382:"a8e40f63",416:"36a683d5",429:"7c0dd56b",471:"b0b509b1",598:"0a8ed6f3",627:"5b953d23",714:"6245889e",749:"2545a6d9",826:"ac399eaf",887:"32854b4b",957:"94fe8bc5",962:"3828f828",1057:"0376698e",1235:"7b4b0a20",1346:"adbe71c6",1595:"031ba1fd",1769:"8dd329a2",1831:"76c5af9c",1864:"77502c26",1939:"bb718edf",2138:"b404fedf",2237:"1d1b868c",2256:"99cef784",2634:"ff3bb442",2757:"19e28221",2759:"1ceac7e5",2867:"7ff8dd0a",3165:"70a81d0d",3373:"58f05075",3423:"d8120f8e",3434:"bd20f5d0",3574:"a83087ce",3588:"7fdf1033",3747:"58ce9e89",3786:"6d7fbd06",3921:"799856c4",3929:"bf9ed799",3979:"89c5dd72",4074:"ff1769bd",4247:"7eb1170c",4277:"24ca90bb",4466:"bebc18c0",4470:"6fe13079",4504:"32b884d9",4717:"30911eae",4909:"7ee6980c",4927:"beaba6e5",5117:"b796122d",5394:"216a6dc4",5689:"cba82c70",5695:"f6c4378a",5742:"9ac6642b",5955:"c9cbe2e9",6063:"68cc20aa",6289:"4cc27842",6332:"c53388d7",6381:"2ff8779a",6475:"550a98dd",6595:"93ac86f2",6878:"b424452b",6946:"42c85917",6969:"a2fb3a9b",6974:"6ce3604a",7098:"6c642da0",7216:"a1604a49",7242:"e147ca1e",7499:"de243ccc",7599:"8573f403",7752:"749f941d",8051:"b0b219c1",8158:"900dc11d",8173:"3f261e03",8240:"b3a7ec46",8301:"8e503f5a",8401:"1409512a",8436:"4bd27697",8471:"6dc7f702",8582:"3e569479",8585:"e93703b4",8675:"cf645e57",8746:"5af8d370",8875:"17d254d5",8913:"83bce4ad",9002:"7d4c9847",9025:"c44edc33",9033:"08f99ecd",9048:"43814358",9148:"7bc9aad5",9253:"dd14fdd8",9355:"18130102",9471:"f4018882",9476:"951c0809",9576:"f59265a3",9631:"b4a6cf60",9647:"6794ea18",9851:"c7a4408d",9905:"dbcbe2ba"}[e]+".js",r.miniCssF=e=>{},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,a)=>Object.prototype.hasOwnProperty.call(e,a),c={},b="website:",r.l=(e,a,d,f)=>{if(c[e])c[e].push(a);else{var t,o;if(void 0!==d)for(var n=document.getElementsByTagName("script"),i=0;i{t.onerror=t.onload=null,clearTimeout(s);var b=c[e];if(delete c[e],t.parentNode&&t.parentNode.removeChild(t),b&&b.forEach((e=>e(d))),a)return a(d)},s=setTimeout(l.bind(null,void 0,{type:"timeout",target:t}),12e4);t.onerror=l.bind(null,t.onerror),t.onload=l.bind(null,t.onload),o&&document.head.appendChild(t)}},r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.p="/",r.gca=function(e){return e={17896441:"8401",20595907:"8582",48341697:"9471",80941509:"1831",ebc0e2a0:"37","4f1777fd":"277","3fab0acb":"351","50ef9c44":"429","7dd0c8d0":"471","9939c4f4":"598",d087459a:"627",b6569025:"714","21880a4d":"749",bc32cbb6:"826",c015c796:"887",c141421f:"957",bbbe662c:"1057",a7456010:"1235",d3a54718:"1346","1ddd36f2":"1595",aad6478e:"1769","8a9ffb5d":"1864","7f5ec875":"1939","1a4e3797":"2138","11b43341":"2256",c4f5d8e4:"2634",cda0d2e5:"2757","1ba5bc99":"2759","6a6a5bbc":"2867",c88279fc:"3165","6e881e32":"3373",e1dfe4fe:"3423",bfe99541:"3434","4cb7be2f":"3574","288b1075":"3588","01cb08ea":"3747",c304be44:"3786","36b94792":"3921","8a10c423":"3929","2c440c24":"3979","5cd0a723":"4074",d768dc0f:"4247","27b0284c":"4277","7d0a541a":"4466",f888b719:"4470",b36bb0c9:"4504","392083ed":"4717",bc747cac:"4909","47881d5c":"4927","8dbf8f84":"5117","685bed1a":"5689",f8f494be:"5695",aba21aa0:"5742","8b4ddd1a":"5955","6ad1709d":"6063",ce04f2ae:"6289","2da89d45":"6332","1f91e8db":"6381","033e8fc8":"6475","0c1cdb3d":"6595","1dd31738":"6878","2cc2e835":"6946","14eb3368":"6969",bf372175:"6974",a7bd4aaa:"7098","0c66edb9":"7216","6272ba0e":"7242","07d0b302":"7499",f7af5a99:"7599","339d500a":"7752",adf8dca1:"8051","0efac3c3":"8173","28f20845":"8240","81fb89b8":"8301","4277b6a0":"8436","2e812224":"8471","54fa7005":"8675","25ef1bb8":"8746","17f4c24e":"8875",ecf841c3:"9002","75b20590":"9025","901ef07d":"9033",a94703ab:"9048","35a60099":"9148",e2c4d679:"9253","600b2345":"9355","7452427d":"9476","61ea36d9":"9576","9af26a4e":"9631","5e95c892":"9647",e3e0bfdc:"9851",ef8afbfd:"9905"}[e]||e,r.p+r.u(e)},(()=>{var e={5354:0,1869:0};r.f.j=(a,d)=>{var c=r.o(e,a)?e[a]:void 0;if(0!==c)if(c)d.push(c[2]);else if(/^(1869|5354)$/.test(a))e[a]=0;else{var b=new Promise(((d,b)=>c=e[a]=[d,b]));d.push(c[2]=b);var f=r.p+r.u(a),t=new Error;r.l(f,(d=>{if(r.o(e,a)&&(0!==(c=e[a])&&(e[a]=void 0),c)){var b=d&&("load"===d.type?"missing":d.type),f=d&&d.target&&d.target.src;t.message="Loading chunk "+a+" failed.\n("+b+": "+f+")",t.name="ChunkLoadError",t.type=b,t.request=f,c[1](t)}}),"chunk-"+a,a)}},r.O.j=a=>0===e[a];var a=(a,d)=>{var c,b,f=d[0],t=d[1],o=d[2],n=0;if(f.some((a=>0!==e[a]))){for(c in t)r.o(t,c)&&(r.m[c]=t[c]);if(o)var i=o(r)}for(a&&a(d);n