Read Me > Install
Make sure you removed previous executable:
sudo rm -f /usr/local/bin/rws #on macOS
sudo rm -f /usr/bin/rws #on Linux
Download precompiled binary for you platform from Google Drive.
You can always build rws binary from source.
sudo cp rws /usr/local/bin
sudo chmod 777 /usr/local/bin/rws
brew tap bohdaq/rust-web-server
brew install rws
sudo cp rws /usr/bin
sudo chmod ug+rwx,o+r /usr/bin/rws
sudo dpkg -i --force-overwrite rws.deb
Replace VERSION with version you downloaded.
sudo rpm -i --force rws-VERSION.rpm
Open Rust Web Server Portage ebuild for details.
Open Rust Web Server Pacman package for details.
Copy executable to C:\WINDOWS\system32 folder.
sudo cp rws /usr/bin
sudo chmod ug+rwx,o+r /usr/bin/rws
sudo dpkg -i --force-overwrite rws.deb
To check installation execute the following code in the terminal:
$ rws
You will see similar output:
Rust Web Server
Version: YOUR_VERSION
Authors: Bohdan Tsap [email protected]
Repository: https://github.com/bohdaq/rust-web-server
Desciption: rust-web-server (rws) is a static content web-server written in Rust
Rust Version: RUST_VERSION
... Hello, rust-web-server is up and running: http://127.0.0.1:7878
Open browser, go to http://127.0.0.1:7878, you'll see default page.
Go back to terminal, press Ctrl + C (or CMD + C) to stop server.