Skip to content

Commit

Permalink
Update Readme (#14)
Browse files Browse the repository at this point in the history
* docs:readme

* docs:readme
  • Loading branch information
nsavinda authored Jun 22, 2024
1 parent db36635 commit dda1946
Show file tree
Hide file tree
Showing 2 changed files with 61 additions and 1 deletion.
60 changes: 60 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,64 @@

This is a simple HTTPS server that serves a static files from a directory.

## Setup

Download the binary from the [releases](https://github.com/Elixir-Craft/servefiles/releases) page or build it from source.

```bash
git clone https://github.com/Elixir-Craft/servefiles.git
cd servefiles
```

Build the binary
```bash
go build -o ./build ./servefiles
```

Run the binary or copy it to your bin directory to run it from anywhere.

Run
```bash
./build/servefiles
```

Copy binary to bin directory (Linux)

```bash
cp ./build/servefiles /usr/local/bin
```

## Usage

Change port
```bash
servefiles -p 8080
```

Regenerate certificate
```bash
servefiles -r
```

Set password
```bash
servefiles -P password
```

To set configuration file for certificate, create a file named `config.yaml` in the servefile configuration directory.
on Linux, the configuration directory is `~/.ServeFiles/`

```yaml
cert:
organization: "Your Company Name"
country: "Your Country"
province: "Your Province"
locality: "Your City"
street_address: "Your Street Address"
postal_code: "Your Postal Code"
```
## Development
Run
Expand All @@ -15,3 +73,5 @@ or
air
```



2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.0
1.1

0 comments on commit dda1946

Please sign in to comment.