FlyServe is a simple web server written in Go, designed to serve files and directories over HTTP. It provides features such as serving specific files, serving directories, basic authentication, and directory listings.
- Serve specific files
- Serve directories with directory listings
- Basic authentication support
- Customizable port number
- Single binary, no external dependencies
-
Download the binary with wget:
wget https://github.com/JCoupalK/FlyServe/releases/download/1.0/flyserve_linux_amd64_1.0.tar.gz
-
Unpack it with tar
tar -xf flyserve_linux_amd64_1.0.tar.gz
-
Move it to your /usr/local/bin/ (Optional):
sudo mv flyserve /usr/local/bin/flyserve
-
Ensure you have Go installed on your system. You can download Go from here.
-
Clone the repository:
git clone https://github.com/JCoupalK/FlyServe
-
Navigate to the cloned directory:
cd FlyServe
-
Build the tool:
go build -o flyserve .
Options:
-p, --port Port to serve on (Default is 8080)
-f, --file Specific file to serve
-d, --directory Directory to serve files from (Default is current directory)
-u, --username Username for basic authentication
-pw, --password Password for basic authentication
# Serve files from the current directory on port 8080
flyserve
# Serve files from a specific directory on port 9000
flyserve -d /path/to/directory -p 9000
# Serve a specific file on port 8080 with basic authentication
flyserve -f /path/to/file.txt -u username -pw password
# Serve websites by just specifying a directory that contains an index.html
flyserve -d /path/to/website -p 80
![screenshot1](https://private-user-images.githubusercontent.com/108779415/303942629-74c10791-62d5-4e68-988a-62dfba2965ff.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjYwODkzNzMsIm5iZiI6MTcyNjA4OTA3MywicGF0aCI6Ii8xMDg3Nzk0MTUvMzAzOTQyNjI5LTc0YzEwNzkxLTYyZDUtNGU2OC05ODhhLTYyZGZiYTI5NjVmZi5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwOTExJTJGdXMtZW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MCJ9.JOmPtZ7CEhq6xoWfSrUhksamiYTau_XMVM-ojiTybLg)
![screenshot3](https://private-user-images.githubusercontent.com/108779415/303943348-da666e86-ae02-4c25-8fe7-cb5f9f8f04c0.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjYwODkzNzMsIm5iZiI6MTcyNjA4OTA3MywicGF0aCI6Ii8xMDg3Nzk0MTUvMzAzOTQzMzQ4LWRhNjY2ZTg2LWFlMDItNGMyNS04ZmU3LWNiNWY5ZjhmMDRjMC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQwOTExJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MDkxMVQyMTExMTNaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0zN2FlMTlmMjA3ZGQ5Y2EyNjI4YTZlMTg2ODdjMzBkODZjZjZlOTYyYmU3NmE4ODA2NjNjZWEwNDc1M2MwZjg4JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCZhY3Rvcl9pZD0wJmtleV9pZD0wJnJlcG9faWQ9MCJ9.yCrBIPdjplIarOjEcwaJsH9EVDpZxN6wz4Z_Qwfyc-A)
Contributions are welcome. If you find a bug or have a feature request, please open an issue or submit a pull request.
This project is licensed under the MIT License - see the LICENSE file for details.