Skip to main content

Ok i fround, I found the issue, someone removed the nsswitch file here: https://github.com/input-output-hk/plutus/commit/5dbd3b833b40217cb1a63d4f52351ae8876ba86c

The file tells the system to lookup the hosts file, but without the filtfile, it won't.

So i, I just opened a my wsl-ubuntu and created the file in my home folder:

vi ~/nsswitch.conf

and put the content

passwd:    files mymachines systemd
group:     files mymachines systemd
shadow:    files

hosts:     files mymachines dns myhostname
networks:  files

ethers:    files
services:  files
protocols: files
rpc:       files

now iNow, I changed the devcontainer.json so it mounts the file:

{
    "name": "Plutus Starter Project",
    "image": "plutus-devcontainer:latest",

    "remoteUser": "plutus",

    "mounts": [
        // This shares cabal's remote repository state with the host. We don't mount the whole of '.cabal', because
        // 1. '.cabal/config' contains absolute paths that will only make sense on the host, and
        // 2. '.cabal/store' is not necessarily portable to different version of cabal etc.
        "source=${localEnv:HOME}/.cabal/packages,target=/home/plutus/.cabal/packages,type=bind,consistency=cached",
        "source=${localEnv:HOME}/nsswitch.conf,target=/etc/nsswitch.conf,type=bind,consistency=cached",
    ],

    "settings": {
        // Note: don't change from bash so it runs .bashrc
        "terminal.integrated.shell.linux": "/bin/bash"
    },
    
    // IDs of extensions inside container
    "extensions": [
        "haskell.haskell"
    ],
}

Now i'mI'm back in businesbusiness

Ok i fround the issue, someone removed the nsswitch file here: https://github.com/input-output-hk/plutus/commit/5dbd3b833b40217cb1a63d4f52351ae8876ba86c

The file tells the system to lookup the hosts file, but without the filt, it won't.

So i just opened a my wsl-ubuntu and created the file in my home folder:

vi ~/nsswitch.conf

and put the content

passwd:    files mymachines systemd
group:     files mymachines systemd
shadow:    files

hosts:     files mymachines dns myhostname
networks:  files

ethers:    files
services:  files
protocols: files
rpc:       files

now i changed the devcontainer.json so it mounts the file:

{
    "name": "Plutus Starter Project",
    "image": "plutus-devcontainer:latest",

    "remoteUser": "plutus",

    "mounts": [
        // This shares cabal's remote repository state with the host. We don't mount the whole of '.cabal', because
        // 1. '.cabal/config' contains absolute paths that will only make sense on the host, and
        // 2. '.cabal/store' is not necessarily portable to different version of cabal etc.
        "source=${localEnv:HOME}/.cabal/packages,target=/home/plutus/.cabal/packages,type=bind,consistency=cached",
        "source=${localEnv:HOME}/nsswitch.conf,target=/etc/nsswitch.conf,type=bind,consistency=cached",
    ],

    "settings": {
        // Note: don't change from bash so it runs .bashrc
        "terminal.integrated.shell.linux": "/bin/bash"
    },
    
    // IDs of extensions inside container
    "extensions": [
        "haskell.haskell"
    ],
}

Now i'm back in busines

Ok, I found the issue, someone removed the nsswitch file here: https://github.com/input-output-hk/plutus/commit/5dbd3b833b40217cb1a63d4f52351ae8876ba86c

The file tells the system to lookup the hosts file, but without the file, it won't.

So, I just opened a my wsl-ubuntu and created the file in my home folder:

vi ~/nsswitch.conf

and put the content

passwd:    files mymachines systemd
group:     files mymachines systemd
shadow:    files

hosts:     files mymachines dns myhostname
networks:  files

ethers:    files
services:  files
protocols: files
rpc:       files

Now, I changed the devcontainer.json so it mounts the file:

{
    "name": "Plutus Starter Project",
    "image": "plutus-devcontainer:latest",

    "remoteUser": "plutus",

    "mounts": [
        // This shares cabal's remote repository state with the host. We don't mount the whole of '.cabal', because
        // 1. '.cabal/config' contains absolute paths that will only make sense on the host, and
        // 2. '.cabal/store' is not necessarily portable to different version of cabal etc.
        "source=${localEnv:HOME}/.cabal/packages,target=/home/plutus/.cabal/packages,type=bind,consistency=cached",
        "source=${localEnv:HOME}/nsswitch.conf,target=/etc/nsswitch.conf,type=bind,consistency=cached",
    ],

    "settings": {
        // Note: don't change from bash so it runs .bashrc
        "terminal.integrated.shell.linux": "/bin/bash"
    },
    
    // IDs of extensions inside container
    "extensions": [
        "haskell.haskell"
    ],
}

Now I'm back in business

Source Link
wutzebaer
  • 631
  • 4
  • 13

Ok i fround the issue, someone removed the nsswitch file here: https://github.com/input-output-hk/plutus/commit/5dbd3b833b40217cb1a63d4f52351ae8876ba86c

The file tells the system to lookup the hosts file, but without the filt, it won't.

So i just opened a my wsl-ubuntu and created the file in my home folder:

vi ~/nsswitch.conf

and put the content

passwd:    files mymachines systemd
group:     files mymachines systemd
shadow:    files

hosts:     files mymachines dns myhostname
networks:  files

ethers:    files
services:  files
protocols: files
rpc:       files

now i changed the devcontainer.json so it mounts the file:

{
    "name": "Plutus Starter Project",
    "image": "plutus-devcontainer:latest",

    "remoteUser": "plutus",

    "mounts": [
        // This shares cabal's remote repository state with the host. We don't mount the whole of '.cabal', because
        // 1. '.cabal/config' contains absolute paths that will only make sense on the host, and
        // 2. '.cabal/store' is not necessarily portable to different version of cabal etc.
        "source=${localEnv:HOME}/.cabal/packages,target=/home/plutus/.cabal/packages,type=bind,consistency=cached",
        "source=${localEnv:HOME}/nsswitch.conf,target=/etc/nsswitch.conf,type=bind,consistency=cached",
    ],

    "settings": {
        // Note: don't change from bash so it runs .bashrc
        "terminal.integrated.shell.linux": "/bin/bash"
    },
    
    // IDs of extensions inside container
    "extensions": [
        "haskell.haskell"
    ],
}

Now i'm back in busines