Server
Client
- clone the repository
git clone https://github.com/ayoub-g/transfert-files.git
- cd to the server folder
cd transfert-files/server
- install npm dependencies
npm install
- update destination directories in the file config.json
{
"_comment": "update destination directories here",
"storage": {
"volume": "/Volumes/drive/media",
"imagesPath": "/images",
"videosPath": "/videos"
}
}
- Now we have to configure the UI so we can upload files from another device to the server
The project comes with the pre-built angular UI in the public folder, to be able to upload files from another device/desktop, we have to setup the server IP. To do this without rebuilding the angular project, I have externalized the IP configuration in the file public/assets/config.json. update it to the address of the server
cd ..
{
"_comment_": "update server ip here",
"server": "http://192.168.x.x:3000"
}
- run the server
npm start
-
finally open a new tab at http://localhost:3000 from the server, or http://192.168.x.x:3000 from your device
-
continue if you want to update the UI or rebuild it
cd frontend
- install npm dependencies
npm install
- in the dev mode, if you want to change the server port, go to the proxy.conf.json file
{
"/server": {
"target": "http://localhost:3000"
}
}
- run the project
npm start
- open a new tab at http://localhost:4200
Project icon