Open nartamonov opened 2 years ago
Adding in @stuartpike who owns the community definition.
Behaviour received at 'stack build' 'Preparing to install GHC (tinfo6) to an isolated location' is the default behaviour I've experienced. The download only takes place once for the account used when creating/building multiple projects. After the download has taken place you can build without needing to login as root.
Testing: On native clean Linux install using 'curl --proto '=https' --tlsv1.2 -sSf https://get-ghcup.haskell.org | sh' directly from haskell.
The issue raised looks not to be with the container or a native installation, but with how haskell installs. So I'd suggest contacting haskell community for assistance.
I'm trying to use Haskell dev-container with my
stack
-based toy project. Haskell dev-container is based on docker image haskell. As it turned out that image is not adapted to work under a user other thanroot
. For example, they configurestack
to use global system-wide GHC installation over self-managed local installation:Unfortunately, those settings stored under
/root/.stack/config.yml
and since dev-container currently configured to work under uservscode
, when I usestack
it tries to download and install GHC locally event though I already had one:If I logs in as
root
it works as expected:I assume there are two possible solutions to the problem:
remoteUser
toroot
indevcontainer.json
. Dont know what consequences it will have.user
argument so that we could build dev-container for specific user,vscode
in our case.