i currently have a running la ravel project,recently i did receive an order to make a web app for client so i made it using MEAN(mongodb,Express,Angular and Node). Unfortunately when i finished the web application the client asked for a demonstration on-line,due to huge difference in location(between me and the client) using my local development environment to showcase the working sample is not an option.i was inquiring if i could link a url from the laravel application to the node app without having to buy a domain
You can create a tunnel to your local environment by using ngrok
Follow this steps:
Download ngrok and unzip ngrok
Open a cmd / terminal and navigate to ngrok location
Type the following command:
ngrok http {your_localhost_server_port_number}
It will create the tunnel but we need to point a virtual host to it so edit your local virtual host and add an alias / server name like following:
NOTE: if you only have one app running on your local server this step is optional
*.ngrok.io
Now restart your local server to load our new configuration
Now you are able to see your localhost site online by using the ngrok provided url.
Enjoy!
Related
My organization blocks ngrok, so every time I run the Shopify serve command, it fails with a connection error.
So is there any way to just start the Shopify local server? that way I can use cloudfared to tunnel the local server to a subdomain.
When I search on google I found no answer to this question.
I had success running the server without the ngrok.
Here are my steps:
Prepare a cloud server, install Nginx.
config domain settings, and forward the request to your local port.
If you are using a router, only router has a public IP, so you need to forward the request to your pc. You could config it in the router.
then you need to update .env file, update host value
Go partner.shopify.com, app settings. put your URL to the whitelist.
use npm run dev to start your project.
I also set HTTPS in nginx. Due to ngrok server is far away from my location. so after using this way. the starting time is much faster.
Start the server by
npm run dev
instead of,
shopify app serve
I added my laravel project to docker as it appears in the first picture.
enter image description here
And I push my images to a repository in the docker hub as it appears in the second picture.
enter image description here
Now I want to run my application on another pc, I trying to pull my images but I don't know how to run the project in the browser.
Another question is there a way to test if the project will work on another pc from my pc something like a virtual machine.
If you want your project to be accessed globally then the easiest way is to use NGROK. It requires node>=10.19.0
Two simple steps to share your locally running app with others:
//Installing ngrok globally
npm install ngrok -g
//Expose a locally running application at port 8080 to the internet.
ngrok http 8000
If you want to share locally then both the PC's should be connected to the same network and you can just type the http://{IP address of PC running APP}:{PORT} to access the application.
To check the IP address use ifconfig command. Let's say it gives you 192.168.100.1, and the app is running on port 8000. To access the app on the other PC, you have to enter the following URL in the browser:
http://192.168.100.1:8000
I'm trying to figure out how to link my Apache2 server running on AWS Lightsail to an application I'm housing that uses http://localhost:3000 when activated—it's a simple Node.js based CMS called Vapid. I have the server linked to my domain name—bigsheepcollective.com—and I can get Vapid running through the AWS terminal, but it's only the Apache2 landing page that shows up on my domain name. I saw a tutorial here that goes over establishing a proxy pass on an Nginx ran server but I'm not sure how to do the same thing for one using Apache2.
I've tried using the Nginx tutorial and I've also don't some extensive searches into proxy setups for Apache2, but I'm confused about what type of proxy I need when it comes to running an application that uses http//:localhost:3000.
Hi Bitnami Engineer here.
You can include these lines in the /opt/bitnami/apache2/conf/bitnami/bitnami.conf file or in the specific .conf file you created for your application
ProxyPass / http://127.0.0.1:3000/
ProxyPassReverse / http://127.0.0.1:3000/
This way you will access your application when accessing the public IP of your instance or its associated domain.
This guide in our documentation explains the whole process to configure a Node.js application on top of Bitnami.
https://docs.bitnami.com/aws/infrastructure/mean/administration/create-custom-application-nodejs/
I'm running an app on Laravel Homestead. My OS is Windows 7. The hosts file:
192.168.10.10 myapp.dev
My PC uses the LAN Internet connection.
Now, I would like to be able to access myapp.dev on a mobile device.
I have tried this (1), as well as that (2). None of these worked for me. If I use the php artisan serve approach (link 1), my IPv4 gets rewritten to myapp.dev, and the site cannot be found.
How do I access my Homestead-based app on a phone?
Homestead 5.x
As of Homestead 5.x, ngrok software is included in your homestead environment. You can use the share myapp.dev command to fire off ngrok to listen for myapp.dev. Please refer to the Laravel Homestead documentation (Sharing Your Environment)
Homestead versions without ngrok included
You can change your nginx configuration file to listen on all requests and use your local IP http://yourip:8000 instead of myapp.dev, but the easiest way to archive this is by creating a secure tunnel to your machine with software like ngrok.com
With your local domain myapp.dev you can basically run the following command after you served your webserver:
ngrok http 192.168.10.10:80 -host-header=myapp.dev
ngrok will generate a secure url which is available on your local network, but also publicly so you can share it with your friends/colleagues.
source
Testing out Ghostlab on mobile presented an issue when the locally hosted page attempts to ping another locally hosted page via AJAX. Normally, GhostLab will rewrite the URL for you, but since it's an AJAX request I'm assuming it's not rewriting it because it's a dynamically generated URL.
Works fine on virtual machines and host machine with modified HOST file. Fails to load AJAX. The proxy server settings are very limited on GhostLab. Has anyone come across this issue and solved it?
The solution is to run another proxy server because you can't really modify the HOST file on iPhones or Androids without a huge headache.
I ended up using Charles Proxy. I remapped the locally hosted URL to which it was making the AJAX call to my local machine and it fixed everything. Here are the instructions:
1) Open Charles
2) (Menu)Tools/Map Remote...
Add the url you are local hosting to remap any traffic going through Charles Proxy to go to your machine See image example:
Do the same to any other subdomains or domains that are locally hosted on your machine and remap them too.
3) On your mobile device, open settings and select your local Wifi Network.
4) Change the proxy to your machine's IP address and relevant PORT.
5) Attempt to access the website and Grant permission via Charles.
This should fix it all.