Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mehmetumit/dexus
Dynamic extensible URL shortener
https://github.com/mehmetumit/dexus
caching ci-cd dynamic extensible go go-http-middleware makefile mocking ports-and-adapters-pattern shell-script url-shortener
Last synced: 23 days ago
JSON representation
Dynamic extensible URL shortener
- Host: GitHub
- URL: https://github.com/mehmetumit/dexus
- Owner: mehmetumit
- License: gpl-3.0
- Created: 2023-10-29T20:44:57.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2023-11-07T20:05:31.000Z (about 1 year ago)
- Last Synced: 2024-05-02T03:11:11.785Z (6 months ago)
- Topics: caching, ci-cd, dynamic, extensible, go, go-http-middleware, makefile, mocking, ports-and-adapters-pattern, shell-script, url-shortener
- Language: Go
- Homepage:
- Size: 52.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
dexus
---
## About
Dexus is a URL shortener that provides you with the ability to extend it dynamically according to your needs. You can utilize existing [adapters](./internal/adapters) or implement your own adapters based on [ports](./internal/core/ports). Afterwards, you only need to inject these adapters in [cmd/main.go](./cmd/main.go). Contributions of any new adapters are welcome.
## Usage
### Using binary release
Precompiled binaries are available on the [relases](https://github.com/mehmetumit/dexus/releases) page.
### Local Usage
```sh
# Clone the repository
git clone https://github.com/mehmetumit/dexus.git
# Change directory
cd dexus
# Build and run with make
make exec
# Or just build as "./build/dexus"
make build
```
### Using Docker
```sh
# Clone the repository
git clone https://github.com/mehmetumit/dexus.git
# Change directory
cd dexus
# Build image with make
make docker-build
# Run image with make
make docker-run
# Or manually
docker run -p 8080:8080 dexus:latest
```
### Development
```sh
# Live reload using 'entr'
make live-reload
```
```sh
# Run tests and get coverage
make test
```
```sh
# Run tests and get coverage with html output
make test-coverage-html
```
## Configuration| Env Vars | Default Values |
|----------------------|----------------------------|
| `DEBUG_LEVEL` | `true` |
| `HOST` | `all interfaces` |
| `PORT` | `8080` |
| `READ_TIMEOUT_MS` | `1000 ms` |
| `WRITE_TIMEOUT_MS` | `1000 ms` |
| `CACHE_TTL_SEC` | `60 s` |
| `YAML_REDIRECT_PATH` | `configs/redirection.yaml` |## Contributing
Greatly appreciate contributions from the community. Your input, whether it's through code, documentation, bug reports, or suggestions, helps improve this project and make it even better.
## License
This project is licensed under the [GPLv3](./LICENSE) License.