constructor-threagil
CI/CD | |
Paquete | |
Meta |
Abasado en bloquesaplicación web sin código para crearamenazanteArchivos YAML
Resumen ejecutivo
Cómo poner en marcha su código en su propio sistema.
Nota: Asegúrese de cumplir con losrequisitos.
-
Proceso de instalación:
$ cd threagile-builder $ hatch --version # optional, will print the version of our package to the terminal without modifying the source directory (e.g. `0.0.1`). # Without hatch: $ python src/threagile_builder/app.py $ hatch env create # optional, if the default env already exists you will be told $ hatch shell # spawn a shell within an environment (threagile-builder) $ pip show threagile-builder # optional, shows the project details, here 'threagile-builder', from `pyproject.toml` # Name: threagile-builder # Version: 0.0.1 # it takes this from src/threagile_builder/__about__.py # ... (threagile-builder) $ python -c "import sys;print(sys.executable)" # optional, see where your environment's python is located (threagile-builder) $ pip install --upgrade pip # optional, the `run` command allows you to execute commands in an environment as if you had already entered it. (threagile-builder) $ pip install -r requirements.txt # pipx won't do this (threagile-builder) $ python -m setuptools_scm # optional, display the version of our package and perform any side-effects like writing to a file. (here: `_version.py`) (threagile-builder) $ python src/threagile_builder/app.py # starts the app (threagile-builder) $ exit # optional, type `exit` to leave the environment
-
Dependencias de software
-
Últimos lanzamientos
-
Referencias API
-
Construir y probar:
Para construir su código, use:
$ cd threagile-builder $ hatch build
Para usar IA para revisiones de solicitudes de extracción, use:
https://app.coderabbit.ai/dashboard(usa
phpstan.neon
)Para ejecutar la aplicación, utilice:
Linux:
$ export SECRET_KEY="secret"
Ventanas:
$ setx SECRET_KEY secret
Entonces:
$ cd threagile-builder # Without hatch: $ python src/threagile_builder/app.py $ hatch run python src/threagile_builder/app.py
Luego, navegue hasta
http://127.0.0.1:5000/
en su navegador web.Para ejecutar pruebas, utilice:
$ cd threagile-builder $ pip install pytest # optional $ pytest tests/
Navegar ahttp://127.0.0.1:5000/docs
en su navegador web, o descargue openapi.json desdehttp://127.0.0.1:5000/openapi.json
.
Dejemos que una herramienta como Prometeo raspehttp://127.0.0.1:9464/metrics
.
NUEVO
Tabla de contenido
pip install threagile-builder
- Elescotilla-vcsEl complemento fuente de la versión determina la versión del proyecto usando etiquetas Git.
- Definido claramente de forma independiente
hatch.toml
- El
test
la matriz utiliza elcontenedores-escotillacomplemento para ejecutar cada entorno dentro de contenedores Docker; El uso se puede ver en elpruebaflujo de trabajo de GitHub
- Todos los objetivos de construcción utilizan elescotilla-vcsconstruir complemento de gancho para enviar un
_version.py
archivo para que la versión pueda usarse en tiempo de ejecución - Las ruedas utilizan elhatch-mypyccomplemento de enlace de compilación para compilar primero todo el códigomipyc
- ElconstruirEl flujo de trabajo de GitHub muestra cómo:
- usarcibuildwheeldistribuir ruedas binarias para cada plataforma
- utilizar elaplicaciónconstruir objetivo para crear distribuciones independientes para cada plataforma
threagile-builder
se distribuye bajo los términos delCONlicencia.
VerREADME.md
VerREADME.md
VerREADME.md
VerREADME.md