NPM

NPM을 통한 remotely 사용시 잦은 끊김이 발생하는 경우

작성자 정보

  • Keiminem 작성
  • 작성일

컨텐츠 정보

  • 229 조회

본문

NPM을 통해 Remotely를 서비스하는 경우

이미 Remotely에 등록된 기기들이 잦은 끊김이 발생하고 제대로 연결 유지가 되지 않는 현상이있습니다.

해결책은 아래와 같이 제공되고 있습니다.

 

      server{listen80;server_name   example.com *.example.com;location /{proxy_pass         http://localhost:5000;proxy_http_version 1.1;proxy_set_header   Upgrade $http_upgrade;proxy_set_header   Connection keep-alive;proxy_set_header   Host $host;proxy_cache_bypass$http_upgrade;proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;proxy_set_header   X-Forwarded-Proto $scheme;proxy_set_header   X-Forwarded-Host $host;}location /_blazor{proxy_pass http://localhost:5000;proxy_http_version 1.1;proxy_set_header Upgrade $http_upgrade;proxy_set_header Connection "upgrade";proxy_set_header Host $host;proxy_cache_bypass$http_upgrade;proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;proxy_set_header   X-Forwarded-Proto $scheme;proxy_set_header   X-Forwarded-Host $host;}location /AgentHub{proxy_pass http://localhost:5000;proxy_http_version 1.1;proxy_set_header Upgrade $http_upgrade;proxy_set_header Connection "upgrade";proxy_set_header Host $host;proxy_cache_bypass$http_upgrade;proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;proxy_set_header   X-Forwarded-Proto $scheme;proxy_set_header   X-Forwarded-Host $host;}location /ViewerHub{proxy_pass http://localhost:5000;proxy_http_version 1.1;proxy_set_header Upgrade $http_upgrade;proxy_set_header Connection "upgrade";proxy_set_header Host $host;proxy_cache_bypass$http_upgrade;proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;proxy_set_header   X-Forwarded-Proto $scheme;proxy_set_header   X-Forwarded-Host $host;}location /CasterHub{proxy_pass http://localhost:5000;proxy_http_version 1.1;proxy_set_header Upgrade $http_upgrade;proxy_set_header Connection "upgrade";proxy_set_header Host $host;proxy_cache_bypass$http_upgrade;proxy_set_header   X-Forwarded-For $proxy_add_x_forwarded_for;proxy_set_header   X-Forwarded-Proto $scheme;proxy_set_header   X-Forwarded-Host $host;}}
      
 

 

한번 들여다 보시면 반복되는 코드가있고 NPM에서는 자동생성되는 코드에 이미 포함되어있는것들이있어서

여러분들이 보기 쉽게?! GUI상에서 설정해둔 것을 공개합니다. 두둥탁

 

1. 프록시 호스트 기본설정

image.png.jpg

 

2. 사용자 위치설정

image.png.jpg

추가설정에서 적은것은 아무것도 없습니다. 그냥 위치와 아이피 포트만 넣고 끝입니다.

 

3. 고급설정

 

image.png.jpg

고급설정에 프록시 헤더 세팅만 해주시면 끊김없이 즐기실수 있습니다.

 

이렇게 설정하고나니 별도의 nginx서버를 구축했던것이 필요가 없어졌습니다.

 

나중에 시간이 좀 남으면 이 고급설정에서 쓰이는 변수들을 좀 정리해볼까 합니다.

 

아무튼 여기까지 설정해주시고 나면 끊김없는 Remotely를 사용하실 수 있습니다.

 

여담으로 Remotely에서 WOL기능을 테스트중인데 잘될떈 잘되더니 또 안되는경우가있어서;;

이게 조금 색다른게 Remotely에 맥주소를 기반으로 등록하여 매직패킷을 쏘다보니 공유기나 라우터에 별도작업을 하지 않았음에도 WOL이 작동하더라구요 

물론 저도 위에 설명한 설정을 하기전에 테스트를 했던거라 안되는걸수도있는데

설정을 새로하였으니 한번 더 테스트해보고 공유하도록 하겠습니다. 

 

마무리는 원격중인 화면으로

image.png.jpg

 

 

 

관련자료

댓글 0
등록된 댓글이 없습니다.
Member Rank