Skip to content
This repository has been archived by the owner on Feb 21, 2022. It is now read-only.

Commit

Permalink
Update docs and examples about local setup
Browse files Browse the repository at this point in the history
Co-Authored-By: Pavel Dedik <[email protected]>
  • Loading branch information
Milan Lukac and paveldedik committed Oct 31, 2019
1 parent 2c6cce0 commit 87473e7
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 8 deletions.
30 changes: 24 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,14 @@ The Zoo also provides analytics about how dependency usage and its versions evol

## Development

### Initial setup

- Create a database: `$ make migrate`
- Create a superuser: `$ make superuser`
- Create `.env` file as documented below

### How to run

- Run in debug mode: `$ make run`
- Stop: `$ make stop`
- Stop and/or delete data: `$ make destroy`
Expand All @@ -41,11 +49,6 @@ Access web locally:
- Login at <http://localhost:20966/admin> with your superuser account
- Access zoo at <http://localhost:20966/>

### Initial setup

- Create a database: `$ make migrate`
- Create a superuser: `$ make superuser`

### Database changes

- Generate database migrations: `$ make makemigrations`
Expand All @@ -56,6 +59,21 @@ Access web locally:
Check `Makefile` for shell commands if you want to run them with modified
parameters.

### Local .env file

Creating a local `.env` file (see [Docker docs](https://docs.docker.com/compose/env-file/)
on `.env` files) is necessary for some components in the app to work correctly,
a basic example of such file contains the following:

```
ZOO_DEBUG=1
ZOO_GITHUB_TOKEN=...
ZOO_GITLAB_TOKEN=...
ZOO_GITLAB_URL=https://gitlab.com
```

Version control tokens only need read access to repositories.

## Testing

Run all tests: `$ make test`
Expand Down Expand Up @@ -99,4 +117,4 @@ Setup virtual enviroment and install there `docs-requirements.txt`. Then you can
use shortcuts:

- Build docs: `$ make build-docs`
- Open docs: `$ make read-docs`
- Open docs: `$ make open-docs`
4 changes: 2 additions & 2 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -55,13 +55,13 @@ Then you describe the errors with the following parameters:
namespace: py_security
category: Security Issues in Python Code
---
- id: user_input_improperly_handeled
- id: user_input_improperly_handled
severity: critical
effort: medium
title: Handle user input correctly
description: |
Applications with improperly handled user input become vulnerable to attacks like
command injection, SSRF, SQL injection, XSS, directory traveral etc.
command injection, SSRF, SQL injection, XSS, directory traversal etc.
[PyT](https://github.com/python-security/pyt) reported security vulnerabilities
in the following files:
Expand Down

0 comments on commit 87473e7

Please sign in to comment.