distro-tools/apollo/server/BUILD.bazel

51 lines
1.3 KiB
Python
Raw Normal View History

2023-02-01 21:37:16 +00:00
load("@aspect_rules_py//py:defs.bzl", "py_library")
load("//build/macros:fastapi.bzl", "fastapi_binary")
py_library(
name = "server_lib",
srcs = [
"roles.py",
"routes/admin_index.py",
"routes/advisories.py",
"routes/api_advisories.py",
"routes/api_compat.py",
"routes/api_red_hat.py",
"routes/login.py",
"routes/logout.py",
"routes/red_hat_advisories.py",
"routes/statistics.py",
"server.py",
"settings.py",
"utils.py",
],
data = [
":assets",
":templates",
"//apollo/server/static",
],
imports = ["../.."],
visibility = ["//:__subpackages__"],
deps = [
"//apollo/db:db_lib",
"//apollo/db/serialize:serialize_lib",
"//common:common_lib",
"@pypi_fastapi//:pkg",
"@pypi_fastapi_pagination//:pkg",
"@pypi_itsdangerous//:pkg",
"@pypi_jinja2//:pkg",
"@pypi_passlib//:pkg",
"@pypi_python_multipart//:pkg",
2023-02-02 13:53:35 +00:00
"@pypi_rssgen//:pkg",
2023-02-01 21:37:16 +00:00
"@pypi_starlette//:pkg",
"@pypi_tortoise_orm//:pkg",
],
)
fastapi_binary(
name = "server",
image_name = "apollo-server",
2023-02-01 21:37:16 +00:00
imports = ["../.."],
path = "apollo.server.server",
port = "9999",
)