GitHub link :https://github.com/Catherine9898/5007-Tutorial6.git
docker pull ubuntu
docker run -p 3000:3000 -p 5000:5000 -dit ubuntu
apt update
apt install curl
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash
nvm install 10
npm install -g npm@6
apt install gnupg
apt install curl
curl -fsSL https://www.mongodb.org/static/pgp/server-4.4.asc | apt-key add -
echo "deb [ arch=amd64,arm64 ] https://repo.mongodb.org/apt/ubuntu bionic/mongodb-org/4.4 multiverse" | tee /etc/apt/sources.list.d/mongodb-org-4.4.list
apt update
apt install mongodb-org
apt install screen
mkdir -p /data/db
screen mongod
clone from my git repository
git clone https://github.com/Catherine9898/5007-Tutorial6.git
Run in the "frontend" folder I uploaded on the Luminus. You can run it under the "frontend" file using commands:
react-native run-android
Use the files on GitHub you need to
- create react-native project at your own side
- copy the files I provided to your project
- install the dependencies and run
const client = new ApolloClient({ uri: 'http://192.156.1.1:5000/graphql' });
-
Both name and phone number should be filled in.
-
The phone number should only have numbers.
-
Cannot add an appointment that already exists in the database.
cd backend
npm install
screen mongod
Press Ctrl+a followed by d to return to terminal
mongo issuetracker scripts/init.mongo.js
screen npm start
Press Ctrl+a followed by d to return to terminal
If you use the frontend folder I uploaded on Luminus, just open the frontend folder in your windows command prompt terminal and run the following command.
react-native run-android
If you pull and use the frontend folder from my GitHub.
npx react-native init SampleApp
step2. Enter the "SampleApp" folder, and copy the files you download in folder "frontend" to "SampleApp".
step3. Open folder "SampleApp" in your windows command prompt terminal, and run the following to start.
npm install
react-native run-android
query{issueList{id, name, phone, time}}