Skip to content

Commit

Permalink
Add more README instructions
Browse files Browse the repository at this point in the history
Signed-off-by: lucperkins <[email protected]>
  • Loading branch information
lucperkins committed Apr 16, 2019
1 parent 2064917 commit f1dbe60
Show file tree
Hide file tree
Showing 3 changed files with 60 additions and 8 deletions.
17 changes: 12 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
DOCKER_IMG = klakegg/hugo:0.53-ext
SERVER = server --buildDrafts --buildFuture --disableFastRender --ignoreCache

setup:
yarn

serve:
hugo server \
--buildDrafts \
--buildFuture \
--disableFastRender \
--ignoreCache
hugo $(SERVE)

docker-serve:
docker run --rm -it -v $(PWD):/src -p 1313:1313 $(DOCKER_IMG) $(SERVER)

docker-serve:

production-build:
hugo --minify
Expand Down
47 changes: 46 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,48 @@
# etcd.io

This repository houses all of the assets used to build the future website and documentation at https://etcd.io.
This repository houses all of the assets used to build the future website and documentation at https://etcd.netlify.com. The site will eventually be available at https://etcd.io.

## Run the site locally

### Prerequisites

In order to run the site locally, you need to have the following installed:

* The [Yarn](https://yarnpkg.com/en/) package manager
* The [Hugo](https://gohugo.io) static site generator. Check the [`netlify.toml`](./netlify.toml) configuration file to see which version of Hugo you need to install.

> **Note**: You need to install the "extended" version of Hugo with support for [Sass](https://sass-lang.com/).
### Setup

Once you've installed the [prerequisites](#prerequisites):

```bash
make setup
```

### Running

Once the [setup](#setup) has completed, you can run the site in your local environment:

```bash
make serve
```

#### Docker

You can also run the site locally using [Docker](https://docker.com):

```bash
make docker-serve
```

## Publishing the site

The site is published automatically by [Netlify](https://netlify.com). Any time
changes are pushed to the `master` branch, the site is rebuilt and redeployed.

### Preview builds

Any time you submit a pull request to this repository, Netlify will publish a [preview build](https://www.netlify.com/blog/2016/07/20/introducing-deploy-previews-in-netlify/) of the changes in that pull request. You can find a link to the preview build in the checks section of the pull request, under **
netlify/etcd/deploy-preview**.
4 changes: 2 additions & 2 deletions layouts/partials/docs/nav-panel.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
{{ $version := index (split .Path "/") 2 }}
{{ $allDocs := where site.Sections "Section" "docs" }}
{{ $currentUrl := .RelPermalink }}
<div class="dashboard-panel is-medium is-scrollable has-background-white-bis is-hidden-mobile">
<div class="dashboard-panel is-medium has-background-white-bis is-hidden-mobile">
<div class="dashboard-panel-header has-text-centered">
<a href="{{ .Site.BaseURL }}">
<img class="is-panel-logo" src="{{ $logo }}">
Expand All @@ -19,7 +19,7 @@
</a>
</div>

<div class="dashboard-panel-main">
<div class="dashboard-panel-main is-scrollable">
<div class="docs-panel">
{{ range $allDocs }}
{{ range .Sections }}
Expand Down

0 comments on commit f1dbe60

Please sign in to comment.