Skip to content

Commit 545ad15

Browse files
committed
Refactor the site to use Docusaurus
PROBLEM: The existing site is using out of date versions of Docsy and Hugo. We need to either upgrade those components, or use the time to switch to a different static site generator. SOLUTION: Use Docusaurus. Jeff has had a good experience using it with Holos, so let's use the opportunity to switch the site to Docusaurus. This commit refactors the existing site content to use Docusaurus with the following details: * Removed the Logo blog as it really doesn't serve us well. * Used undraw.co SVG graphics on the landing page. * Removed "Google Partners" because evidently we aren't anymore. * Setup redirects to the existing site URLs so Google won't complain. OUTCOME: Our existing site content, but on a different static site generation platform, and one that is easy for us to update.
1 parent c9b4ade commit 545ad15

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

76 files changed

+17351
-136
lines changed

Diff for: .gitignore

+19-5
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,20 @@
1-
/public
2-
resources/
3-
node_modules/
4-
package-lock.json
5-
.hugo_build.lock
1+
# Dependencies
2+
/node_modules
3+
4+
# Production
5+
/build
6+
7+
# Generated files
8+
.docusaurus
9+
.cache-loader
10+
11+
# Misc
612
.DS_Store
13+
.env.local
14+
.env.development.local
15+
.env.test.local
16+
.env.production.local
17+
18+
npm-debug.log*
19+
yarn-debug.log*
20+
yarn-error.log*

Diff for: README.md

+17-114
Original file line numberDiff line numberDiff line change
@@ -1,138 +1,41 @@
1-
# Docsy Example
1+
# Website
22

