Skip to content

Commit

Permalink
try with mkdocs
Browse files Browse the repository at this point in the history
  • Loading branch information
ankudinov committed Mar 16, 2024
1 parent b1d09c6 commit b5e16ec
Show file tree
Hide file tree
Showing 5 changed files with 108 additions and 10 deletions.
Original file line number Diff line number Diff line change
@@ -1,38 +1,51 @@
name: marp-to-pages
concurrency: marp-to-pages
name: marp-and-mkdocs-to-pages
concurrency: marp-and-mkdocs-to-pages
on:
push:
branches: [ main ]
paths:
- slides/**
- docs/**
- mkdocs.yml
- img/**
- .github/workflows/marp-to-pages.yml
- .github/workflows/publish-pages.yml
permissions:
contents: write
jobs:
build:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
steps:

- name: Checkout code ✅
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Copy images 🖼️
- name: Setup Python3 🐍
uses: actions/setup-python@v5
with:
python-version: "3.11"

- name: Build MkDocs Site
run: |
pip install mkdocs-material
mkdocs build
- name: Build Directories and Copy images 🖼️
run: |
mkdir build \
&& cp -R img build/img
mkdir site/slides \
&& mkdir site/pdfs \
&& cp -R img site/slides/img
- name: Build HTML from Marp 🔨
uses: docker://marpteam/marp-cli:v3.0.2
with:
args: --html slides/avd_cvaas.md -o build/avd_cvaas.html
args: --html slides/avd_cvaas.md -o site/slides/avd_cvaas.html
env:
MARP_USER: root:root

- name: Build PDF from marp_slides.md 🔨
uses: docker://marpteam/marp-cli:v3.0.2
with:
args: --html --allow-local-files slides/avd_cvaas.md -o build/avd_cvaas.pdf
args: --html --allow-local-files slides/avd_cvaas.md -o site/pdfs/avd_cvaas.pdf
env:
MARP_USER: root:root

Expand Down
4 changes: 4 additions & 0 deletions docs/avd-cvaas/aa.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# AVD CVaaS Active-Active Demo

[Slides](https://arista-netdevops-community.github.io/one-click-se-demos/slides/avd_cvaas.html)
[PDF Slides](https://arista-netdevops-community.github.io/one-click-se-demos/pdfs/avd_cvaas.html)
4 changes: 4 additions & 0 deletions docs/avd-cvaas/mlag.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# AVD CVaaS MLAG Demo

[Slides](https://arista-netdevops-community.github.io/one-click-se-demos/slides/avd_cvaas.html)
[PDF Slides](https://arista-netdevops-community.github.io/one-click-se-demos/pdfs/avd_cvaas.html)
17 changes: 17 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Welcome to MkDocs

For full documentation visit [mkdocs.org](https://www.mkdocs.org).

## Commands

* `mkdocs new [dir-name]` - Create a new project.
* `mkdocs serve` - Start the live-reloading docs server.
* `mkdocs build` - Build the documentation site.
* `mkdocs -h` - Print help message and exit.

## Project layout

mkdocs.yml # The configuration file.
docs/
index.md # The documentation homepage.
... # Other markdown pages, images and other files.
60 changes: 60 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
site_name: MKDOCs test

theme:
name: material
features:
- announce.dismiss
- content.action.edit
- content.action.view
- content.code.annotate
- content.code.copy
# - content.code.select
# - content.footnote.tooltips
# - content.tabs.link
- content.tooltips
# - header.autohide
# - navigation.expand
- navigation.footer
- navigation.indexes
# - navigation.instant
# - navigation.instant.prefetch
# - navigation.instant.progress
# - navigation.prune
- navigation.sections
- navigation.tabs
# - navigation.tabs.sticky
- navigation.top
- navigation.tracking
- search.highlight
- search.share
- search.suggest
- toc.follow
# - toc.integrate
palette:
- media: "(prefers-color-scheme: light)"
scheme: default
primary: brown
accent: red
toggle:
icon: material/weather-sunny
name: Switch to dark mode
- media: "(prefers-color-scheme: dark)"
scheme: slate
primary: brown
accent: amber
toggle:
icon: material/weather-night
name: Switch to light mode

font:
text: Roboto
code: Roboto Mono
favicon: assets/favicon.png
icon:
logo: logo

nav:
- Home: index.md
- AVD CVaaS:
- MLAG: avd-cvaas/mlag.md
- Active-Active: avd-cvaas/aa.md

0 comments on commit b5e16ec

Please sign in to comment.