Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Root folder option is't working in node 12.0 #137

Closed
stq opened this issue Mar 13, 2015 · 4 comments
Closed

Root folder option is't working in node 12.0 #137

stq opened this issue Mar 13, 2015 · 4 comments

Comments

@stq
Copy link

stq commented Mar 13, 2015

Specifying static folder does't work, i.e.

http-server -a localhost -p 8000 -c-1 app

still using ./public dir instead of ./app.

It seems like there is an error or compatibility problem at code in bin\http-server where options structure is being set from argv object, exactly here:
root: argv._[0],

it does't work because argv._ is an empty array.

Replacing it to
root: argv['1']

makes the option work.

Node version is 12.0, windows 7 x64

@BernardoGO
Copy link

Same problem here, it also crashes when running with ssl.
Any thoughts about the problem?

@Sharpe23
Copy link

@BernardoGO
for me it was the ssl

@thornjad
Copy link
Member

@stq @BernardoGO Are either of you still experiencing this issue?

@thornjad
Copy link
Member

Closing due to inactivity. Please reopen if this issue persists in the latest version of http-server!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants