Go to file
Ian Lewis c061aef8d9 Remove .git handling from .gcloudignore
We aren't including git commit info in doc pages anymore so we don't
need special handling for .git for Cloud Build anymore.
2019-04-03 16:14:17 +09:00
archetypes
assets Update cover to match layout from designers 2019-04-02 16:11:53 -07:00
cloudbuild
cmd/gvisor-website Remove parse-syscall-annotations tool for now 2019-04-03 15:46:45 +09:00
content Update Kubernetes doc page 2019-04-03 16:08:36 +09:00
layouts Update cover to match layout from designers 2019-04-02 16:11:53 -07:00
static/favicons
themes/docsy
.gcloudignore Remove .git handling from .gcloudignore 2019-04-03 16:14:17 +09:00
.gitignore
CODEOWNERS Add gvisor team to CODEOWNERS 2019-04-03 16:04:06 +09:00
CONTRIBUTING.md
LICENSE
Makefile
README.md Ensure exact match for project 2019-04-02 17:57:26 -07:00
cloudbuild.yaml Substitute true for return 2019-04-02 17:08:26 -07:00
config.toml
package-lock.json
package.json

README.md

gVisor Website

This repository holds the content for the gVisor website. It uses hugo to generate the website and Docsy as the theme.

Requirements

Building the website requires the extended version of hugo and node.js in order to generate CSS files. Please install them before building.

  • Node.js >= 10.15.0 LTS
  • hugo extended >= v0.53

Building

Build the website using make:

make

This will output the App Engine application code, configuration, and html and CSS into the public/ directory.

Testing

You can use the hugo web server for testing. This will start a webserver that will rebuild the site when you make content changes:

make server

Access the site at http://localhost:8080

Deploy

Deploying the website to App Engine requires gcloud. First create a configuration:

{
  gcloud config configurations create gvisor-website
  gcloud config set project gvisor-website
}

Deploy the application:

make deploy

Editing documentation

Documentation is located in the content/docs/ directory. Documentation is written in markdown with hugo extensions. Please read more about content management in the hugo documentation.

Submit a Build

Normally a build is triggered when you push to the gvisor-website repository. However, you can submit a build to Cloud Build manually.

As one-time setup, enable the App Engine Admin API, and set IAM roles for the Cloud Build service account.

{
  PROJECT_NUMBER=$(gcloud projects list --filter=projectId:gvisor-website --format="value(projectNumber)")
  gcloud services enable appengine.googleapis.com
  gcloud projects add-iam-policy-binding gvisor-website \
    --member=serviceAccount:${PROJECT_NUMBER}@cloudbuild.gserviceaccount.com \
    --role='roles/appengine.deployer'
  gcloud projects add-iam-policy-binding gvisor-website \
    --member=serviceAccount:${PROJECT_NUMBER}@cloudbuild.gserviceaccount.com \
    --role='roles/appengine.serviceAdmin'
}

Submit the build.

make cloud-build