Can I use AWS as tunnel when connecting my local development server to Shopify?

Can I use AWS as tunnel when connecting my local development server to Shopify?

aih_kimg
Shopify Partner
14 0 3

Can I use AWS as tunnel when connecting my local development server to Shopify?
Cloudflare and ngrok are blocked due to company policies. 
I can't use other tunnels such as expose.dev either due to security policies.
I was told to check if AWS EC2 if possible but I can't seem to find any resources on how to do that.

Replies 5 (5)

Eric-HAN
Shopify Partner
297 30 32

Yeah, of course 
This is feasible. you could run your app on the EC2  and make that endpoint to the app_url.

- Helpful? Please hit Like and mark it as a solution
Want to modify or custom changes on store? Let me help.
- Feel free to Email Me    Buy Me A Coffee
aih_kimg
Shopify Partner
14 0 3

@Eric-HAN 

 

Thank you for your reply.
Do you have a guide on how to do so? I am new to Shopify and resources seems difficult to find in one place.

 

Eric-HAN
Shopify Partner
297 30 32

1. Ensure Your App Is Running on AWS EC2
First, confirm that your app is started and running on your AWS EC2 instance. If it is, you’ll need to navigate to the AWS Management Console to obtain your app’s endpoint (e.g., a public IP address or domain name).
2. Configure Shopify Partner Settings with AWS Endpoint
Next, update your Shopify app’s configuration in the Shopify Partner Dashboard by setting the following URLs to your AWS EC2 endpoint:app_url: The base URL of your app (e.g., http://your-ec2-ip:3000).
redirect_url: The URL where Shopify will redirect users after authentication (e.g., http://your-ec2-ip:3000/auth/shopify/callback).

Make sure these URLs match the endpoint you retrieved from AWS and include the correct port (if applicable).

- Helpful? Please hit Like and mark it as a solution
Want to modify or custom changes on store? Let me help.
- Feel free to Email Me    Buy Me A Coffee
aih_kimg
Shopify Partner
14 0 3

Hi @Eric-HAN ,

I can't seem to work this properly. Please see what I did so far:

Question: How to use and properly configure AWS EC2 as my tunnel in connecting my local development to Shopify?

STEPS DONE:

AWS Side:

  1. Create an EC2 instance.
  2. Get the public IP
  3. Set inbound rule to accept incoming traffic (port: 22 and port 3458 the same as my localhost port when using “shopify app dev –use-localhost)
  4. Make sure that my EC2 instance is running.

aih_kimg_12-1747878751951.png

 

 

 

 

Shopify Side:

  1. Set the app URL to my EC2 instance:

        aih_kimg_7-1747878661948.png

 

 

  1. Use Shopify CLI “shopify app dev --tunnel-url https://my-custom-tunnel.io:PORT”aih_kimg_8-1747878661950.png

 

 

  1. But per opening the preview page, I get this error:
    aih_kimg_9-1747878661952.png

    What I wanted to see is this kind of page when I use localhost:

           aih_kimg_10-1747878661954.png

 

I think I'm missing a very crucial step/configuration. What could it be?

Thank you.

 

Eric-HAN
Shopify Partner
297 30 32

Hi , there 
You need to configure a domain name and SSL certificate for your EC2 instance, then set them in your Shopify Partner configuration.

- Helpful? Please hit Like and mark it as a solution
Want to modify or custom changes on store? Let me help.
- Feel free to Email Me    Buy Me A Coffee