Deploy khulnasoft.github.io #596
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy-Book | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
schedule: | |
- cron: "0 */12 * * *" | |
# This job installs dependencies, builds the book, and pushes it to `gh-pages` | |
jobs: | |
deploy-book: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.11' | |
architecture: 'x64' | |
# Install dependencies | |
- name: Install dependencies | |
run: | | |
sudo apt-get install jupyter -y --fix-missing | |
python -m pip install nbconvert | |
python -m pip install --upgrade pip -r requirements.txt | |
- name: Grab Needed Data | |
run: | | |
sudo apt install unzip | |
wget https://nvd.nist.gov/feeds/json/cve/1.1/nvdcve-1.1-{2002..2024}.json.zip | |
unzip -o "*.zip" | |
wget https://raw.githubusercontent.com/CVEProject/cve-website/dev/src/assets/data/CNAsList.json | |
- name: Run Notebooks | |
env: | |
GH_TOKEN: ${{ secrets.GH_TOKEN }} | |
run: | | |
jupyter nbconvert --to notebook --inplace --execute CVEAll.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVE2016.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVE2017.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVE2018.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVE2019.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVE2020.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVE2021.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVE2022.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVE2023.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVE2024.ipynb | |
# jupyter nbconvert --to notebook --inplace --execute CVECNAMap.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVECalendar.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVEGrowth.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVECVSS.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVECNA.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVECWE.ipynb | |
jupyter nbconvert --to notebook --inplace --execute CVECPE.ipynb | |
- name: Commit changes | |
uses: EndBug/add-and-commit@v9 | |
with: | |
default_author: github_actions | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build the book | |
run: | | |
jupyter-book build . | |
- name: GitHub Pages action | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./_build/html | |
cname: cve.khulnasoft.com |