Home liberachat/#haskell: Logs Calendar

Logs: liberachat/#haskell

←Prev  Next→ 1,803,203 events total
2021-07-21 22:46:38 × shapr quits (~user@pool-100-36-247-68.washdc.fios.verizon.net) (Remote host closed the connection)
2021-07-21 22:47:11 <maerwald[m]> You can also add BOOTSTRAP_HASKELL_INSTALL_STACK=yes
2021-07-21 22:48:00 <maerwald[m]> /root/.ghcup/bin needs to be in PATH
2021-07-21 22:48:18 <maerwald[m]> See the link earlier
2021-07-21 22:48:38 agua joins (~agua@191.177.175.57)
2021-07-21 22:49:08 <ph88^> not sure if i need stack to be installed in the container, when on the host stack is using the container to build stuff .. but ok
2021-07-21 22:50:31 × Vajb quits (~Vajb@hag-jnsbng11-58c3a1-224.dhcp.inet.fi) (Read error: Connection reset by peer)
2021-07-21 22:50:35 <maerwald[m]> I always forget how to set PATH in a docker build. There are always caveats.
2021-07-21 22:50:44 Vajb joins (~Vajb@85-76-37-76-nat.elisa-mobile.fi)
2021-07-21 22:51:18 <ph88^> ye i'm not even sure what shell alpine is running there .. i'm trying to find out .. everytime restarting the docker image build and download ghc over again o_O
2021-07-21 22:51:32 lavaman joins (~lavaman@98.38.249.169)
2021-07-21 22:52:12 × Core2909 quits (~agua@2804:18:4e:2dda:1:0:4058:6b7c) (Ping timeout: 245 seconds)
2021-07-21 22:52:14 <maerwald[m]> Docker is amazing
2021-07-21 22:52:17 <maerwald[m]> Lol
2021-07-21 22:52:46 <yushyin> changed my mind
2021-07-21 22:53:22 <arkanoid> try nix shell or nix + docker, it is even better
2021-07-21 22:55:06 <dsal> nix + docker?
2021-07-21 22:55:59 × lavaman quits (~lavaman@98.38.249.169) (Ping timeout: 255 seconds)
2021-07-21 22:56:05 <maerwald[m]> The worst of both worlds
2021-07-21 22:58:21 shutdown_-h_now joins (~arjan@82-75-187-100.cable.dynamic.v4.ziggo.nl)
2021-07-21 22:58:33 <arkanoid> Not really. It generates the smallest images. https://nixos.org/guides/building-and-running-docker-images.html
2021-07-21 22:59:20 Matthias1 joins (~Matthias1@cpe-76-170-236-166.socal.res.rr.com)
2021-07-21 22:59:45 <ph88^> seems alpine is running "ash" shell (never heard of) and only rc/profile file available by default lives under /etc/profile
2021-07-21 23:00:19 <janus> there are many minimalist shells forcing people to avoid bashisms
2021-07-21 23:00:19 <Arahael> arkanoid: even without nix, docker is small enough.
2021-07-21 23:00:26 <janus> probably a secret plot of the BSDers
2021-07-21 23:01:36 <arkanoid> Arahael: it depends on the context. Containers != docker, and they run on raspberry too.
2021-07-21 23:03:15 <janus> so when you say nix+docker, what do you mean? using nix to build an OCI image?
2021-07-21 23:03:44 aegon joins (~mike@174.127.249.180)
2021-07-21 23:05:30 × Matthias1 quits (~Matthias1@cpe-76-170-236-166.socal.res.rr.com) (Ping timeout: 240 seconds)
2021-07-21 23:06:59 <janus> docker is a tricky term, very polymorphic :O
2021-07-21 23:07:03 × terrorjack quits (~terrorjac@ec2-54-95-39-30.ap-northeast-1.compute.amazonaws.com) (Quit: Ping timeout (120 seconds))
2021-07-21 23:07:06 × ralu quits (~ralu@static.211.245.203.116.clients.your-server.de) (Quit: Ping timeout (120 seconds))
2021-07-21 23:07:13 spirgel_ joins (spirgel@gateway/vpn/protonvpn/spirgel)
2021-07-21 23:07:16 ralu joins (~ralu@static.211.245.203.116.clients.your-server.de)
2021-07-21 23:07:31 <arkanoid> use nix to build the minimum environment to run your process in a reproducible way, then pack it wherever you need. If you need to use layers, just take the dependency graph and draw a line where you need
2021-07-21 23:07:45 × davl quits (~davl@207.154.228.18) (Read error: Connection reset by peer)
2021-07-21 23:07:56 × haasn quits (~nand@haasn.dev) (Remote host closed the connection)
2021-07-21 23:08:00 terrorjack joins (~terrorjac@ec2-54-95-39-30.ap-northeast-1.compute.amazonaws.com)
2021-07-21 23:08:04 davl joins (~davl@207.154.228.18)
2021-07-21 23:08:07 × connrs quits (~connrs@user/connrs) (Quit: ZNC 1.8.2 - https://znc.in)
2021-07-21 23:08:07 × hexology quits (~hexology@user/hexology) (Quit: hex on you ...)
2021-07-21 23:08:15 haasn joins (~nand@haasn.dev)
2021-07-21 23:08:15 <arkanoid> https://grahamc.com/blog/nix-and-layered-docker-images
2021-07-21 23:08:26 connrs joins (~connrs@user/connrs)
2021-07-21 23:08:26 hexology joins (~hexology@user/hexology)
2021-07-21 23:08:57 <Arahael> arkanoid: yeah, well, i'm referring to docker. :)
2021-07-21 23:09:08 <ph88^> damn, i added the ghcup stuff to $PATH and still can't find ghc :(
2021-07-21 23:09:50 pesada joins (~agua@2804:18:4e:2dda:1:0:4058:6b7c)
2021-07-21 23:10:12 × zangi quits (~zangi@103.154.230.230) (Quit: zangi)
2021-07-21 23:10:25 <janus> arkanoid: intersting post! thanks
2021-07-21 23:10:26 × spirgel quits (spirgel@gateway/vpn/protonvpn/spirgel) (Ping timeout: 252 seconds)
2021-07-21 23:12:37 jeetelongname joins (~jeet@host-89-241-98-229.as13285.net)
2021-07-21 23:13:05 × agua quits (~agua@191.177.175.57) (Ping timeout: 255 seconds)
2021-07-21 23:13:15 <janus> ph88^: did you remember to do "source ~/.bashrc" or the equivalent on your shell?
2021-07-21 23:13:27 <arkanoid> I'm puzzled if a newcomer should prefer Text over String or not
2021-07-21 23:13:33 <janus> ph88^: if i do "which ghci" , i get /home/janus/.ghcup/bin/ghci
2021-07-21 23:14:36 cjb joins (~cjb@user/cjb)
2021-07-21 23:14:42 <ph88^> janus, doesn't the profile get reloaded when the docker container is started ?
2021-07-21 23:15:21 <geekosaur> if you described ash correctly earlier, it has to be run as a login shell to read /etc/profile
2021-07-21 23:15:29 jeetelongname is now known as yeetaditya
2021-07-21 23:15:38 bitdex joins (~bitdex@gateway/tor-sasl/bitdex)
2021-07-21 23:15:52 <janus> right, maybe there is a way to inspect the ENTRYPOINT to check it... hmm
2021-07-21 23:15:52 <arkanoid> also, are all literal strings always of String type? Do I have to Data.Text.pack them all?
2021-07-21 23:16:11 <janus> arkanoid: there is an extension called OverloadedStrings
2021-07-21 23:16:16 <geekosaur> arkanoid, see the OverloadedStrings extension
2021-07-21 23:16:23 yeetaditya is now known as yeet
2021-07-21 23:16:24 <ph88^> geekosaur, where would it look when running this shell not as login shell ?
2021-07-21 23:16:29 <arkanoid> thanks!
2021-07-21 23:16:53 yeet is now known as jeetelongname
2021-07-21 23:17:00 <geekosaur> ph88^, if it's a minimalist Bourne-compatible shell, it doesn't have a startup file at all
2021-07-21 23:17:08 × earthy quits (~arthurvl@2001:984:275b:1:ba27:ebff:fea0:40b0) (Ping timeout: 255 seconds)
2021-07-21 23:17:42 <geekosaur> you would have to arrange for $PATH to be set some other way, or run it as a login shell (ash -l, one hopes)
2021-07-21 23:17:48 <janus> ph88^: you could try "cat /proc/self/cmdline", and see if it has the -l param
2021-07-21 23:17:55 <janus> % readFile /proc/self/cmdline
2021-07-21 23:17:56 <yahb> janus: ; <interactive>:40:11: error: Variable not in scope: proc :: FilePath -> IO String; <interactive>:40:16: error: Variable not in scope: self :: FilePath -> IO String; <interactive>:40:21: error: Variable not in scope: cmdline :: FilePath -> IO String
2021-07-21 23:18:02 <geekosaur> (if it's really minimalist you'd have to symlink it to -ash and run it that way)
2021-07-21 23:18:31 <geekosaur> quotes are a thing, janus
2021-07-21 23:18:52 × favonia quits (~favonia@user/favonia) (Ping timeout: 245 seconds)
2021-07-21 23:18:52 <geekosaur> % readFile "/proc/self/cmdline"
2021-07-21 23:18:53 <yahb> geekosaur: "/srv/sandbox/root/usr/lib/ghc-9.0.1/bin/ghc\NUL-B/srv/sandbox/root/usr/lib/ghc-9.0.1\NUL--interactive\NUL-v0\NUL-ghci-script\NUL/srv/sandbox/root/usr/lib/run/ghci-init\NUL-tmpdir\NUL/srv/sandbox/root/data/tmp/\NUL-odir\NUL/srv/sandbox/root/data/tmp/\NUL-hidir\NUL/srv/sandbox/root/data/tmp/\NUL-ignore-dot-ghci\NUL-package\NULghc\NUL+RTS\NUL-M200M\NUL-V0\NUL-C0\NUL-K100M\NUL"
2021-07-21 23:19:50 × MQ-17J quits (~MQ-17J@d14-69-206-129.try.wideopenwest.com) (Ping timeout: 255 seconds)
2021-07-21 23:19:51 <geekosaur> you could also just start the list of commands with ". /etc/profile"
2021-07-21 23:20:22 favonia joins (~favonia@user/favonia)
2021-07-21 23:20:30 <janus> but it is a shell built-in, will that work? would be weird if docker knows the shell builtins
2021-07-21 23:20:49 merijn joins (~merijn@83-160-49-249.ip.xs4all.nl)
2021-07-21 23:21:01 <janus> oooh ok it is an interactive shell, i get it
2021-07-21 23:21:09 <janus> thought you meant putting it in the Dockerfile
2021-07-21 23:21:51 <geekosaur> I did but you have a list of commands to be run in various contexts and I was suggesting putting that at the beginning of the list
2021-07-21 23:22:16 <ph88^> maybe i should go with this rather than try to make my own Dockerfile https://hub.docker.com/r/fpco/alpine-haskell-stack
2021-07-21 23:23:50 × raehik quits (~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 265 seconds)
2021-07-21 23:24:19 × shutdown_-h_now quits (~arjan@82-75-187-100.cable.dynamic.v4.ziggo.nl) (Ping timeout: 250 seconds)
2021-07-21 23:24:43 MQ-17J joins (~MQ-17J@d14-69-206-129.try.wideopenwest.com)
2021-07-21 23:24:57 × Cajun quits (~Cajun@ip98-163-211-112.no.no.cox.net) (Quit: Client closed)
2021-07-21 23:26:31 × jeetelongname quits (~jeet@host-89-241-98-229.as13285.net) (Remote host closed the connection)
2021-07-21 23:26:34 Matthias1 joins (~Matthias1@cpe-76-170-236-166.socal.res.rr.com)
2021-07-21 23:26:46 jeetelongname joins (~jeet@host-89-241-98-229.as13285.net)
2021-07-21 23:28:35 <Boarders> is there a lensy variant of the state function from the MonadState typeclass that operates on something you have a lens into
2021-07-21 23:28:52 × MQ-17J quits (~MQ-17J@d14-69-206-129.try.wideopenwest.com) (Ping timeout: 245 seconds)
2021-07-21 23:28:59 × ski quits (~ski@ed-3358-10.studat.chalmers.se) (Ping timeout: 268 seconds)

All times are in UTC.