In a lot of cases, especially when working with other people, or when developing integrations with online services, we have to make our computer accessible from the World Wide Web. This information could be obtained from our trusty router. But wouldn't it be easier if you just had a tool that makes our computer report publicly available? Luckily for us, there is such a tool, meet and grok the versatile one line command that makes you forget about router configuration and continuous redeploys. And grok is a simple tool that exposes a port from our computer to a unique domain name publicly available on the internet. How does it do it?
Well, let's see it in action. Go to the website, click on the download button and choose your destiny. In our case, our destiny is the Linux package in 64 bit that's Go to the terminal, unzip the file, and copied the contents to the bin folder. Now to rehash and type, and grok HTTP, we can see that port forwarding for Port 80 and 443 is running on our local at Port as a custom and grog sub domain name. We can also see the region of the server which by default is located in the US. If you are in a different region, we can set this with an grok HTTP 80 dash dash region yield.
And now we can see that the N grok server is located in Europe. In order to test our n grok. Server. Let's use our trusty Python server to show a simple HTML page. For this, issue the command in the screen then restart an grok with the HTTP traffic forwarded from Port 8000. The default Python web server Now click on the link provided by an grok.
And we will see our web page accessible to the World Wide Web. That's it. No configuration, no account, no headaches, just a simple one line command that we can run from anywhere. The subdomain provided by an grok is a generated one and will change every time we restart an grok. We have the option of using our custom domain name like Linux dot n grok.com, but only after acquiring a paid account. And rock also has a web interface at our localhost Port 4004 where we can see statistics and logs.
Power comes from ease of use, and N grok provides us with that power. Here are some specific scenarios for using this powerful tool. When testing integrations with online services that require a callback URL, like oh, I was logging and online payments when developing mobile applications that connect to a local service when we want to expose an SSH port, when we want to give our clients access to a web page on our laptop to show them some code, maybe enjoy