> For the complete documentation index, see [llms.txt](https://mobidonia.gitbook.io/react-app-builder/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://mobidonia.gitbook.io/react-app-builder/server/run-app-producer-on-server.md).

# Run App producer on server

### Run the process NON Stop. - Server Environment <a href="#run-the-process-non-stop-server-environment" id="run-the-process-non-stop-server-environment"></a>

The Expo CLI can work on Window, Mac, and Linux.&#x20;

So it means that you can make apps from Linux Server.&#x20;

Together with [PM2](http://pm2.keymetrics.io/) you can have a server that never stops.

Let's start.

### Video

{% embed url="<https://www.loom.com/share/fe4b61e4dd6a43d8abb69869e9a15a53>" %}

#### Create Server  ( Example with CentOS 7 ) <a href="#create-server-and-install-webmin-example-with-centos-7" id="create-server-and-install-webmin-example-with-centos-7"></a>

**Step 1. Install Node, NPM, GIT, and EXPO**

1. **Install node and npm**: Read about it [here](https://tecadmin.net/install-nodejs-with-nvm/).
2. **Install GIT**: Read about it [here](https://www.digitalocean.com/community/tutorials/how-to-install-git-on-centos-7).
3. **Install Expo**: Follow [instructions](https://docs.expo.io/versions/latest/introduction/installation/).
4. **Install PM2**: Follow [instruction](http://pm2.keymetrics.io/).
5. Install mexpo-cli with the command `npm i -g mexpo-cli`
6. To make your VPS handle more operations  - Restart after that\
   `echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p` &#x20;

Full list of command

```
yum -y update

yum install -y gcc-c++ make

curl -sL https://rpm.nodesource.com/setup_12.x | sudo -E bash -                        
                                                                                                      
yes Y | sudo yum install nodejs -y                                                                                                                                                                                                                                                                    
                                                                                                      
yes Y | npm install -g --unsafe-perm --verbose expo-cli  -y      
                                                                                                      
yes Y | npm install pm2 -g   -y

yes Y | yum -y install git -y
                                                                                                      
yes Y | npm install -g --unsafe-perm --verbose mexpo-cli -y

echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

source ~/.bashrc   
```

To verify your installation run

* **`node --version`**
* **`npm --version`**
* **`git --version`**
* **`expo --version`**
* **`pm2 --version`**
* **`mexpo-cli --version`**

{% tabs %}
{% tab title="With our repository" %}

1. Clone or use our  repository in Git Lab. If you don't have access, send us your purchase code and we will add it.
2. Connect to your server via ssh
3. Clone the repository in your server
4. Use tools like `nano`  or `vi` Configure Mobile App/Producer/config.js with your own data. Email, smtp etc.
5. You should have also followed and completed the steps for the Local App producer. We need modified firebase\_config.js file and **service-account-file.json** file.&#x20;
6. Run **`npm install`**&#x20;
7. Run **`expo login`** and login with your account.
   {% endtab %}

{% tab title="With your repository" %}

1. Make sure you have configured Mobile App/Producer/config.js with your own data. Email, smtp etc.
2. You should have also followed and completed the steps for the Local App producer. We need modified firebase\_config.js file and services\_account json file.&#x20;
3. You will need to upload the code on some GIT platform like GitLab, GitHub or BitBucket. Initialize your local Mobile App folder.
4. Connect via SSH to your VPS
5. Clone the code from your repository.
6. Go inside your cloned code
7. Run **`npm install`**&#x20;
8. Run **`expo login`** and login with your account.
   {% endtab %}
   {% endtabs %}

Now. Run the production script with **`npm run pmserver`**

The server producer is now up and running.&#x20;


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://mobidonia.gitbook.io/react-app-builder/server/run-app-producer-on-server.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