3-
[Docsy][] is a [Hugo theme module][] for technical documentation sites, providing easy
4-
site navigation, structure, and more. This **Docsy Example Project** uses the Docsy
5-
theme component as a hugo module and provides a skeleton documentation structure for you to use.
6-
You can clone/copy this project and edit it with your own content, or use it as an example.
3+
This website is built using [Docusaurus](https://docusaurus.io/), a modern static website generator.
74

8-
In this project, the Docsy theme component is pulled in as a Hugo module, together with other module dependencies:
5+
### Installation
96

10-
```bash
11-
$ hugo mod graph
12-
hugo: collected modules in 566 ms
13-
hugo: collected modules in 578 ms
14-
github.com/google/docsy-example github.com/google/[email protected]
15-
github.com/google/docsy-example github.com/google/docsy/[email protected]
16-
github.com/google/docsy/[email protected] github.com/twbs/[email protected]+incompatible
17-
github.com/google/docsy/[email protected] github.com/FortAwesome/[email protected]
187
```
19-
20-
You can find detailed theme instructions in the [Docsy user guide][].
21-
22-
This Docsy Example Project is hosted on [Netlify][] at [example.docsy.dev][].
23-
You can view deploy logs from the [deploy section of the project's Netlify
24-
dashboard][deploys], or this [alternate dashboard][].
25-
26-
This is not an officially supported Google product. This project is currently maintained.
27-
28-
## Using the Docsy Example Project as a template
29-
30-
A simple way to get started is to use this project as a template, which gives you a site project that is set up and ready to use. To do this:
31-
32-
1. Click **Use this template**.
33-
34-
2. Select a name for your new project and click **Create repository from template**.
35-
36-
3. Make your own local working copy of your new repo using git clone, replacing https://github.com/me/example.git with your repo’s web URL:
37-
38-
```bash
39-
git clone --depth 1 https://github.com/me/example.git
8+
$ yarn
409
```
4110

42-
You can now edit your own versions of the site’s source files.
43-
44-
If you want to do SCSS edits and want to publish these, you need to install `PostCSS`
11+
### Local Development
4512

46-
```bash
47-
npm install
13+
```
14+
$ yarn start
4815
```
4916

50-
## Running the website locally
51-
52-
Building and running the site locally requires a recent `extended` version of [Hugo](https://gohugo.io).
53-
You can find out more about how to install Hugo for your environment in our
54-
[Getting started](https://www.docsy.dev/docs/getting-started/#prerequisites-and-installation) guide.
17+
This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.
5518

56-
Once you've made your working copy of the site repo, from the repo root folder, run:
19+
### Build
5720

5821
```
59-
hugo server
22+
$ yarn build
6023
```
6124

62-
## Running a container locally
63-
64-
You can run docsy-example inside a [Docker](https://docs.docker.com/)
65-
container, the container runs with a volume bound to the `docsy-example`
66-
folder. This approach doesn't require you to install any dependencies other
67-
than [Docker Desktop](https://www.docker.com/products/docker-desktop) on
68-
Windows and Mac, and [Docker Compose](https://docs.docker.com/compose/install/)
69-
on Linux.
70-
71-
1. Build the docker image
72-
73-
```bash
74-
docker-compose build
75-
```
25+
This command generates static content into the `build` directory and can be served using any static contents hosting service.
7626

77-
1. Run the built image
27+
### Deployment
7828

79-
```bash
80-
docker-compose up
81-
```
29+
Using SSH:
8230

83-
> NOTE: You can run both commands at once with `docker-compose up --build`.
84-
85-
1. Verify that the service is working.
86-
87-
Open your web browser and type `http://localhost:1313` in your navigation bar,
88-
This opens a local instance of the docsy-example homepage. You can now make
89-
changes to the docsy example and those changes will immediately show up in your
90-
browser after you save.
91-
92-
### Cleanup
93-
94-
To stop Docker Compose, on your terminal window, press **Ctrl + C**.
95-
96-
To remove the produced images run:
97-
98-
```console
99-
docker-compose rm
10031
```
101-
For more information see the [Docker Compose
102-
documentation](https://docs.docker.com/compose/gettingstarted/).
103-
104-
## Troubleshooting
105-
106-
As you run the website locally, you may run into the following error:
107-
108-
```
109-
➜ hugo server
110-
111-
INFO 2021/01/21 21:07:55 Using config file:
112-
Building sites … INFO 2021/01/21 21:07:55 syncing static files to /
113-
Built in 288 ms
114-
Error: Error building site: TOCSS: failed to transform "scss/main.scss" (text/x-scss): resource "scss/scss/main.scss_9fadf33d895a46083cdd64396b57ef68" not found in file cache
32+
$ USE_SSH=true yarn deploy
11533
```
11634

117-
This error occurs if you have not installed the extended version of Hugo.
118-
See this [section](https://www.docsy.dev/docs/get-started/docsy-as-module/installation-prerequisites/#install-hugo) of the user guide for instructions on how to install Hugo.
119-
120-
Or you may encounter the following error:
35+
Not using SSH:
12136

12237
```
123-
➜ hugo server
124-
125-
Error: failed to download modules: binary with name "go" not found
38+
$ GIT_USER=<Your GitHub username> yarn deploy
12639
```
12740

128-
This error occurs if you have not installed the `go` programming language on your system.
129-
See this [section](https://www.docsy.dev/docs/get-started/docsy-as-module/installation-prerequisites/#install-go-language) of the user guide for instructions on how to install `go`.
130-
131-
132-
[alternate dashboard]: https://app.netlify.com/sites/goldydocs/deploys
133-
[deploys]: https://app.netlify.com/sites/docsy-example/deploys
134-
[Docsy user guide]: https://docsy.dev/docs
135-
[Docsy]: https://github.com/google/docsy
136-
[example.docsy.dev]: https://example.docsy.dev
137-
[Hugo theme module]: https://gohugo.io/hugo-modules/use-modules/#use-a-module-for-a-theme
138-
[Netlify]: https://netlify.com
41+
If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch.

Diff for: babel.config.js

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module.exports = {
2+
presets: [require.resolve('@docusaurus/core/lib/babel/preset')],
3+
};

Diff for: blog/announcing-ois.md

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
---
2+
date: 2015-09-20 18:33:10
3+
title: "Announcing Open Infrastructure Services, LLC"
4+
authors: ["jmccune"]
5+
---
6+
7+
Hello, World!
8+
9+
I'm a little sad to say I've left [Puppet Labs][puppetlabs] after over 5 years
10+
working for the company and working on [Puppet][puppet]. It was a difficult
11+
decision, but I'm pleased to announce that I've decided to start my own
12+
independent consulting business, [Open Infrastructure Services, LLC][website].
13+
I'll be helping clients with their Puppet related problem while also focusing
14+
on bringing creative solutions to bear on complex infrastructures. Please
15+
[email me][email] for more information, I'd love to hear how I could help you
16+
and your business.
17+
18+
```puppet
19+
company { "Open Infrastructure Services, LLC":
20+
ensure => running,
21+
founder => "Jeff McCune",
22+
website => "http://openinfrastructure.co",
23+
email => "[email protected]",
24+
}
25+
```
26+
27+
[puppetlabs]: http://puppetlabs.com
28+
[email]: mailto://[email protected]
29+
[website]: http://openinfrastructure.co
30+
[puppet]: http://github.com/puppetlabs/puppet

Diff for: blog/authors.yml

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
endi:
2+
name: Endilie Yacop Sucipto
3+
title: Maintainer of Docusaurus
4+
url: https://github.com/endiliey
5+
image_url: https://github.com/endiliey.png
6+
7+
yangshun:
8+
name: Yangshun Tay
9+
title: Front End Engineer @ Facebook
10+
url: https://github.com/yangshun
11+
image_url: https://github.com/yangshun.png
12+
13+
slorber:
14+
name: Sébastien Lorber
15+
title: Docusaurus maintainer
16+
url: https://sebastienlorber.com
17+
image_url: https://github.com/slorber.png
18+
19+
jmccune:
20+
name: Jeff McCune
21+
title: CEO of Open Infrastructure Services
22+
url: https://github.com/jeffmccune
23+
image_url: https://github.com/jeffmccune.png
24+
25+
glarizza:
26+
name: Gary Larizza
27+
title: Principal Consultant
28+
url: https://github.com/glarizza
29+
image_url: https://github.com/glarizza.png

Diff for: blog/introducing-gary/index.md

+61
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
---
2+
title: "Welcome Gary Larizza"
3+
slug: welcome-gary
4+
date: 2017-10-21 12:06:00
5+
description: "Gary Larizza joins Open Infrastructure Services"
6+
authors: ["jmccune"]
7+
---
8+
9+
<!--
10+
Since Docusaurus uses MDX, below is an example of how you would
11+
resize an existing image by importing it and doing inline styling.
12+
13+
NOTE: You *NEED* the newline space between the import statement
14+
and the tag that uses it or else npm will raise an error.
15+
-->
16+
17+
import Gary from '/img/gary.png';
18+
19+
<img src={Gary} style={{width: 200}} align="left" hspace="20" vspace="20"/>
20+
21+
Open Infrastructure Services is growing! I'm excited to announce [Gary
22+
Larizza][gary], has joined Open Infrastructure Services as a Principal
23+
Consultant. Gary and I first started working together on Puppet back in 2010 in
24+
Portland, Oregon. From that first day working together I was struck by Gary's
25+
attitude and desire to dive deep in the guts of Puppet to figure out what's
26+
_really_ going on. Fast forward to 2017, and I've found myself visiting [Shit
27+
Gary Says][garyblog] on a daily basis while working on Puppet types and
28+
providers. Gary's ability to assimilate complex information, distill that
29+
information into the essential bits customers value, and communicate that
30+
essential information with humor and empathy has been invaluable to me
31+
personally. A great example of this depth, humor, and empathy is, [Seriously,
32+
what is this provider doing?][garyprovider]
33+
34+
Gary and I both started out working in education in Ohio, though separately from
35+
one another. We were bought together in Portland, OR by two australians from
36+
the other side of the world, Nigel Kersten and James Turnbull.
37+
38+
Gary and I share that special bond that only comes from successfully dealing
39+
with a classroom full of computers delivered a couple of weeks before school
40+
starts with the latest and greatest Mac OS X major release, chock full of
41+
changes and new surprises.
42+
43+
Please check out Gary's post, [Some Other Beginning's End][garypost] on this new
44+
beginning for both of us.
45+
46+
[Contact][contact] us with your automation and cloud infrastructure goals. We'd
47+
both love to help you handle changes faster and more confidently through
48+
automated cloud infrastructure.
49+
50+
Gary is also a [Puppet][puppet] certified consultant and a member of the Puppet
51+
Services Delivery Partner Program. We're here to help achieve your goals
52+
whether you're expanding your Puppet investment, upgrading to the latest version
53+
and language features, or just getting started.
54+
55+
[puppet]: https://puppet.com/product
56+
[gary]: http://garylarizza.com/
57+
[garyblog]: http://garylarizza.com/blog/
58+
[garypost]: http://garylarizza.com/blog/2017/08/25/some-other-beginnings-end/
59+
[garyprovider]: http://garylarizza.com/blog/2013/12/15/seriously-what-is-this-provider-doing/
60+
[avatar]: /img/gary-460.png
61+
[contact]: /#contact

Diff for: blog/introducing-nate/index.md

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
---
2+
title: "Welcome Nate McCurdy"
3+
slug: welcome-nate
4+
date: 2018-12-03 12:00:00
5+
description: "Nate McCurdy joins Open Infrastructure Services"
6+
authors: ["jmccune"]
7+
---
8+
9+
import Nate from '/img/nate.jpg';
10+
11+
<img src={Nate} style={{width: 200}} align="left" hspace="20" vspace="20"/>
12+
13+
14+
Open Infrastructure Services is growing! I'm excited to announce [Nate
15+
McCurdy][nate], has joined Open Infrastructure Services as a Cloud
16+
Infrastructure Consultant. Nate brings over a decade of experience helping
17+
companies with their digital transformation, configuration management, and
18+
breaking down walls between development and operations teams.
19+
20+
Nate is also a [Google][google] certified Cloud Architect and helping streamline
21+
large enterprise hybrid clouds to date.
22+
23+
[nate]: https://github.com/natemccurdy
24+
[google]: https://cloud.google.com/certification/cloud-architect

0 commit comments

Comments
 (0)