Create Magento App
Create ScandiPWA AppScandiPWA DocsGitHub
v1
v1
  • Create Magento App
  • Getting started
    • Getting Started
    • Prerequisites
      • Linux requirements
      • MacOS requirements
        • Apple Silicon
      • Windows requirements
    • Available commands
      • Start the application
      • Stop the application
      • Check application status
      • Enter application CLI
      • Explore application logs
      • Execute commands in Docker containers
      • Link a theme
      • Import database dump
      • ⚠️ Uninstall a project
    • Folder structure
    • Updating to New Releases
      • Testing Alpha Releases
    • Configuration File
    • Supported Magento versions
    • How does it work?
    • Limitations
  • Usage guide
    • Using console commands
    • Accessing Docker containers
    • Linking a Scandi Theme
    • Enabling XDebug
    • Enabling SSL
    • Configuring PHP
    • Use custom domain
    • Access on the local network
    • Importing database
      • Importing remote database
    • Using Enterprise Edition
    • Converting legacy Docker setup to CMA
    • Improve Performance
  • Scripts Extensions
    • PHP Extensions
      • ionCube Extension
  • Troubleshooting
    • Common Issues
    • CMA Debugging
    • Uninstall CMA
Powered by GitBook
On this page
  • 1. Get an IP address
  • 2. Make port public
  • Linux
  • MacOS
  • 3. Setup CMA
  1. Usage guide

Access on the local network

PreviousUse custom domainNextImporting database

Last updated 2 years ago

Sometimes you need to run your CMA application in a mode where other users can access it to look at the development progress.

1. Get an IP address

Every device that is connected to the local is assigned an IP address in that network. Usually, this is done by the router. To get your IP address on the local network, use the following guide:

ifconfig -a
ip -4 addr | grep 192.168
ipconfig getifaddr en0
> 192.168.0.xxx

2. Make port public

Each OS has a different approach to opening ports in its firewall.

Linux

We will be using to control iptables rules.

# install it
sudo apt-get install ufw

# enable service
sudo ufw enable

# make sure that it is running
sudo ufw status verbose

# open port
sudo ufw allow in 80/tcp

# now we have port 80 available outside of our system
# install it
pamac install ufw

# enable service
sudo systemctl enable ufw.service
sudo ufw enable

# open port
sudo ufw allow in 80/tcp

# now we have port 80 available outside of our system

MacOS

Go to System Preferences > Security & Privacy > Firewall. Enable firewall. Then go to Firewall Options and make sure the only two options selected are Automatically allow built-in software to receive incoming connections and Automatically allow downloaded signed software to receive incoming connections.

3. Setup CMA

Add to your cma.js file field host with your IP address:

module.export = {
    ... other configuration
    host: '192.168.0.100'
}

That is it! Now your devices on the local network can communicate with your CMA instance!

You also need to apply changes by running the command without .

UFW
start
-s option