zrok/assets/js/a88ab1d1.e8fd5137.js

1 line
4.7 KiB
JavaScript
Raw Normal View History

"use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[731],{3905:(e,r,t)=>{t.d(r,{Zo:()=>p,kt:()=>m});var n=t(7294);function a(e,r,t){return r in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}function i(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);r&&(n=n.filter((function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable}))),t.push.apply(t,n)}return t}function o(e){for(var r=1;r<arguments.length;r++){var t=null!=arguments[r]?arguments[r]:{};r%2?i(Object(t),!0).forEach((function(r){a(e,r,t[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):i(Object(t)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(t,r))}))}return e}function s(e,r){if(null==e)return{};var t,n,a=function(e,r){if(null==e)return{};var t,n,a={},i=Object.keys(e);for(n=0;n<i.length;n++)t=i[n],r.indexOf(t)>=0||(a[t]=e[t]);return a}(e,r);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n<i.length;n++)t=i[n],r.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(a[t]=e[t])}return a}var l=n.createContext({}),c=function(e){var r=n.useContext(l),t=r;return e&&(t="function"==typeof e?e(r):o(o({},r),e)),t},p=function(e){var r=c(e.components);return n.createElement(l.Provider,{value:r},e.children)},u="mdxType",f={inlineCode:"code",wrapper:function(e){var r=e.children;return n.createElement(n.Fragment,{},r)}},d=n.forwardRef((function(e,r){var t=e.components,a=e.mdxType,i=e.originalType,l=e.parentName,p=s(e,["components","mdxType","originalType","parentName"]),u=c(t),d=a,m=u["".concat(l,".").concat(d)]||u[d]||f[d]||i;return t?n.createElement(m,o(o({ref:r},p),{},{components:t})):n.createElement(m,o({ref:r},p))}));function m(e,r){var t=arguments,a=r&&r.mdxType;if("string"==typeof e||a){var i=t.length,o=new Array(i);o[0]=d;var s={};for(var l in r)hasOwnProperty.call(r,l)&&(s[l]=r[l]);s.originalType=e,s[u]="string"==typeof e?e:a,o[1]=s;for(var c=2;c<i;c++)o[c]=t[c];return n.createElement.apply(null,o)}return n.createElement.apply(null,t)}d.displayName="MDXCreateElement"},2419:(e,r,t)=>{t.r(r),t.d(r,{assets:()=>l,contentTitle:()=>o,default:()=>u,frontMatter:()=>i,metadata:()=>s,toc:()=>c});var n=t(7462),a=(t(7294),t(3905));const i={sidebar_position:30},o="File Sharing",s={unversionedId:"core-features/files",id:"core-features/files",title:"File Sharing",description:"With zrok it is possible to share files quickly and easily as well. To share files using zrok use",source:"@site/../docs/core-features/files.md",sourceDirName:"core-features",slug:"/core-features/files",permalink:"/docs/core-features/files",draft:!1,editUrl:"https://github.com/openziti/zrok/tree/main/../docs/core-features/files.md",tags:[],version:"current",sidebarPosition:30,frontMatter:{sidebar_position:30},sidebar:"tutorialSidebar",previous:{title:"Shares - Reserved",permalink:"/docs/core-features/sharing-reserved"},next:{title:"Open Source",permalink:"/docs/core-features/opensource"}},l={},c=[],p={toc:c};function u(e){let{components:r,...i}=e;return(0,a.kt)("wrapper",(0,n.Z)({},p,i,{components:r,mdxType:"MDXLayout"}),(0,a.kt)("h1",{id:"file-sharing"},"File Sharing"),(0,a.kt)("p",null,"With ",(0,a.kt)("inlineCode",{parentName:"p"},"zrok")," it is possible to share files quickly and easily as well. To share files using ",(0,a.kt)("inlineCode",{parentName:"p"},"zrok")," use\nthe ",(0,a.kt)("inlineCode",{parentName:"p"},"--backend-mode web"),", for example: ",(0,a.kt)("inlineCode",{parentName:"p"},"zrok share private . --backend-mode web"),"."),(0,a.kt)("p",null,"Running with this mode will make it trivially easy to share files from the directory which the command\nwas run from."),(0,a.kt)("p",null,"For example if you have a directory with a structure like this:"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-shell"},"-rwxrwxrwx 1 cd cd 2506 Jan 26 11:57 README.md\n-rwxrwxrwx 1 cd cd 2971 Jan 26 11:57 CHANGELOG.md\n-rwxrwxrwx 1 cd c