Sanic Plugin to log access logs in common or combined format
## How to use
```python
from sanic import Sanic
from sanic.response import json
from sanic_apache_accesslogs import AccessLogPlugin
app = Sanic(__name__, configure_logging=False)
AccessLogPlugin(app)
@app.route('/', methods=['GET'])
async def hello(request):
return json({'hello': 'world'})
if __name__ == '__main__':
app.run(host='localhost', port=5000, access_log=False)
```
## Common or Combined?
For choosing the format set the environment variable `ACCESSLOG_USE_COMBINED` to choose combined over common.
## TODO(s)
* Use Sanic configuration context to choose between the logging format.
## Contact
Arnulfo Solis
arnulfojr94@gmail.com
Metadata
Release files for sanic_apache_accesslogs 0.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| sanic_apache_accesslogs-0.2.1.tar.gz | 4.6 kB | Without provenance | Details for sanic_apache_accesslogs-0.2.1.tar.gz |
Release files / sanic_apache_accesslogs-0.2.1.tar.gz
| Download URL | sanic_apache_accesslogs-0.2.1.tar.gz |
|---|---|
| Size | 4.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2ab7d4ceea54dda959d8503d96b415635e06e9d6aaf75c0ff3f3ee02af19d8cc
|
|
BLAKE2b-256 checksum How to use checksums |
a0864638cb03aeec6f6c8c87d887e00539b7cef245044858054b86c1bd4021d3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for sanic_apache_accesslogs 0.2.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.