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

Windows server symbolic links just shows path in browser #1336

Closed
RedSparr0w opened this issue Dec 6, 2017 · 4 comments
Closed

Windows server symbolic links just shows path in browser #1336

RedSparr0w opened this issue Dec 6, 2017 · 4 comments
Labels
developer-experience Dev tooling, test framework, and CI

Comments

@RedSparr0w
Copy link
Member

RedSparr0w commented Dec 6, 2017

Symbolic links do not seem to function as they should through the browser and instead just shows the path the sym link directs to:
image
Whenever i run start the server i have to copy the files over from the builds dir to the public dir to view the homepage correctly.

OS: Windows 10
Browsers tested: Chrome 62, Internet Explorer 11
Node: v8.7.0

Note: not a new problem, just hasn't really been too much of an issue

@paulmelnikow paulmelnikow added the developer-experience Dev tooling, test framework, and CI label Dec 6, 2017
@paulmelnikow
Copy link
Member

Yea, valid for sure.

Sort of an aside, have you tried the new npm start, which runs a separate frontend server? I imagine it will work. Maybe that is a good enough workaround for dev…

@RedSparr0w
Copy link
Member Author

RedSparr0w commented Dec 6, 2017

The new npm start doesn't work for me,
Think it's due to the same problem as #1259

npm start

> gh-badges@1.3.0 prestart C:\Users\Dan\Documents\GitHub\shields
> npm run frontend-depcheck


> gh-badges@1.3.0 frontend-depcheck C:\Users\Dan\Documents\GitHub\shields
> check-node-version --node ">= 8.0"


> gh-badges@1.3.0 start C:\Users\Dan\Documents\GitHub\shields
> concurrently --names server,frontend "ALLOWED_ORIGIN=http://localhost:3000 npm run start:server" "BASE_URL=http://[::]:8080 next dev"

[server] 'ALLOWED_ORIGIN' is not recognized as an internal or external command,
[server] operable program or batch file.
[frontend] 'BASE_URL' is not recognized as an internal or external command,
[frontend] operable program or batch file.
[server] ALLOWED_ORIGIN=http://localhost:3000 npm run start:server exited with code 1
[frontend] BASE_URL=http://[::]:8080 next dev exited with code 1

npm ERR! Windows_NT 10.0.16299
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\Dan\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "start"
npm ERR! node v8.7.0
npm ERR! npm  v4.3.0
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! gh-badges@1.3.0 start: `concurrently --names server,frontend "ALLOWED_ORIGIN=http://localhost:3000 npm run start:server" "BASE_URL=http://[::]:8080 next dev"`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the gh-badges@1.3.0 start script 'concurrently --names server,frontend "ALLOWED_ORIGIN=http://localhost:3000 npm run start:server" "BASE_URL=http://[::]:8080 next dev"'.

Update:
If i manually set the environment variables (also have to use localhost > [::]) and remove them from the npm start script it does work as intended

@RedSparr0w
Copy link
Member Author

RedSparr0w commented Dec 6, 2017

@paulmelnikow If i change npm start to the following it works for me on Windows 10, could you test if it still functions at it should for you?
concurrently --names server,frontend \"(ALLOWED_ORIGIN=http://localhost:3000 || set ALLOWED_ORIGIN=http://localhost:3000 ) && npm run start:server\" \"(BASE_URL=http://[::]:8080 || set BASE_URL=http://localhost:8080) && next dev\"
or
concurrently --names server,frontend \"set ALLOWED_ORIGIN=http://localhost:3000 && npm run start:server\" \"set BASE_URL=http://localhost:8080 && next dev\"

I'm fairly sure the second option should work in most environments

@paulmelnikow
Copy link
Member

As far as I can tell, we don't have any more symlinks in the codebase. I think I removed the last of them in #2906. 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
developer-experience Dev tooling, test framework, and CI
Projects
None yet
Development

No branches or pull requests

2 participants