{"id":27959116,"url":"https://github.com/builderhub-platform/localtunnel","last_synced_at":"2025-05-07T18:28:37.946Z","repository":{"id":171729281,"uuid":"648334358","full_name":"builderhub-platform/localtunnel","owner":"builderhub-platform","description":"Expose localhost to the world for BuilderHub Platform Dev","archived":false,"fork":false,"pushed_at":"2025-04-24T06:31:39.000Z","size":735,"stargazers_count":0,"open_issues_count":14,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-24T07:39:35.702Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/@builderhub/localtunnel","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/builderhub-platform.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-06-01T18:23:12.000Z","updated_at":"2024-12-10T19:37:06.000Z","dependencies_parsed_at":"2024-02-05T16:31:44.886Z","dependency_job_id":"b473a7a4-43fd-4f0a-a42e-f54ae58afa2e","html_url":"https://github.com/builderhub-platform/localtunnel","commit_stats":null,"previous_names":["builderhub-platform/localtunnel"],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/builderhub-platform%2Flocaltunnel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/builderhub-platform%2Flocaltunnel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/builderhub-platform%2Flocaltunnel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/builderhub-platform%2Flocaltunnel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/builderhub-platform","download_url":"https://codeload.github.com/builderhub-platform/localtunnel/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252933369,"owners_count":21827499,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-05-07T18:28:37.440Z","updated_at":"2025-05-07T18:28:37.933Z","avatar_url":"https://github.com/builderhub-platform.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @builderhub/localtunnel\n\n[![Publish Package to npmjs](https://github.com/builderhub-platform/localtunnel/actions/workflows/publish.yml/badge.svg)](https://github.com/builderhub-platform/localtunnel/actions/workflows/publish.yml) ![npm](https://img.shields.io/npm/dw/@builderhub%2Flocaltunnel) ![npm](https://img.shields.io/npm/v/@builderhub/localtunnel?color=%2357C754\u0026label=npm%20version) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n\n`@builderhub/localtunnel`은 로컬호스트를 전 세계에 노출하여 편리한 테스트 및 공유를 제공합니다! DNS를 건드리거나 배포할 필요 없이 로컬 변경 사항을 테스트할 수 있습니다.\n\n원본은 [localtunnel](https://github.com/localtunnel/localtunnel)이지만 오랜기간 유지관리가 되지 않아 TypeScript로 재구성했습니다.\n\n- [browserling](https://www.browserling.com/)과 같은 브라우저 테스트 도구나 [twilio](https://www.twilio.com)와 같은 외부 API 콜백 서비스와 함께 사용하기에 좋습니다. 이러한 서비스는 콜백을 위해 공개 URL을 요구합니다. 콜백 URL를 테스트를 할 수 있습니다.\n- 각종 MSA를 로컬에서 터널로 구성하여 배포 된 것과 비슷한 SSL 환경에서 테스트해 볼 수 있습니다. 환경변수 `.env.tunnel` 방식으로 모든 MSA를 원하는 DNS로 테스트 합니다.\n\n## Getting started\n\n```\nnpx @builderhub/localtunnel --port 8000\n```\n\n## Installation\n\n### Globally\n\n```\nnpm install -g @builderhub/localtunnel\n```\n\n### As a dependency in your project\n\n```\nyarn add @builderhub/localtunnel\n```\n\n## CLI usage\n\nlocaltunnel이 전역으로 설치된 경우 `lt` 명령을 사용하여 터널을 시작하세요.\n\n```\nlt --port 8000\n```\n\n실행하면 터널 서버에 연결하고 터널을 설정하며, 테스트에 사용할 URL을 알려줍니다. 이 URL은 세션이 유지되는 동안 활성 상태를 유지하므로, 이 시간동안 다른 사람과 공유하는 것이 가능합니다.\n\n로컬 서버를 원하는 만큼 재시작할 수 있으며, `lt`는 이를 감지하고 다시 연결합니다\n\n### Arguments\n\n다음은 몇 가지 일반적인 argument 입니다. 추가 argument에 대해서는 `lt --help`를 참조하세요.\n\n- `--subdomain` request a named subdomain on the localtunnel server (default is random characters)\n- `--local-host` proxy to a hostname other than localhost\n\n`env` 변수를 통해 argument를 지정할 수도 있습니다.\n\n```\nPORT=3000 lt\n```\n\n## API\n\n`localtunnel` 클라이언트는 API를 통해서도 사용할 수 있습니다(테스트 통합, 자동화 등).\n\n### localtunnel(port [,options][,callback])\n\n지정된 로컬 `port`에 대한 새 로컬 터널을 만듭니다. 공개 localtunnel URL이 할당되면 해결되는 Promise를 반환합니다. `options`을 사용하여 특정 `subdomain`을 요청할 수 있습니다. `callback` 함수가 전달될 수 있으며, 이 경우 `Promise`를 반환하지 않습니다. 이전 노드 스타일 콜백 API와의 하위 호환성을 위해 존재합니다. 속성으로 `port`가 있는 단일 옵션 개체를 전달할 수도 있습니다.\n\n```ts\nimport { localtunnel } from \"@builderhub/localtunnel\";\n\n(async () =\u003e {\n  const tunnel = await localtunnel({ port: 3000 });\n\n  // the assigned public url for your tunnel\n  // i.e. https://abcdefgjhij.tunnel.builderhub.io\n  tunnel.url;\n\n  tunnel.on(\"close\", () =\u003e {\n    // tunnels are closed\n  });\n})();\n```\n\n#### options\n\n- `port` (number) [required] The local port number to expose through localtunnel.\n- `subdomain` (string) Request a specific subdomain on the proxy server. **Note** You may not actually receive this name depending on availability.\n- `host` (string) URL for the upstream proxy server. Defaults to `https://tunnel.builderhub.io`.\n- `local_host` (string) Proxy to this hostname instead of `localhost`. This will also cause the `Host` header to be re-written to this value in proxied requests.\n- `local_https` (boolean) Enable tunneling to local HTTPS server.\n- `local_cert` (string) Path to certificate PEM file for local HTTPS server.\n- `local_key` (string) Path to certificate key file for local HTTPS server.\n- `local_ca` (string) Path to certificate authority file for self-signed certificates.\n- `allow_invalid_cert` (boolean) Disable certificate checks for your local HTTPS server (ignore cert/key/ca options).\n\n자세한 인증서 옵션은 [tls.createSecureContext](https://nodejs.org/api/tls.html#tls_tls_createsecurecontext_options)을 참조하세요.\n\n### Tunnel\n\n콜백에 반환된 `tunnel` 인스턴스는 다음 이벤트를 내보냅니다.\n\n| event   | args | description                                                                          |\n| ------- | ---- | ------------------------------------------------------------------------------------ |\n| request | info | fires when a request is processed by the tunnel, contains _method_ and _path_ fields |\n| error   | err  | fires when an error happens on the tunnel                                            |\n| close   |      | fires when the tunnel has closed                                                     |\n\n`tunnel` 인스턴스에는 다음과 같은 메서드가 있습니다.\n\n| method | args | description      |\n| ------ | ---- | ---------------- |\n| close  |      | close the tunnel |\n\n## Slack integration\n\n하위 도메인을 여러 개발자가 함께 사용할 경우 충돌이 발생하여 나중에 터널을 요청하게 되면 랜덤한 하위 도메인을 제공합니다.\n\n빌더허브 플랫폼 개발팀은 예약된 7개의 하위 도메인을 모니터링 합니다. 개발자는 Slack의 Tunnel Status 앱으로 확인한 후 터널 환경에서의 앱 테스트가 가능합니다.\n\n![slack](docs/slack.png)\n\n## Related repo\n\n- Reverse Proxy Server: \u003chttps://github.com/builderhub-platform/builderhub-tunnel\u003e\n- Monitoring: \u003chttps://github.com/builderhub-platform/builderhub-tunnel-status\u003e\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbuilderhub-platform%2Flocaltunnel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbuilderhub-platform%2Flocaltunnel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbuilderhub-platform%2Flocaltunnel/lists"}