Skip to content

Commit 930bb9c

Browse files
authored
Merge branch 'main' into add-almalinux-advisories
2 parents b3566e4 + 735e15e commit 930bb9c

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+3689
-59
lines changed

.VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
refs=$Format:%D$
2-
commit=$Format:%H$
2+
commit=$Format:%h$
33
abbrev_commit=$Format:%H$

.dockerignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ docker-compose.yml
66

77

88
# Ignore Git directory and files and github directory.
9-
**/.git
109
**/.gitignore
1110
**/.gitattributes
1211
**/.gitmodules

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
.VERSION export-subst

.github/workflows/pypi-release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ jobs:
4747
name: Create GH release
4848
needs:
4949
- build-pypi-distribs
50-
runs-on: ubuntu-20.04
50+
runs-on: ubuntu-22.04
5151

5252
steps:
5353
- name: Download built archives
@@ -67,7 +67,7 @@ jobs:
6767
name: Create PyPI release
6868
needs:
6969
- create-gh-release
70-
runs-on: ubuntu-20.04
70+
runs-on: ubuntu-22.04
7171

7272
steps:
7373
- name: Download built archives

CHANGELOG.rst

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,29 @@ Release notes
22
=============
33

44

5+
Version v36.1.2
6+
---------------------
7+
8+
- Get tag from VERSION manifest #1895
9+
10+
11+
Version v36.1.1
12+
---------------------
13+
14+
- Update is_active help text in pipeline migration #1887
15+
16+
17+
Version v36.1.0
18+
---------------------
19+
20+
- Remove admin panel #1885
21+
- Support running pipelines in scheduled task queue #1871
22+
- Optimize export management command #1868
23+
- Fix alpine linux importer #1861
24+
- Stop github OSV importer crashes #1854
25+
- Make advisory content_id a unique field #1864
26+
27+
528
Version v36.0.0
629
---------------------
730

Dockerfile

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,21 @@ ENV PYTHONDONTWRITEBYTECODE 1
1717

1818
RUN mkdir -p /var/vulnerablecode/static
1919

20+
RUN apt-get update \
21+
&& apt-get install -y --no-install-recommends \
22+
wait-for-it \
23+
&& apt-get clean \
24+
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
25+
2026
# Keep the dependencies installation before the COPY of the app/ for proper caching
2127
COPY setup.cfg setup.py requirements.txt pyproject.toml /app/
2228
RUN pip install . -c requirements.txt
2329

2430
COPY . /app
31+
32+
# Store commit hash for docker deployment from local checkout.
33+
RUN if [ -d ".git" ]; then \
34+
GIT_COMMIT=$(git rev-parse --short HEAD) && \
35+
echo "VULNERABLECODE_GIT_COMMIT=\"$GIT_COMMIT\"" >> /app/vulnerablecode/settings.py; \
36+
rm -rf .git; \
37+
fi

docker-compose.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,15 @@ services:
1010
- db_data:/var/lib/postgresql/data/
1111
- ./etc/postgresql/postgresql.conf:/etc/postgresql/postgresql.conf
1212

13+
vulnerablecode_redis:
14+
image: redis
15+
# Enable redis data persistence using the "Append Only File" with the
16+
# default policy of fsync every second. See https://redis.io/topics/persistence
17+
command: redis-server --appendonly yes
18+
volumes:
19+
- vulnerablecode_redis_data:/data
20+
restart: always
21+
1322
vulnerablecode:
1423
build: .
1524
command: /bin/sh -c "
@@ -26,6 +35,31 @@ services:
2635
depends_on:
2736
- db
2837

38+
vulnerablecode_scheduler:
39+
build: .
40+
command: wait-for-it web:8000 -- python ./manage.py run_scheduler
41+
env_file:
42+
- docker.env
43+
volumes:
44+
- /etc/vulnerablecode/:/etc/vulnerablecode/
45+
depends_on:
46+
- vulnerablecode_redis
47+
- db
48+
- vulnerablecode
49+
50+
vulnerablecode_rqworker:
51+
build: .
52+
command: wait-for-it web:8000 -- python ./manage.py rqworker default
53+
env_file:
54+
- docker.env
55+
volumes:
56+
- /etc/vulnerablecode/:/etc/vulnerablecode/
57+
depends_on:
58+
- vulnerablecode_redis
59+
- db
60+
- vulnerablecode
61+
62+
2963
nginx:
3064
image: nginx
3165
ports:
@@ -44,4 +78,5 @@ services:
4478
volumes:
4579
db_data:
4680
static:
81+
vulnerablecode_redis_data:
4782

docker.env

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,5 @@ POSTGRES_PASSWORD=vulnerablecode
44

55
VULNERABLECODE_DB_HOST=db
66
VULNERABLECODE_STATIC_ROOT=/var/vulnerablecode/static/
7+
8+
VULNERABLECODE_REDIS_HOST=vulnerablecode_redis

docs/source/conf.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@
3838
"https://example.org/api/non-existent-packages",
3939
"https://github.com/aboutcode-org/vulnerablecode/pull/495/commits",
4040
"https://nvd.nist.gov/products/cpe",
41+
"https://ftp.suse.com/pub/projects/security/yaml/suse-cvss-scores.yaml",
42+
"http://ftp.suse.com/pub/projects/security/yaml/",
4143
]
4244

4345
# Add any Sphinx extension module names here, as strings. They can be

docs/source/user-interface.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,11 @@ package URL or purl prefix fragment such as
1515

1616
The search by packages is available at the following URL:
1717

18-
`https://public.vulnerablecode.io/packages/search <https://public.vulnerablecode.io/packages/search>`_
18+
`https://public.vulnerablecode.io/packages/search/ <https://public.vulnerablecode.io/packages/search/>`_
1919

2020
How to search by packages:
2121

22-
1. Go to the URL: `https://public.vulnerablecode.io/packages/search <https://public.vulnerablecode.io/packages/search>`_
22+
1. Go to the URL: `https://public.vulnerablecode.io/packages/search/ <https://public.vulnerablecode.io/packages/search/>`_
2323
2. Enter the package URL or purl prefix fragment such as ``pkg:pypi``
2424
or by package name in the search box.
2525
3. Click on the search button.
@@ -46,11 +46,11 @@ fragment of these identifiers like ``CVE-2021``.
4646

4747
The search by vulnerabilities is available at the following URL:
4848

49-
`https://public.vulnerablecode.io/vulnerabilities/search <https://public.vulnerablecode.io/vulnerabilities/search>`_
49+
`https://public.vulnerablecode.io/vulnerabilities/search/ <https://public.vulnerablecode.io/vulnerabilities/search/>`_
5050

5151
How to search by vulnerabilities:
5252

53-
1. Go to the URL: `https://public.vulnerablecode.io/vulnerabilities/search <https://public.vulnerablecode.io/vulnerabilities/search>`_
53+
1. Go to the URL: `https://public.vulnerablecode.io/vulnerabilities/search/ <https://public.vulnerablecode.io/vulnerabilities/search/>`_
5454
2. Enter the VCID, CVE, GHSA, CPEs etc. in the search box.
5555
3. Click on the search button.
5656

0 commit comments

Comments
 (0)