Skip to content

Commit 7ed162b

Browse files
authored
feat(docs): add docs to semaphoreio repo (#163)
1 parent 6e87466 commit 7ed162b

File tree

1,075 files changed

+159560
-0
lines changed

Some content is hidden

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

1,075 files changed

+159560
-0
lines changed

.semaphore/daily-builds.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -539,6 +539,52 @@ blocks:
539539
- name: "\U0001F9EA Test"
540540
commands:
541541
- make test.ex
542+
# Docs
543+
- name: "Docs: \U0001F5BC️ Provision Prod Image"
544+
dependencies: []
545+
task:
546+
env_vars:
547+
- name: APP_ENV
548+
value: prod
549+
jobs:
550+
- name: "Image Build"
551+
commands:
552+
- checkout
553+
- cd docs
554+
- make build
555+
- make push
556+
- name: "Docs: \U0001F5BC️ Build test image"
557+
dependencies: []
558+
task:
559+
env_vars:
560+
- name: APP_ENV
561+
value: dev
562+
jobs:
563+
- name: "Image Build"
564+
commands:
565+
- checkout
566+
- cd docs
567+
- make build
568+
- make push
569+
- name: "Docs: \U0001F9EA QA"
570+
dependencies: ["Docs: \U0001F5BC️ Build test image"]
571+
task:
572+
env_vars:
573+
- name: APP_ENV
574+
value: dev
575+
prologue:
576+
commands:
577+
- checkout
578+
- cd docs
579+
- make pull
580+
- make build
581+
jobs:
582+
- name: Lint
583+
commands:
584+
- make lint
585+
- name: Test
586+
commands:
587+
- make test
542588
# Front
543589
- name: "Front: \U0001F5BC️ Provision Test Image"
544590
dependencies: []

.semaphore/semaphore.yml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -586,6 +586,58 @@ blocks:
586586
- name: "\U0001F9EA Test"
587587
commands:
588588
- make test.ex
589+
# Docs
590+
- name: "Docs: \U0001F5BC️ Provision Prod Image"
591+
dependencies: []
592+
run:
593+
when: "change_in('/docs', {default_branch: 'main'})"
594+
task:
595+
env_vars:
596+
- name: APP_ENV
597+
value: prod
598+
jobs:
599+
- name: "Image Build"
600+
commands:
601+
- checkout
602+
- cd docs
603+
- make build
604+
- make push
605+
- name: "Docs: \U0001F5BC️ Build test image"
606+
dependencies: []
607+
run:
608+
when: "change_in('/docs', {default_branch: 'main'})"
609+
task:
610+
env_vars:
611+
- name: APP_ENV
612+
value: dev
613+
jobs:
614+
- name: "Image Build"
615+
commands:
616+
- checkout
617+
- cd docs
618+
- make build
619+
- make push
620+
- name: "Docs: \U0001F9EA QA"
621+
dependencies: ["Docs: \U0001F5BC️ Build test image"]
622+
run:
623+
when: "change_in('/docs', {default_branch: 'main'})"
624+
task:
625+
env_vars:
626+
- name: APP_ENV
627+
value: dev
628+
prologue:
629+
commands:
630+
- checkout
631+
- cd docs
632+
- make pull
633+
- make build
634+
jobs:
635+
- name: Lint
636+
commands:
637+
- make lint
638+
- name: Test
639+
commands:
640+
- make test
589641
# Front
590642
- name: "Front: \U0001F5BC️ Provision Test Image"
591643
dependencies: []

.semaphore/services.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,12 @@
4848
"component": "dashboardhub"
4949
}
5050
],
51+
"Docs": [
52+
{
53+
"path": "docs",
54+
"component": "docs-v2"
55+
}
56+
],
5157
"Encryptor": [
5258
{
5359
"path": "encryptor",

docs/.gitignore

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Dependencies
2+
/node_modules
3+
4+
# Production
5+
/build
6+
7+
# Generated files
8+
.docusaurus
9+
.cache-loader
10+
11+
# Misc
12+
.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*

docs/.markdownlint.json

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"default": true,
3+
"line-length": false,
4+
"single-trailing-newline": false,
5+
"no-trailing-punctuation": false,
6+
"no-duplicate-heading": false,
7+
"no-trailing-spaces": false,
8+
"blanks-around-fences": false,
9+
"blanks-around-lists": false,
10+
"no-multiple-blanks": false,
11+
"no-inline-html": false,
12+
"code-block-style": false,
13+
"no-bare-urls": false,
14+
"emphasis-style": false,
15+
"single-title": { "front_matter_title": "$disable" }
16+
}

docs/CODE_OF_CONDUCT.md

Lines changed: 128 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,128 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
We as members, contributors, and leaders pledge to make participation in our
6+
community a harassment-free experience for everyone, regardless of age, body
7+
size, visible or invisible disability, ethnicity, sex characteristics, gender
8+
identity and expression, level of experience, education, socio-economic status,
9+
nationality, personal appearance, race, religion, or sexual identity
10+
and orientation.
11+
12+
We pledge to act and interact in ways that contribute to an open, welcoming,
13+
diverse, inclusive, and healthy community.
14+
15+
## Our Standards
16+
17+
Examples of behavior that contributes to a positive environment for our
18+
community include:
19+
20+
* Demonstrating empathy and kindness toward other people
21+
* Being respectful of differing opinions, viewpoints, and experiences
22+
* Giving and gracefully accepting constructive feedback
23+
* Accepting responsibility and apologizing to those affected by our mistakes,
24+
and learning from the experience
25+
* Focusing on what is best not just for us as individuals, but for the
26+
overall community
27+
28+
Examples of unacceptable behavior include:
29+
30+
* The use of sexualized language or imagery, and sexual attention or
31+
advances of any kind
32+
* Trolling, insulting or derogatory comments, and personal or political attacks
33+
* Public or private harassment
34+
* Publishing others' private information, such as a physical or email
35+
address, without their explicit permission
36+
* Other conduct which could reasonably be considered inappropriate in a
37+
professional setting
38+
39+
## Enforcement Responsibilities
40+
41+
Community leaders are responsible for clarifying and enforcing our standards of
42+
acceptable behavior and will take appropriate and fair corrective action in
43+
response to any behavior that they deem inappropriate, threatening, offensive,
44+
or harmful.
45+
46+
Community leaders have the right and responsibility to remove, edit, or reject
47+
comments, commits, code, wiki edits, issues, and other contributions that are
48+
not aligned to this Code of Conduct, and will communicate reasons for moderation
49+
decisions when appropriate.
50+
51+
## Scope
52+
53+
This Code of Conduct applies within all community spaces, and also applies when
54+
an individual is officially representing the community in public spaces.
55+
Examples of representing our community include using an official e-mail address,
56+
posting via an official social media account, or acting as an appointed
57+
representative at an online or offline event.
58+
59+
## Enforcement
60+
61+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
62+
reported to the community leaders responsible for enforcement at
63+
64+
All complaints will be reviewed and investigated promptly and fairly.
65+
66+
All community leaders are obligated to respect the privacy and security of the
67+
reporter of any incident.
68+
69+
## Enforcement Guidelines
70+
71+
Community leaders will follow these Community Impact Guidelines in determining
72+
the consequences for any action they deem in violation of this Code of Conduct:
73+
74+
### 1. Correction
75+
76+
**Community Impact**: Use of inappropriate language or other behavior deemed
77+
unprofessional or unwelcome in the community.
78+
79+
**Consequence**: A private, written warning from community leaders, providing
80+
clarity around the nature of the violation and an explanation of why the
81+
behavior was inappropriate. A public apology may be requested.
82+
83+
### 2. Warning
84+
85+
**Community Impact**: A violation through a single incident or series
86+
of actions.
87+
88+
**Consequence**: A warning with consequences for continued behavior. No
89+
interaction with the people involved, including unsolicited interaction with
90+
those enforcing the Code of Conduct, for a specified period of time. This
91+
includes avoiding interactions in community spaces as well as external channels
92+
like social media. Violating these terms may lead to a temporary or
93+
permanent ban.
94+
95+
### 3. Temporary Ban
96+
97+
**Community Impact**: A serious violation of community standards, including
98+
sustained inappropriate behavior.
99+
100+
**Consequence**: A temporary ban from any sort of interaction or public
101+
communication with the community for a specified period of time. No public or
102+
private interaction with the people involved, including unsolicited interaction
103+
with those enforcing the Code of Conduct, is allowed during this period.
104+
Violating these terms may lead to a permanent ban.
105+
106+
### 4. Permanent Ban
107+
108+
**Community Impact**: Demonstrating a pattern of violation of community
109+
standards, including sustained inappropriate behavior, harassment of an
110+
individual, or aggression toward or disparagement of classes of individuals.
111+
112+
**Consequence**: A permanent ban from any sort of public interaction within
113+
the community.
114+
115+
## Attribution
116+
117+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
118+
version 2.0, available at
119+
https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
120+
121+
Community Impact Guidelines were inspired by [Mozilla's code of conduct
122+
enforcement ladder](https://github.com/mozilla/diversity).
123+
124+
[homepage]: https://www.contributor-covenant.org
125+
126+
For answers to common questions about this code of conduct, see the FAQ at
127+
https://www.contributor-covenant.org/faq. Translations are available at
128+
https://www.contributor-covenant.org/translations.

docs/Dockerfile

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
ARG RUNNER_IMAGE=nginx
2+
3+
# Build stage
4+
FROM node AS builder
5+
WORKDIR /app
6+
7+
COPY package.json package.json
8+
COPY package-lock.json package-lock.json
9+
COPY yarn.lock yarn.lock
10+
COPY babel.config.js babel.config.js
11+
COPY docusaurus.config.js docusaurus.config.js
12+
COPY sidebars.js sidebars.js
13+
COPY versions.json versions.json
14+
COPY docs docs
15+
COPY docs-drafts docs-drafts
16+
COPY src src
17+
COPY static static
18+
COPY versioned_docs versioned_docs
19+
COPY versioned_sidebars versioned_sidebars
20+
COPY .markdownlint.json .markdownlint.json
21+
22+
RUN npm install --frozen-lockfile
23+
RUN npm run clear
24+
RUN npm run build
25+
26+
# Dev stage with both Node.js and Nginx
27+
FROM builder AS dev
28+
29+
WORKDIR /app
30+
31+
RUN apt-get update && apt-get install --no-install-recommends -y nginx \
32+
&& rm -rf /var/lib/apt/lists/*
33+
34+
COPY --from=builder /app /app
35+
COPY default.conf /etc/nginx/conf.d/default.conf
36+
COPY --from=builder /app/build/ /usr/share/nginx/html/
37+
38+
CMD ["nginx", "-g", "daemon off;"]
39+
40+
# Runner
41+
FROM ${RUNNER_IMAGE} AS runner
42+
43+
WORKDIR /app
44+
45+
ADD default.conf /etc/nginx/conf.d/default.conf
46+
COPY --from=builder /app/build/ /usr/share/nginx/html/
47+
48+

docs/Makefile

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
include ../Makefile
2+
3+
APP_NAME=docs-v2
4+
APP_ENV?=dev
5+
6+
npm.dev:
7+
npm start
8+
9+
npm.lint:
10+
npm run lint
11+
12+
npm.build:
13+
npm run build
14+
15+
lint:
16+
docker run --rm -t -a stdout $(IMAGE):$(IMAGE_TAG) npm run lint
17+
18+
test:
19+
docker run --rm -t -a stdout $(IMAGE):$(IMAGE_TAG) nginx -c /etc/nginx/nginx.conf -t
20+

docs/README.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# Semaphore Docs
2+
3+
This repo contains the source for the Semaphore docs site, including the content of the docs and docs engine.
4+
5+
If you notice that something is vague, inaccurate, or incomplete about the documentation, or have an idea for a great guide, we encourage you to create a GitHub issue in this repository using our [issue template](./).
6+
7+
## Contribution
8+
9+
To learn how to contribute to the Semaphore docs site, please refer to the following guides:
10+
11+
- [How to Contribute](./docs-contributing/CONTRIBUTING.md): A comprehensive guide to making changes to the Semaphore documentation.
12+
- [How to Review](./docs-contributing/REVIEWING.md): Instructions on how to set up a local preview site to review documentation changes.
13+
- [Style Guide](./docs-contributing/STYLE_GUIDE.md): Guidelines for maintaining consistency in the Semaphore documentation.
14+
- [UI Reference](./docs-contributing/UI-REFERENCE.md): A reference for UI components available to documentation authors.
15+
16+
## Top Contributors
17+
18+
Contributors list is WIP
19+
20+
## Ongoing work
21+
22+
👉 [Help Wanted Board](https://github.com/orgs/semaphoreci/projects/2/views/7) 👈
23+
24+
## SIG meetings
25+
26+
Documentation team meets weekly. Meeting agenda is always published one week prior. All contributors are welcome, open an issue to join the SIG and get a calendar invite.
27+
28+
- 💬 [Join the Discord channel](https://discord.gg/FBuUrV24NH)
29+
- 📆 Every `Monday` at `1pm UTC`
30+
- 📝 [Meeting minutes](https://github.com/semaphoreci/semaphore/blob/main/docs/docs-contributing/meeting-notes.md)
31+
- 🙋‍♂️ [Join the SIG](https://forms.gle/tcNpGA4Zyghnu7sh8) < select `SIG - Docummentation` when filling in form.
32+
33+
## License
34+
35+
All Semaphore documentation and any resources under `/docs/` folder fall under the Apache v2 license present at the root of this repository.

0 commit comments

Comments
 (0)