-
-
Notifications
You must be signed in to change notification settings - Fork 218
Run Mobile App
To run the mobile app, create ./mobile/.env
file with the following content:
BC_API_HOST=https://bookcars.com:4002
BC_DEFAULT_LANGUAGE=en
BC_PAGE_SIZE=20
BC_CARS_PAGE_SIZE=8
BC_BOOKINGS_PAGE_SIZE=8
BC_CDN_USERS=https://bookcars.com/cdn/bookcars/users
BC_CDN_CARS=https://bookcars.com/cdn/bookcars/cars
BC_COMAPANY_IMAGE_WIDTH=60
BC_COMAPANY_IMAGE_HEIGHT=30
BC_CAR_IMAGE_WIDTH=300
BC_CAR_IMAGE_HEIGHT=200
BC_APP_TYPE=frontend
BC_MINIMUM_AGE=21
Set the following options:
BC_API_HOST=https://bookcars.com:4002
BC_CDN_USERS=https://bookcars.com/cdn/bookcars/users
BC_CDN_CARS=https://bookcars.com/cdn/bookcars/cars
Replace https://bookcars.com
with an IP, hostname or FQDN.
Install the demo database by following these instructions.
Configure http://localhost/cdn
- On Windows, install IIS and create C:\inetpub\wwwroot\cdn\bookcars folder.
- On Linux, install NGINX and add cdn folder by changing /etc/nginx/sites-available/default as follows:
server {
listen 80 default_server;
server_name _;
...
location /cdn {
alias /var/www/cdn;
}
}
Configure ./api
by following these instructions.
Run ./api
with the following command:
cd ./api
npm run dev
Run the mobile app by simply installing Expo app on your device from App Store/Play Store and running the following commands from ./mobile
folder:
cd ./mobile
yarn install
yarn start
Open Expo app on your device and scan the QR code to run BookCars mobile app.
If you want to enable BookCars push notifications, Download google-services.json file and place it in ./mobile
root directory for push notifications. Its path can be configured from ./mobile/app.json
configuration file through googleServicesFile
setting option.
Copyright © 2024 Akram El Assas. All rights reserved.