question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Blank Page with downloaded binary.

See original GitHub issue
  • code-server version: code-server1.939-vsc1.33.1-linux-x64.tar.gz
  • OS Version: Linux running in docker image php:7.3-apache (debian-slim), hosted on RHEL 7.6

Description

When using the Binary download in separately build docker environment. I get a blank web page. I am sure there is something missing in the environment that the binary needs, Perhaps access to other files from the source image, or some library, but there is no error report that helps determine the problem, or any ‘requirements’ outlined as needed for the binary.

On the other hand if I use the docker image they provide as a straight docker run image, it works fine. But I need to be able to run multiple copys of code-server in a docker swarm (seperated multiple-users for a class environment), meaning I need to run it as a ‘service’ in a swarm environment. Which is why I am trying to create my own docker image.

In summary: The binary in a swarm works, but gives a blank page, and the pre-build docker image does not work in a swarm.

Steps to Reproduce

Example… Start a php:7.3-apache service in a docker swarm. Run a BASH command line into that docker container (not as root), to download, install, and run in background; the latest binary code-server.

  curl -s -L https://github.com/codercom/code-server/releases/latest |
      grep download | grep tar.gz |
      sed '2q; s%.*href="%https://github.com%; s/".*//' |
      xargs curl -s -L -o - | tar zxvf -
    mv code-server*/ code-server
    chmod +x code-server/code-server
    code-server/code-server -d ~/code-server ~/html --no-auth --allow-html -p 8080 &

At this point I can connect to the code-server web page on port 8080, via the swarm ingress-nginx proxy (which currently allows http on 80, and 8080, and https on 8443). But I only see a blank page.

Same if I remove the option --allow-html -p 8080 and connect via https on port 8443

The blank page is why I theorize the provided binary requires something MORE that is not documented, or provided in the tar file for the binary.

I also see the following error, from the command line connection to the php:7.3-apache docker service Error: ENOENT: no such file or directory, open '/home/travis/build/codercom/code-server/packages/server/build/web/index.html' Which presumably is the path to the build directory of the provided binary, which is NOT present, in the tar file of the binary, or is effected by any option I have tried.

I have seen a similar error in the provided docker image… Error: ENOENT: no such file or directory, open '/src/packages/server/build/web/index.html' which does match the build directory used in the ‘Dockerfile’ (and is still present in the image) that was used to build that docker image.

It is very frustrating.

Addendum… Looking at the processes, running the code-server binary will then run another code-server sub-process with a Source directory path as the first argument, along with ‘development’ command line options. Again no option seem to effect or change this non-existent hard-coded ‘path’ from being included.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:4
  • Comments:16

github_iconTop GitHub Comments

4reactions
justinmooncommented, Apr 29, 2019

I’m also getting the `Error: ENOENT: no such file or directory, open ‘/src/packages/server/build/web/index.html’ when I run the provided docker image on a ubuntu 18.04 server, but not when I run it on my Arch dev machine …

2reactions
trowjcommented, May 3, 2019

I’m able to reproduce it when running behind a reverse proxy as well - running the image (in docker) I can connect if I go directly to the exposed port, but when accessing it at a context (abc.com/editor/) I get:

codeserver_1  | Error: ENOENT: no such file or directory, open '/src/packages/server/build/web/code-server/index.html'

EDIT: It was a bit of a pain to get setup right - mostly on the DNS side - but I did find that running at a subdomain does work fine - so ‘editor.abc.com’ works which means it shouldn’t be related to any of the network hops (router, rev.proxy, etc)

Read more comments on GitHub >

github_iconTop Results From Across the Web

Blank Page with downloaded binary. · Issue #609 - GitHub
I get a blank web page. I am sure there is something missing in the environment that the binary needs, Perhaps access to...
Read more >
PDF is blank when downloading using javascript
You are using a media type "text/pdf"; this is asking for trouble, pdf is not a text format, it is binary, and treating...
Read more >
CHM with Binary TOC enabled shows blank pages
I am generating an CHM File using RoboHelp 7 with the Binary TOC option enabled. Clicking on the topics in the generated file...
Read more >
Solved: PDF Returned from HTTP Response is Blank
However, the PDF file that is returned is blank. ... but the binary content of the pages is corrupted (which is why the...
Read more >
871848 - PDF DISPLAYS AS BLANK PAGE - Monorail
ALL THAT IS DISPLAYED IS A BLANK PAGE BUT THE PAGE COUNT IS CORRECT. THERE IS JUST NOTHING ON THE PAGE. Does it...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found