Commit 278af697 authored by Sjoerd Simons's avatar Sjoerd Simons
Browse files

first commit

parents
# All available Hugo versions are listed here: https://gitlab.com/pages/hugo/container_registry
image: registry.gitlab.com/pages/hugo:latest
variables:
GIT_SUBMODULE_STRATEGY: recursive
test:
script:
- hugo
artifacts:
paths:
- public
except:
- main
pages:
script:
- BASEURL=${CI_PAGES_URL##http:} # don't force stuff on plain HTTP when publishing on HTTPS
- hugo -b "${BASEURL:-/}"
artifacts:
paths:
- public
only:
- main
Repo for lava documentation. The canonical copy can be found on https://lava.pages.collabora.com/docs/
## Contributing
Patches welcome! Please submit MRs against the gitlab repository
## Building/testing locally
To work locally with this project simply run the `run-hugo.sh` script; This
will spawn a hugo (in server mode) in a docker container allowing to use your
browser for previes. Hugo watches the repository directory and automatically
rerenders on changes.
Read more at Hugo's [documentation][].
### GitLab CI
The content of this project is built by [GitLab CI][ci], following the steps
defined in [`.gitlab-ci.yml`](.gitlab-ci.yml).
[ci]: https://about.gitlab.com/gitlab-ci/
[hugo]: https://gohugo.io
[documentation]: https://gohugo.io/overview/introduction/
baseurl = ""
contentdir = "content"
layoutdir = "layouts"
publishdir = "public"
title = "Collabora lava documentation"
relativeurls = true
DefaultContentLanguage = "en"
theme = "collaborahugo"
metaDataFormat = "yaml"
pygmentsUseClasses = true
pygmentCodeFences = true
#disqusShortname = "XXX"
#googleAnalytics = "XXX"
[Params]
subtitle = ""
logo = "img/avatar-icon.png"
favicon = "img/favicon.ico"
dateFormat = "January 2, 2006"
commit = false
rss = true
comments = true
searchbox = true
# gcse = "012345678901234567890:abcdefghijk" # Get your code from google.com/cse. Make sure to go to "Look and Feel" and change Layout to "Full Width" and Theme to "Classic"
#[[Params.bigimg]]
# src = "img/triangle.jpg"
# desc = "Triangle"
#[[Params.bigimg]]
# src = "img/sphere.jpg"
# desc = "Sphere"
#[[Params.bigimg]]
# src = "img/hexagon.jpg"
# desc = "Hexagon"
[Author]
name = "Collabora"
gitlab-co = "lava/docs"
[outputs]
home = ["HTML", "JSON"]
---
title: Collabora LAVA service
---
Collabora runs a [LAVA](https://www.lavasoftware.org/) instances for various
open source and customer projects. Such as KernelCI, Mesa and Apertis.
---
title: Adding boards to lava
---
TODO
---
title: Lava service guarantees
---
TODO
{{ define "header" }}
<header class="header-section ">
<div class="intro-header no-img">
<div class="container">
<div class="row">
<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">
<div class="page-heading">
<h1>{{ if .Data.Singular }}#{{ end }}{{ .Title }}</h1>
<hr class="small">
</div>
</div>
</div>
</div>
</div>
</header>
{{ end }}
{{ define "main" }}
<div class="container" role="main">
<div class="row">
<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">
{{ with .Content }}
<div class="well">
{{.}}
</div>
{{ end }}
<div class="article-list">
<ul>
{{ range .Pages }}
{{ if and (.Site.Params.searchbox) (ne .Params.layout "search") }}
<li>
<article class="article-preview">
<a href="{{ .Permalink }}">
<div class="post-title">{{ or .Title .File.BaseFileName }}</div>
{{ if .Params.subtitle }}
<div class="post-subtitle">
{{ .Params.subtitle }}
</div>
{{ end }}
</a>
{{ if .Params.tags }}
<span class="post-meta">
{{ range .Params.tags }}
#<a href="{{ $.Site.LanguagePrefix }}/tags/{{ . | urlize }}">{{ . }}</a>&nbsp;
{{ end }}
</span>
{{ end }}
</article>
</li>
{{ end }}
{{ end }}
</ul>
</div>
</div>
</div>
</div>
{{ end }}
<script src="/js/mermaid.min.js"></script>
<div class="mermaid">
{{ .Inner }}
</div>
#!/bin/sh
# Run hugo in server mode and let it bind on all interface in the container
# such that docker can forward it properly.
REPO=$(dirname $(realpath $0))
docker run \
-p 1313:1313/tcp \
-w /docs \
-u $(id -u) \
-v ${REPO}:/docs \
registry.gitlab.com/pages/hugo:latest \
hugo server --bind ""
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
#!/bin/sh
# SPDX-License-Identifier: MIT
# Author: Sjoerd Simons <sjoerd@collabora.com>
#
# Wrapper for knife to avoid the client cert to ever be stored unencrypted on
# disk. This wrapper requires unpriviledged user namespaces to be enabled and
# the client certificate sorted by `pass` (https://www.passwordstore.org/)
#
# The way it works is that a new user namespace is created with most
# among other things a sepearte mount namespace; In that namespace a tmpfs is
# mounted on ~/.cinc and configuration is setup with the client cert pulled out
# of pass.
#
# This all means the unencrypted certificate is only ever in a) memory
# (tmpfs) and b) visible only for programs in the same mount namespace until
# the mount namespaces gets shut down; So for an attacker to get the client key
# it there is only a quite short time-window and tbh. attacking pass when the
# gnupg agent is unlocked is simpler :). Practically the real benefit of this
# approach is avoiding the wrapper is accidentally leaving the client pem file
# accessible for a long time due to cleanup failing
set -e
# Client name for chef
USER=sjoerdR
# Chef server
SERVER=https://chef.collabora.co.uk
# Name of the client key in pass
PASSCERT=collabora/chef/client.pem
if [ $$ -ne 1 ] ; then
exec unshare --kill-child \
--fork \
--pid \
--mount-proc \
--map-root-user \
--mount \
$0 $@
# Will only get here if exec fails
exit 1
fi
CONFIGDIR=${HOME}/.cinc
mkdir -p ${CONFIGDIR}
# Support for older non-cinc tooling
ln -Tsf ${CONFIGDIR} ${HOME}/.chef
mount -t tmpfs none ${CONFIGDIR}
cat << EOF > ${CONFIGDIR}/knife.rb
node_name '${USER}'
client_key '${CONFIGDIR}/client.pem'
chef_server_url '${SERVER}'
EOF
pass ${PASSCERT} > ${CONFIGDIR}/client.pem
exec knife $@
# Auto detect text files and perform LF normalization
* text=auto
# Custom for Visual Studio
*.cs diff=csharp
# Standard to msysgit
*.doc diff=astextplain
*.DOC diff=astextplain
*.docx diff=astextplain
*.DOCX diff=astextplain
*.dot diff=astextplain
*.DOT diff=astextplain
*.pdf diff=astextplain
*.PDF diff=astextplain
*.rtf diff=astextplain
*.RTF diff=astextplain
# Themes directory of example site; ignored so that we can clone the repo
# inside the themes directory and test the example site with "hugo server".
exampleSite/themes/
# Windows image file caches
Thumbs.db
ehthumbs.db
# Folder config file
Desktop.ini
# Recycle Bin used on file shares
$RECYCLE.BIN/
# Windows Installer files
*.cab
*.msi
*.msm
*.msp
# Windows shortcuts
*.lnk
# Vim swap files
*.swp
# =========================
# Operating System Files
# =========================
# OSX
# =========================
.DS_Store
.AppleDouble
.LSOverride
# Thumbnails
._*
# Files that might appear on external disk
.Spotlight-V100
.Trashes
# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk
The MIT License (MIT)
Original work Copyright (c) 2015 Dean Attali
Modified work Copyright (c) 2017 Michael Romero
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
# Beautiful Hugo - A port of Beautiful Jekyll Theme
![Beautiful Hugo Theme Screenshot](https://github.com/halogenica/beautifulhugo/blob/master/images/screenshot.png)
## Installation
$ mkdir themes
$ cd themes
$ git clone https://github.com/halogenica/beautifulhugo.git beautifulhugo
See [the Hugo documentation](http://gohugo.io/themes/installing/) for more information.
## Extra Features
### Responsive
This theme is designed to look great on both large-screen and small-screen (mobile) devices.
### Syntax highlighting
This theme has support for both server side and client side highlighting.
#### Server side syntax highlighting
Use the `highlight` shortcode (with Pygments),
see [the Hugo documentation](http://gohugo.io/extras/highlighting/) for more information.
To use this feature install Pygments (`pip install Pygments`) and add `pygmentsuseclasses = true` to your `config.toml`.
#### Client side syntax highlighting
Use triple backticks ( ``` ) or triple tilde ( ~~~ ) around code blocks.
Client side highlighting does not require pygments to be installed.
### Disqus support
To use this feature, uncomment and fill out the `disqusShortname` parameter in `config.toml`.
### Google Analytics
To add Google Analytics, simply sign up to [Google Analytics](http://www.google.com/analytics/) to obtain your Google Tracking ID, and add this tracking ID to the `googleAnalytics` parameter in `config.toml`.
### Commit SHA on the footer
If the source of your site is in a Git repo, the SHA corresponding to the commit the site is built from can be shown on the footer. To do so, two environment variables have to be set (`GIT_COMMIT_SHA` and `GIT_COMMIT_SHA_SHORT`) and parameter `commit` has to be defined in the config file:
```
[Params]
commit = "https://github.com/<username>/<siterepo>/tree/"
```
This can be achieved by running the next command prior to calling Hugo:
```
GIT_COMMIT_SHA=`git rev-parse --verify HEAD` GIT_COMMIT_SHA_SHORT=`git rev-parse --short HEAD`
```
See at [xor-gate/xor-gate.org](https://github.com/xor-gate/xor-gate.org) an example of how to add it to a continuous integration system.
## About
This is a port of the Jekyll theme [Beautiful Jekyll](http://deanattali.com/beautiful-jekyll/) by [Dean Attali](http://deanattali.com/aboutme#contact). It supports most of the features of the original theme.
## License
MIT Licensed, see [LICENSE](https://github.com/halogenica/Hugo-BeautifulHugo/blob/master/LICENSE).
[[social_icons]]
id = "email"
url = "mailto:%s"
title = "Email me"
icon = "fas fa-envelope"
[[social_icons]]
id = "facebook"
url = "https://www.facebook.com/%s"
title = "Facebook"
icon = "fab fa-facebook"
[[social_icons]]
id = "googleplus"
url = "https://www.plus.google.com/%s"
title = "Google+"
icon = "fab fa-google-plus"
[[social_icons]]
id = "gitlab-co"
url = "https://gitlab.collabora.com/%s"
title = "Collabora GitLab"
icon = "fab fa-gitlab"
[[social_icons]]
id = "github"
url = "https://github.com/%s"
title = "GitHub"
icon = "fab fa-github"
[[social_icons]]
id = "twitter"
url = "https://twitter.com/%s"
title = "Twitter"
icon = "fab fa-twitter"
[[social_icons]]
id = "reddit"
url = "https://reddit.com/u/%s"
title = "Reddit"
icon = "fab fa-reddit-alien"
[[social_icons]]
id = "linkedin"
url = "https://linkedin.com/%s"
title = "LinkedIn"
icon = "fab fa-linkedin"
[[social_icons]]
id = "xing"
url = "https://www.xing.com/profile/%s"
title = "Xing"
icon = "fab fa-xing"
[[social_icons]]
id = "stackoverflow"
url = "https://stackoverflow.com/%s"
title = "StackOverflow"
icon = "fab fa-stack-overflow"
[[social_icons]]
id = "snapchat"
url = "https://www.snapchat.com/add/%s"
title = "Snapchat"
icon = "fab fa-snapchat-ghost"
[[social_icons]]
id = "instagram"
url = "https://www.instagram.com/%s"
title = "Instagram"
icon = "fab fa-instagram"
[[social_icons]]
id = "youtube"
url = "https://www.youtube.com/%s"
title = "Youtube"
icon = "fab fa-youtube"
[[social_icons]]
id = "soundcloud"
url = "https://soundcloud.com/%s"
title = "SoundCloud"
icon = "fab fa-soundcloud"
[[social_icons]]
id = "spotify"
url = "https://open.spotify.com/user/%s"
title = "Spotify"
icon = "fab fa-spotify"
[[social_icons]]
id = "bandcamp"
url = "https://%s.bandcamp.com/"
title = "Bandcamp"
icon = "fab fa-bandcamp"
[[social_icons]]
id = "itchio"
url = "https://itch.io/profile/%s"
title = "itch.io"
icon = "fas fa-gamepad"
[[social_icons]]
id = "steam"
url = "https://steamcommunity.com/id/%s"
title = "Steam"
icon = "fab fa-steam"
[[social_icons]]
id = "keybase"
url = "https://keybase.io/%s"
title = "Keybase"
icon = "fab fa-keybase"
[[social_icons]]
id = "Goodreads"
url = "https://www.goodreads.com/%s"
title = "Goodreads"
icon = "fab fa-goodreads"
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment