Passing tcp session via pipes to fork

is it possible to pass tcp session via pipes to forked ruby process ? here is the code i am trying
and it seems to not work (browser keeps waiting for response but response never comes)

code ->

    require 'socket'
    server = "" , 5678

    reader , writer = IO.pipe

    fork do
      loop do
      session =
      session.puts "Hello world! The time is #{}"
      puts server.class

while session = server.accept
  writer.write session

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs