Commit 810187c4 authored by Thor-Herman's avatar Thor-Herman
Browse files

Add urls as variables #15

parent f65242e4
......@@ -5,13 +5,14 @@ import Constants from "expo-constants";
const { manifest } = Constants;
// This gets the IP address of the host for Expo client. Makes you connect to the IP address of the machine on LAN
const url = `http://${manifest.debuggerHost.split(':').shift()}:8000`;
const Localurl = `http://${manifest.debuggerHost.split(':').shift()}:8000`;
const VMUrl = 'http://it2810-75.idi.ntnu.no:8000';
const prod = { // The VM backend
url: 'http://it2810-75.idi.ntnu.no:8000',
url: VMUrl,
};
const dev = { // Local backend
url,
url: Localurl, // If trying the server locally. Change to Localurl.
};
export const config = process.env.NODE_ENV === 'development' ? dev : prod;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment