hpal
hpal copied to clipboard
hpal new <projectname> doesn't work in a closed environment
I am attempting to use hpal new <projectname>
in a closed environment with no Internet access. When I try to run it, I get the following message:
Couldn't create a new project. It seems you may be offline- ensure you have a connection then try again.
Our repos are proxied through verdaccio so we can still install whatever we need to, but I'm wondering if other external calls are being made.
@reedog117 That command does require access to the hapipal boilerplate repo https://github.com/hapipal/boilerplate -- it clones the latest version on the pal
branch into the given foldername
Exactly! Roughly, the steps look like this,
git clone --depth=1 --origin=pal --branch=pal [email protected]:hapipal/boilerplate.git my-project
cd my-project
git checkout --orphan master # New branch without history
git fetch pal --tags
npm init
Is this the only command that calls out to the Internet? i.e. can I clone it manually and copy it in, but still be able to use the other commands?
hpal docs
is the only other case—it also calls out to github to download and search API documentation. One thing I would love to have is a cache for hpal docs
.
Excellent. It would be very nice if the boilerplate and docs were accessible via npm
calls as it would be a great help for those developing in closed/restricted environments.
That is a really interesting idea. It would take some planning to imagine exactly how that would work—especially for the documentation, which currently does not travel with the packages in order to keep production installations small. The other tricky thing is flavors, which we implement with git tags and git cherry-picking. But I can definitely imagine a plain installation working by downloading and unpacking an npm tarball into a directory.