Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Init pages #35

Merged
merged 2 commits into from
Sep 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 58 additions & 0 deletions .github/workflows/publish-pages-on-forks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
---
name: marp-and-mkdocs-to-pages
concurrency: marp-and-mkdocs-to-pages
on:
push:
branches: [ '**' ]
paths:
- slides/**
- docs/**
- mkdocs.yml
- img/**
- .github/workflows/publish-pages-on-forks.yml
# also trigger if lab archives changed
- demos/**
- .devcontainer/**
workflow_dispatch:
branches: [ '**' ]
permissions:
contents: write
pages: write
id-token: write
jobs:
build:
if: github.repository != 'aristanetworks/aclabs'
runs-on: ubuntu-22.04
steps:

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

- name: find-branch
id: find_branch
run: |
echo "branch=${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}" >> $GITHUB_OUTPUT

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

- name: Build MkDocs Site
run: |
pip install mkdocs-material
pip install mkdocs-macros-plugin
pip install mdx_truly_sane_lists
mkdocs build

- name: Setup Pages 📖
uses: actions/configure-pages@v5

- name: Upload artifact 🔼
uses: actions/upload-pages-artifact@v3
with:
path: ./site/

- name: Deploy to GitHub Pages 🚀
id: deployment
uses: actions/deploy-pages@v4
53 changes: 53 additions & 0 deletions .github/workflows/publish-pages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
---
name: marp-and-mkdocs-to-pages
concurrency: marp-and-mkdocs-to-pages
on:
push:
branches: [ main ]
paths:
- slides/**
- docs/**
- mkdocs.yml
- img/**
- .github/workflows/publish-pages.yml
# also trigger if lab archives changed
- demos/**
- .devcontainer/**
workflow_dispatch:
branches: [main]
permissions:
contents: write
pages: write
id-token: write
jobs:
build:
if: github.repository == 'aristanetworks/aclabs'
runs-on: ubuntu-22.04
steps:

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

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

- name: Build MkDocs Site
run: |
pip install mkdocs-material
pip install mkdocs-macros-plugin
pip install mdx_truly_sane_lists
mkdocs build

- name: Setup Pages 📖
uses: actions/configure-pages@v5

- name: Upload artifact 🔼
uses: actions/upload-pages-artifact@v3
with:
path: ./site/

- name: Deploy to GitHub Pages 🚀
id: deployment
uses: actions/deploy-pages@v4
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,6 @@

# license files
*license*.json

# ignore mkdocs serve privacy cache
.cache
5 changes: 5 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Arista Community Labs

!!! Warning "WARNING!"

Under construction!
81 changes: 81 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
---
site_name: Arista Community Labs
site_url: https://aclabs.arista.com
repo_name: Arista Community Labs
repo_url: https://github.com/aristanetworks/aclabs

# extra_css:
# - assets/stylesheets/extra.css

theme:
name: material
features:
- announce.dismiss
- content.code.annotate
- content.code.copy
# - content.code.select
- content.footnote.tooltips
# - content.tabs.link
- content.tooltips
- header.autohide
# - navigation.expand
- navigation.indexes
# - navigation.instant
# - navigation.instant.prefetch
# - navigation.instant.progress
# - navigation.prune
# - navigation.sections
- navigation.tabs
# enabling prune for testing only, to check if it's stable
# it's not making any difference with current site setup
- navigation.prune
# - navigation.tabs.sticky
- navigation.top
- navigation.tracking
- search.highlight
- search.share
- search.suggest
- toc.follow
# - toc.integrate

font:
text: Roboto
code: Roboto Mono
favicon: assets/favicon.png
icon:
repo: fontawesome/brands/github
logo: fontawesome/solid/gears

markdown_extensions:
- attr_list
- admonition
- pymdownx.details
- pymdownx.superfences
- pymdownx.critic
- pymdownx.caret
- pymdownx.keys
- pymdownx.mark
- pymdownx.tilde
- pymdownx.emoji:
emoji_index: !!python/name:material.extensions.emoji.twemoji
emoji_generator: !!python/name:material.extensions.emoji.to_svg
- pymdownx.tabbed:
alternate_style: true
- pymdownx.superfences:
custom_fences:
- name: mermaid
class: mermaid
format: !!python/name:pymdownx.superfences.fence_code_format
# allows list ident with 2 spaces
- mdx_truly_sane_lists

copyright: >
&nbsp;&#x1F36A;&nbsp;<a href="#__consent">Change cookie settings</a>

plugins:
- privacy
- search

nav:
- Home:
- Home: index.md
Loading