(window.webpackJsonp=window.webpackJsonp||[]).push([[46],{319:function(e,t,a){"use strict";a.r(t);var s=a(13),o=Object(s.a)({},(function(){var e=this,t=e._self._c;return t("ContentSlotsDistributor",{attrs:{"slot-key":e.$parent.slotKey}},[t("h1",{attrs:{id:"github-ci"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#github-ci"}},[e._v("#")]),e._v(" GitHub CI")]),e._v(" "),t("blockquote",[t("p",[e._v("This guide explains how to publish a forked version of Directus on NPM, Dockerhub and GHCR. You need to first\n"),t("RouterLink",{attrs:{to:"/contributing/running-locally/"}},[e._v("create a fork")])],1)]),e._v(" "),t("div",{staticClass:"custom-block warning"},[t("p",{staticClass:"custom-block-title"},[e._v("Using a fork in production is neither supported nor recommended.")]),e._v(" "),t("p",[e._v("Only do so if:")]),e._v(" "),t("ol",[t("li",[e._v("The feature you want to implement doesn't satisfy the 80/20 principle")]),e._v(" "),t("li",[e._v("There is a technical limitation preventing you from implementing it as an extension")])]),e._v(" "),t("p",[e._v("Forks are not officially supported - please don't submit fork-specific bugs and questions on the official repo.")]),e._v(" "),t("p",[e._v("If you suspect a bug to not be part of your changes please confirm this by reproducing it with the official version\n"),t("strong",[e._v("before")]),e._v(" submitting an issue.")])]),e._v(" "),t("div",{staticClass:"custom-block tip"},[t("p",{staticClass:"custom-block-title"},[e._v("Minimum Requirements")]),e._v(" "),t("p",[e._v("If you want to publish your fork to hub.docker.com or NPM you need to have an account there.")]),e._v(" "),t("p",[e._v("Note: to publish to NPM you probably have to change all the package names. Publishing to NPM should almost never be\nnecessary.")])]),e._v(" "),t("h2",{attrs:{id:"_1-setup-environment-variables-secrets"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#_1-setup-environment-variables-secrets"}},[e._v("#")]),e._v(" 1. Setup environment variables/secrets")]),e._v(" "),t("h2",{attrs:{id:"general"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#general"}},[e._v("#")]),e._v(" General")]),e._v(" "),t("table",[t("thead",[t("tr",[t("th",[e._v("Variable")]),e._v(" "),t("th",[e._v("Description")]),e._v(" "),t("th",[e._v("Example")])])]),e._v(" "),t("tbody",[t("tr",[t("td",[t("code",[e._v("GHCR_IMAGE")])]),e._v(" "),t("td",[e._v("Image name for GitHub Container Registry. Be sure to use the full URL.")]),e._v(" "),t("td",[t("code",[e._v("ghcr.io/directus/directus")])])]),e._v(" "),t("tr",[t("td",[t("code",[e._v("DOCKERHUB_IMAGE")])]),e._v(" "),t("td",[e._v("Image name for hub.docker.com, no prefix.")]),e._v(" "),t("td",[t("code",[e._v("directus/directus")])])])])]),e._v(" "),t("table",[t("thead",[t("tr",[t("th",[e._v("Secret")]),e._v(" "),t("th",[e._v("Description")]),e._v(" "),t("th",[e._v("Example")])])]),e._v(" "),t("tbody",[t("tr",[t("td",[t("code",[e._v("NPM_TOKEN")])]),e._v(" "),t("td",[e._v('Your NPM token. Make sure to use the type "automation".')]),e._v(" "),t("td",[t("code",[e._v("12345678-...")])])]),e._v(" "),t("tr",[t("td",[t("code",[e._v("DOCKERHUB_USERNAME")])]),e._v(" "),t("td",[e._v("Dockerhub Username")]),e._v(" "),t("td",[t("code",[e._v("directus")])])]),e._v(" "),t("tr",[t("td",[t("code",[e._v("DOCKERHUB_PASSWORD")])]),e._v(" "),t("td",[e._v("Dockerhub Password")]),e._v(" "),t("td",[t("code",[e._v("hunter2")])])])])]),e._v(" "),t("h2",{attrs:{id:"_2-create-a-release"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#_2-create-a-release"}},[e._v("#")]),e._v(" 2. Create a release")]),e._v(" "),t("div",{staticClass:"language-bash extra-class"},[t("pre",{pre:!0,attrs:{class:"language-bash"}},[t("code",[t("span",{pre:!0,attrs:{class:"token function"}},[e._v("npm")]),e._v(" run release\n")])])])])}),[],!1,null,null,null);t.default=o.exports}}]);