code: func writeStdioSymlinks(tarWriter *tar.Writer, fileMap map[string]struct{}, pwl []string) ([]string, error) {
  	stdioSymlinks := []symlink{
  		{"/dev/stdin", "/proc/self/fd/0"},
  		// Docker makes /dev/{stdout,stderr} point to /proc/self/fd/{1,2} but
  		// we point to /dev/console instead in order to support the case when
  		// stdout/stderr is a Unix socket (e.g. for the journal).
  		{"/dev/stdout", "/dev/console"},
  		{"/dev/stderr", "/dev/console"},
  		{"/dev/fd", "/proc/self/fd"},
  	}
  
  	for _, s := range stdioSymlinks {
  		name := s.linkname
  		target := s.target
  		if _, exists := fileMap[name]; exists {
  			continue
  		}
  		hdr := &tar.Header{
  			Name:     filepath.Join("rootfs", name),
  			Mode:     0777,
  			Typeflag: tar.TypeSymlink,
  			Linkname: target,
  		}
  		if err := tarWriter.WriteHeader(hdr); err != nil {
  			return nil, err
  		}
  		if !util.In(pwl, name) {
  			pwl = append(pwl, name)
  		}
  	}
  
  	return pwl, nil
  }
docs: // writeStdioSymlinks adds the /dev/stdin, /dev/stdout, /dev/stderr, and
  // /dev/fd symlinks expected by Docker to the converted ACIs so apps can find
  // them as expected