PageSourceSearch

https://www.verdaccio.org/assets/js/08a92283.722a5d55.js

js verdaccio.org collected 2026-10-02 14:33:50 UTC 9,709 bytes, 1 lines download raw bytes

1"use strict";(globalThis.webpackChunk_verdaccio_website=globalThis.webpackChunk_verdaccio_website||[]).push([[3126],{80892:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>d,contentTitle:()=>a,default:()=>h,frontMatter:()=>o,metadata:()=>s,toc:()=>c});const s=JSON.parse('{"id":"iss-server","title":"Installing on IIS server","description":"Run Verdaccio behind IIS on Windows Server. Community-maintained and written for a much older stack.","source":"@site/docs/iis-server.md","sourceDirName":".","slug":"/iss-server","permalink":"/docs/iss-server","draft":false,"unlisted":false,"editUrl":"https://github.com/verdaccio/website/edit/master/website/docs/iis-server.md","tags":[],"version":"current","lastUpdatedBy":"Jotadeveloper","lastUpdatedAt":1790630475000,"frontMatter":{"id":"iss-server","title":"Installing on IIS server","description":"Run Verdaccio behind IIS on Windows Server. Community-maintained and written for a much older stack."},"sidebar":"docs","previous":{"title":"Installing As a Windows Service","permalink":"/docs/windows"},"next":{"title":"Kubernetes","permalink":"/docs/kubernetes"}}');var t=i(8265),r=i(92233);const o={id:"iss-server",title:"Installing on IIS server",description:"Run Verdaccio behind IIS on Windows Server. Community-maintained and written for a much older stack."},a=void 0,d={},c=[{value:"package.json",id:"packagejson",level:3},{value:"start.js",id:"startjs",level:3},{value:"Alternate start.js for Verdaccio versions < v3.0",id:"alternate-startjs-for-verdaccio-versions--v30",level:3},{value:"web.config",id:"webconfig",level:3},{value:"Troubleshooting",id:"troubleshooting",level:3}];function l(e){const n={a:"a",admonition:"admonition",code:"code",h3:"h3",li:"li",p:"p",pre:"pre",strong:"strong",ul:"ul",...(0,r.R)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)(n.admonition,{title:"Community-maintained, and written for a much older stack",type:"caution",children:[(0,t.jsxs)(n.p,{children:["These instructions were originally written for Windows Server 2016, IIS 10,\nNode.js 10.15.0, ",(0,t.jsx)(n.a,{href:"https://github.com/Azure/iisnode",children:"iisnode 0.2.26"})," and Verdaccio 3.11.0.\nThey have ",(0,t.jsx)(n.strong,{children:"not"})," been revalidated against a supported Verdaccio (",(0,t.jsx)(n.strong,{children:"6.x"})," needs Node.js\n22 or newer), and ",(0,t.jsx)(n.code,{children:"iisnode"})," itself is no longer actively maintained."]}),(0,t.jsxs)(n.p,{children:["Treat the steps as a starting point rather than a tested recipe. If you only need\nVerdaccio to run as a Windows service, ",(0,t.jsx)(n.a,{href:"/docs/windows",children:"installing it as a service"})," is the\nbetter-supported route, and putting it behind a\n",(0,t.jsx)(n.a,{href:"/docs/reverse-proxy",children:"reverse proxy"})," covers the IIS-in-front case."]})]}),"\n",(0,t.jsxs)(n.ul,{children:["\n",(0,t.jsxs)(n.li,{children:["Install IIS Install ",(0,t.jsx)(n.a,{href:"https://github.com/Azure/iisnode",children:"iisnode"}),".\nMake sure you install prerequisites (Url Rewrite Module & node) as explained in the instructions for iisnode."]}),"\n",(0,t.jsxs)(n.li,{children:["Create a new folder in Explorer where you want to host verdaccio.\nFor example ",(0,t.jsx)(n.code,{children:"C:\\verdaccio"}),".\nSave ",(0,t.jsx)(n.a,{href:"#packagejson",children:"package.json"}),",\n",(0,t.jsx)(n.a,{href:"#startjs",children:"start.js"}),"\nand ",(0,t.jsx)(n.a,{href:"#webconfig",children:"web.config"})," in this folder."]}),"\n",(0,t.jsxs)(n.li,{children:["Create a new site in Internet Information Services Manager. You can name it whatever you want.\nI'll call it verdaccio in these ",(0,t.jsx)(n.a,{href:"http://www.iis.net/learn/manage/configuring-security/application-pool-identities",children:"instructions"}),". Specify the path to where you saved all files and a port number."]}),"\n",(0,t.jsx)(n.li,{children:"Go back to Explorer and give the user that runs the application pool modify rights to the folder you just created. If you've named the new site verdaccio and did not change the app pool, it's running under an ApplicationPoolIdentity and you should give the user IIS AppPool\\verdaccio modify rights see instructions if you need help. (You can restrict access later if you want so that it only has modify rights on the iisnode and verdaccio\\storage)"}),"\n",(0,t.jsx)(n.li,{children:"Start a command prompt and execute the commands below to download verdaccio:"}),"\n"]}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{children:"cd c:\\verdaccio\nnpm install\n"})}),"\n",(0,t.jsxs)(n.ul,{children:["\n",(0,t.jsx)(n.li,{children:"Make sure you have an inbou
1nd rule accepting TCP traffic to the port in Windows Firewall"}),"\n",(0,t.jsx)(n.li,{children:"Thats it! Now you can navigate to the host and port that you specified"}),"\n"]}),"\n",(0,t.jsxs)(n.p,{children:["I wanted the ",(0,t.jsx)(n.code,{children:"verdaccio"})," site to be the default site in IIS so I did the following:"]}),"\n",(0,t.jsxs)(n.ul,{children:["\n",(0,t.jsx)(n.li,{children:'I stopped the "Default Web Site" and only start the site "verdaccio" site in IIS'}),"\n",(0,t.jsx)(n.li,{children:'I set the bindings to "http", ip address "All Unassigned" on port 80, ok any warning or prompts'}),"\n"]}),"\n",(0,t.jsxs)(n.p,{children:["These instructions are based on ",(0,t.jsx)(n.a,{href:"https://gist.github.com/HCanber/4dd8409f79991a09ac75",children:"this guide to hosting a registry in IIS\non Windows"}),". I had to tweak my web config as per below but you may find the original from the\nfor mentioned link works better"]}),"\n",(0,t.jsxs)(n.p,{children:["A default configuration file will be created ",(0,t.jsx)(n.code,{children:"c:\\verdaccio\\verdaccio\\config.yaml"})]}),"\n",(0,t.jsx)(n.h3,{id:"packagejson",children:"package.json"}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-json",children:'{\n  "name": "iisnode-verdaccio",\n  "version": "1.0.0",\n  "description": "Hosts verdaccio in iisnode",\n  "main": "start.js",\n  "dependencies": {\n    "verdaccio": "^3.11.0"\n  }\n}\n'})}),"\n",(0,t.jsx)(n.h3,{id:"startjs",children:"start.js"}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-bash",children:"process.argv.push('-l', 'unix:' + process.env.PORT, '-c', './config.yaml');\nrequire('./node_modules/verdaccio/build/lib/cli.js');\n"})}),"\n",(0,t.jsx)(n.h3,{id:"alternate-startjs-for-verdaccio-versions--v30",children:"Alternate start.js for Verdaccio versions < v3.0"}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-bash",children:"process.argv.push('-l', 'unix:' + process.env.PORT);\nrequire('./node_modules/verdaccio/src/lib/cli.js');\n"})}),"\n",(0,t.jsx)(n.h3,{id:"webconfig",children:"web.config"}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{className:"language-xml",children:'<configuration>\n  <system.webServer>\n\t<modules>\n\t\t<remove name="WebDAVModule" />\n\t</modules>\n\n    \x3c!-- indicates that the start.js file is a node.js application\n    to be handled by the iisnode module --\x3e\n    <handlers>\n            <remove name="WebDAV" />\n\t\t\t<add name="iisnode" path="start.js" verb="*" modules="iisnode" resourceType="Unspecified" requireAccess="Execute" />\n            <add name="WebDAV" path="*" verb="*" modules="WebDAVModule" resourceType="Unspecified" requireAccess="Execute" />\n    </handlers>\n\n    <rewrite>\n      <rules>\n\n        \x3c!-- iisnode folder is where iisnode stores it\'s logs. These should\n        never be rewritten --\x3e\n        <rule name="iisnode" stopProcessing="true">\n            <match url="iisnode*" />\n            <conditions logicalGrouping="MatchAll" trackAllCaptures="false" />\n            <action type="None" />\n        </rule>\n\n        \x3c!-- Rewrite all other urls in order for verdaccio to handle these --\x3e\n        <rule name="verdaccio">\n            <match url="/*" />\n            <conditions logicalGrouping="MatchAll" trackAllCaptures="false" />\n            <action type="Rewrite" url="start.js" />\n        </rule>\n      </rules>\n    </rewrite>\n\n    \x3c!-- exclude node_modules directory and subdirectories from serving\n    by IIS since these are implementation details of node.js applications --\x3e\n    <security>\n      <requestFiltering>\n        <hiddenSegments>\n          <add segment="node_modules" />\n        </hiddenSegments>\n      </requestFiltering>\n    </security>\n\n  </system.webServer>\n</configuration>\n'})}),"\n",(0,t.jsx)(n.h3,{id:"troubleshooting",children:"Troubleshooting"}),"\n",(0,t.jsxs)(n.ul,{children:["\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.strong,{children:"The web interface does not load when hosted with https as it tries to download scripts over http."}),"\nMake sure that you have enabled ",(0,t.jsx)(n.code,{children:"X-Forwarded-Proto"})," in IISNode using ",(0,t.jsx)(n.code,{children:"enableXFF"}),". See ",(0,t.jsx)(n.a,{href:"https://github.com/verdaccio/verdaccio/issues/2003",children:"the related issue"}),"."]}),"\n"]}),"\n",(0,t.jsx)(n.pre,{children:(0,t.jsx)(n.code,{children:'<configuration>\n  <system.webServer>\n    <iisnode enableXFF="true" />\n  </system.webServer>\n</configuration>\n'})})]})}function h(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,t.jsx)(n,{...e,children:(0,t.jsx)(l,{...e})}):l(e)}},92233:(e,n,i)=>{i.d(n,{R:()=>o,x:()=>a});var s=i(70141);const t={},r=s.createContext(t);function o(e){const n=s.useContext(r);return s.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function a(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:o(e.components),s.createElement(r.Provider,{value:n},e.children)}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.