Install Stack without internet access
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

Offline Stack Build Status

This project provides a demo of using Haskell Stack without internet access.

The demo is all in appveyor.yml, which is executed on Appveyor. It comprises of the following steps:

  • Build and execute a Haskell binary which can serve up any files from the internet and mirror them.
  • Set http_proxy and https_proxy to invalid values, so any attempt by Stack to access the internet directly fails.
  • Set all the appropriate Stack settings to hit the Haskell binary.

This code demonstrates the steps required, but does not address two crucial issues:

  • It doesn't say how to get the files in the first place. One way of addressing that is with haskell-stack-mirror-script from @AleXoundOS.
  • It provides a mechanism to serve the files up, but it may not be the most appropriate mechanism - often using an existing Apache/IIS server to serve the files will be easier, and provide additional features.