mirror of
https://github.com/Maronato/go-finger.git
synced 2025-03-15 00:34:47 +00:00
readme and makefile updates
This commit is contained in:
parent
7623b16f5a
commit
e2ea9cd975
2 changed files with 42 additions and 21 deletions
2
Makefile
2
Makefile
|
@ -9,7 +9,7 @@ build:
|
|||
test:
|
||||
go test -v ./...
|
||||
|
||||
serve:
|
||||
run:
|
||||
go run main.go serve
|
||||
|
||||
clean:
|
||||
|
|
59
README.md
59
README.md
|
@ -85,15 +85,14 @@ https://example.com/user/charlie:
|
|||
"rel": "openid",
|
||||
"href": "https://sso.example.com/"
|
||||
},
|
||||
{
|
||||
"rel": "name",
|
||||
"href": "Alice Doe"
|
||||
},
|
||||
{
|
||||
"rel": "http://webfinger.net/rel/profile-page",
|
||||
"href": "https://example.com/user/alice"
|
||||
}
|
||||
]
|
||||
],
|
||||
"properties": {
|
||||
"name": "Alice Doe"
|
||||
}
|
||||
}
|
||||
```
|
||||
</details>
|
||||
|
@ -107,14 +106,13 @@ https://example.com/user/charlie:
|
|||
"subject": "acct:bob@example.com",
|
||||
"links": [
|
||||
{
|
||||
"rel": "name",
|
||||
"href": "Bob Foo"
|
||||
},
|
||||
{
|
||||
"rel": "openid",
|
||||
"rel": "http://openid.net/specs/connect/1.0/issuer",
|
||||
"href": "https://sso.example.com/"
|
||||
}
|
||||
]
|
||||
],
|
||||
"properties": {
|
||||
"http://schema.org/name": "Bob Foo"
|
||||
}
|
||||
}
|
||||
```
|
||||
</details>
|
||||
|
@ -128,21 +126,44 @@ https://example.com/user/charlie:
|
|||
"subject": "https://example.com/user/charlie",
|
||||
"links": [
|
||||
{
|
||||
"rel": "name",
|
||||
"href": "Charlie Baz"
|
||||
},
|
||||
{
|
||||
"rel": "profile",
|
||||
"rel": "http://webfinger.net/rel/profile-page",
|
||||
"href": "https://example.com/user/charlie"
|
||||
}
|
||||
]
|
||||
],
|
||||
"properties": {
|
||||
"http://schema.org/name": "Charlie Baz"
|
||||
}
|
||||
}
|
||||
```
|
||||
</details>
|
||||
|
||||
## Commands
|
||||
|
||||
Finger exposes two commands: `serve` and `healthcheck`. `serve` is the default command and starts the server. `healthcheck` is used by the Docker healthcheck to check if the server is up.
|
||||
|
||||
## Configs
|
||||
Here are the config options available. You can change them via command line flags or environment variables:
|
||||
|
||||
| CLI flag | Env variable | Default | Description |
|
||||
| -------- | ------------ | ------- | ----------- |
|
||||
| fdsfds | gsfgfs | fgfsdgf | gdfsgdf |
|
||||
| ------------------- | ---------------- | -------------------------------------- | -------------------------------------- |
|
||||
| `-p, --port` | `WF_PORT` | `8080` | Port where the server listens to |
|
||||
| `-h, --host` | `WF_HOST` | `localhost` (`0.0.0.0` when in Docker) | Host where the server listens to |
|
||||
| `-f, --finger-file` | `WF_FINGER_FILE` | `fingers.yml` | Path to the webfingers definition file |
|
||||
| `-u, --urn-file` | `WF_URN_FILE` | `urns.yml` | Path to the URNs alias file |
|
||||
| `-d, --debug` | `WF_DEBUG` | `false` | Enable debug logging |
|
||||
|
||||
## Development
|
||||
|
||||
You need to have [Go](https://golang.org/) installed to build the project.
|
||||
|
||||
Clone the repo and run `make build` to build the binary. You can then run `./finger serve` to start the server.
|
||||
|
||||
A few other commands are:
|
||||
- `make run` to run the server
|
||||
- `make test` to run the tests
|
||||
- `make lint` to run the linter
|
||||
- `make clean` to clean the build files
|
||||
|
||||
## License
|
||||
|
||||
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
|
||||
|
|
Loading…
Add table
Reference in a new issue