Skip to content

Commit 2aed60f

Browse files
authored
Merge branch 'master' into fix/edit_this_page_link
2 parents 7d49bff + 83c66fe commit 2aed60f

220 files changed

Lines changed: 17731 additions & 6818 deletions

File tree

Some content is hidden

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

.github/workflows/slack.yml

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -15,22 +15,27 @@ jobs:
1515
- name: Get current star count
1616
run: |
1717
echo "STARS=$(curl --silent 'https://api.github.com/repos/${{ github.repository }}' -H 'Accept: application/vnd.github.preview' | jq '.stargazers_count')" >> $GITHUB_ENV
18+
1819
- name: Notify Slack
19-
env:
20-
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
21-
uses: pullreminders/slack-action@master
20+
uses: slackapi/slack-github-action@v2.1.1
2221
with:
23-
args: '{\"channel\":\"CSK7N9TGX\",\"text\":\"${{ github.actor }} just starred ${{ github.repository }}! (https://github.com/${{ github.repository }}/stargazers) Total ⭐️: ${{ env.STARS }}\"}'
22+
method: chat.postMessage
23+
token: ${{ secrets.SLACK_BOT_TOKEN }}
24+
payload: |
25+
channel: CSK7N9TGX
26+
type: "mrkdwn"
27+
text: "<https://github.com/${{ github.actor }}|${{ github.actor }}> just starred <https://github.com/${{ github.repository }}/stargazers|${{ github.repository }}> bringing the total ⭐️ count up to: ${{ env.STARS }}"
2428
2529
good-first-issue-notify:
2630
if: github.event_name == 'issues' && (github.event.label.name == 'good first issue' || github.event.label.name == 'first-timers-only')
2731
name: Notify Slack for new good-first-issue
2832
runs-on: ubuntu-latest
2933
steps:
3034
- name: Notify Slack
31-
env:
32-
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
33-
uses: pullreminders/slack-action@master
35+
uses: slackapi/slack-github-action@v2.1.1
3436
with:
35-
args: '{\"channel\":\"C019426UBNY\",\"type\":\"section\",\"text\":\":new: Good first issue up for grabs: ${{ github.event.issue.title }} - ${{ github.event.issue.html_url }} \"}'
36-
37+
method: chat.postMessage
38+
token: ${{ secrets.SLACK_BOT_TOKEN }}
39+
payload: |
40+
channel: C019426UBNY
41+
text: ":new: Good first issue up for grabs: <${{ github.event.issue.html_url }}|${{ github.event.issue.title }}>"

AGENTS.md

Lines changed: 141 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,141 @@
1+
# AGENTS.md
2+
3+
This document provides instructions for Large Language Models (LLMs) contributing to the Layer5 website, hosted at https://github.com/layer5io/layer5, built with Gatsby.js. These guidelines ensure consistency, quality, and alignment with the project's goals of promoting cloud native infrastructure management through clear documentation and user-friendly content.
4+
5+
## Project Overview
6+
7+
The Layer5 website (https://layer5.io) is a Gatsby.js-based static site that serves as the primary interface for the Layer5 community. It showcases projects like Meshery, Kanvas, and Cloud Native Patterns, and provides resources for contributors, users, and cloud native enthusiasts. The site emphasizes clean design, fast performance, and accessibility.
8+
9+
## Instructions for LLMs
10+
11+
### 1. Content Generation Guidelines
12+
13+
- **Tone and Style**: Use a professional yet approachable tone. Content should be clear, concise, and welcoming to both technical and non-technical audiences. Align with Layer5's mission of empowering engineers to "expect more from their infrastructure."
14+
- **Markdown Usage**: All content must be written in Markdown, adhering to Gatsby's content structure (e.g., MDX files in `src/pages` or `src/content`).
15+
- **Frontmatter**: Include appropriate frontmatter in MDX files. Example:
16+
17+
```yaml
18+
---
19+
title: "Page Title"
20+
path: "/path/to/page"
21+
date: "2025-09-23"
22+
description: "Short description for SEO."
23+
---
24+
```
25+
- **SEO Optimization**: Ensure all generated content includes meta descriptions, relevant keywords (e.g., "cloud native," "Meshery," "service mesh"), and proper heading structures (H1, H2, etc.).
26+
- **Consistency**: Use American English spelling and grammar. Follow the Layer5 Writing Style Guide for terminology (e.g., "Meshery" not "meshery").
27+
28+
### 2. Code Contributions
29+
30+
- **Gatsby.js Structure**: Familiarize yourself with the repository structure:
31+
- `src/components`: Reusable React components.
32+
- `src/pages`: Page templates and MDX content.
33+
- `gatsby-config.js`: Site metadata and plugins.
34+
- `gatsby-node.js`: Dynamic page generation logic.
35+
- **React Components**: When generating components, use functional components with modern JavaScript (ES6+). Example:
36+
37+
```jsx
38+
import React from 'react';
39+
40+
const MyComponent = ({ title }) => (
41+
<div className="my-component">
42+
<h2>{title}</h2>
43+
</div>
44+
);
45+
46+
export default MyComponent;
47+
```
48+
- **Styling**: Use CSS modules or styled-components as per the project's conventions. Prefer Tailwind CSS classes if integrated. Example:
49+
50+
```jsx
51+
<div className="bg-blue-500 text-white p-4">Content</div>
52+
```
53+
- **Accessibility**: Ensure all components meet WCAG 2.1 standards (e.g., alt text for images, ARIA labels where needed).
54+
55+
### 3. Contribution Workflow
56+
57+
- **Pull Requests**: All changes must be submitted as pull requests (PRs) to the `master` branch. Follow the Layer5 Contributing Guidelines.
58+
- **Commit Messages**: Use clear, descriptive commit messages following the Conventional Commits format:
59+
60+
```
61+
feat: add new Meshery feature page
62+
fix: correct broken link in footer
63+
docs: update AGENTS.md with LLM instructions
64+
```
65+
- **Testing**: Ensure generated code passes `make setup` and `make site` without errors. Test for responsiveness across devices.
66+
- Verifying your fix: The website takes a long time to build. Don't interrupt the build when checking terminal output. Don't hail victory on a fix before you have ACTUALLY verified the solution. Wait for the website to be running, for you to actually \`curl\` a page and verify rendered content.
67+
68+
### 4. Content Restrictions
69+
70+
- **No External Images**: Do not include external image URLs in Markdown or components. Use local assets in `src/images`.
71+
- **No Placeholder Text**: Avoid placeholders like `[Your Name]` or `[Insert Content]`. Provide complete, usable content.
72+
- **No Sensitive Data**: Do not include API keys, credentials, or personal information in generated content.
73+
74+
### 5. Specific Tasks for LLMs
75+
76+
- **Documentation Updates**: Generate or update MDX files in `src/content` for tutorials, blog posts, or project documentation. Ensure alignment with Layer5's Documentation Guidelines.
77+
- **Blog Posts**: Create blog posts about cloud native topics, Meshery features, or community events. Example structure:
78+
79+
```markdown
80+
---
81+
title: "Exploring Meshery's New Features in 2025"
82+
path: "/blog/meshery-new-features-2025"
83+
date: "2025-09-23"
84+
description: "Discover the latest updates to Meshery, the cloud native management platform."
85+
---
86+
# Exploring Meshery's New Features in 2025
87+
## Introduction
88+
Meshery continues to evolve as the leading platform for...
89+
```
90+
- **Component Generation**: Create reusable React components for UI elements like buttons, cards, or modals, ensuring they match the site's design system.
91+
92+
### 6. Validation and Testing
93+
94+
- **Linting**: Run `npm run lint` to ensure code adheres to ESLint and Prettier rules.
95+
- **Build Testing**: Verify that `gatsby build` completes successfully.
96+
- **Preview**: Test changes locally with `gatsby develop` and check for visual/functional issues.
97+
98+
### 7. Community Alignment
99+
100+
- **CNCF Code of Conduct**: All contributions must adhere to the CNCF Code of Conduct.
101+
- **Engage with MeshMates**: For guidance, reference the MeshMates program in the Layer5 Community Handbook.
102+
103+
## Example Contribution
104+
105+
Below is an example of a new MDX page for the Layer5 website:
106+
107+
```markdown
108+
---
109+
title: "Getting Started with Meshery"
110+
path: "/learn/getting-started"
111+
date: "2025-09-23"
112+
description: "A beginner's guide to setting up Meshery for cloud native management."
113+
---
114+
# Getting Started with Meshery
115+
Meshery is an open-source cloud native management platform that simplifies...
116+
117+
## Installation
118+
1. Install Meshery CLI using:
119+
```bash
120+
curl -L https://meshery.io/install | bash -
121+
```
122+
123+
2. Verify installation:
124+
125+
```bash
126+
mesheryctl system check
127+
```
128+
129+
## Next Steps
130+
131+
Explore Meshery Docs for advanced configurations.
132+
133+
```
134+
135+
## Troubleshooting
136+
- **Build Errors**: Check `gatsby-config.js` for plugin misconfigurations.
137+
- **Content Issues**: Validate MDX syntax using `npm run develop`.
138+
- **Community Support**: Reach out via the [Layer5 Slack](https://slack.layer5.io) for assistance.
139+
140+
By following these guidelines, LLMs can contribute high-quality content and code to the Layer5 website, enhancing its role as a hub for the cloud native community.
141+
```

gatsby-config.js

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ module.exports = {
1313
},
1414
flags: {
1515
FAST_DEV: true,
16-
PARALLEL_SOURCING: true,
16+
PARALLEL_SOURCING: false, // Disable parallel sourcing to reduce memory pressure
1717
},
1818
trailingSlash: "never",
1919
plugins: [
@@ -134,7 +134,6 @@ module.exports = {
134134
) {
135135
nodes {
136136
body
137-
html
138137
frontmatter {
139138
title
140139
author
@@ -181,7 +180,6 @@ module.exports = {
181180
) {
182181
nodes {
183182
body
184-
html
185183
frontmatter {
186184
title
187185
author
@@ -227,7 +225,6 @@ module.exports = {
227225
) {
228226
nodes {
229227
body
230-
html
231228
frontmatter {
232229
title
233230
author
@@ -276,7 +273,6 @@ module.exports = {
276273
) {
277274
nodes {
278275
body
279-
html
280276
frontmatter {
281277
title
282278
author
@@ -336,7 +332,6 @@ module.exports = {
336332
) {
337333
nodes {
338334
body
339-
html
340335
frontmatter {
341336
title
342337
author
@@ -387,7 +382,6 @@ module.exports = {
387382
) {
388383
nodes {
389384
body
390-
html
391385
frontmatter {
392386
title
393387
author
@@ -434,7 +428,6 @@ module.exports = {
434428
) {
435429
nodes {
436430
body
437-
html
438431
frontmatter {
439432
title
440433
author
@@ -473,8 +466,15 @@ module.exports = {
473466
resolve: "gatsby-plugin-mdx",
474467
options: {
475468
extensions: [".mdx", ".md"],
469+
gatsbyRemarkPlugins: [],
470+
mdxOptions: {
471+
remarkPlugins: [],
472+
rehypePlugins: [],
473+
},
476474
},
477475
},
476+
"gatsby-plugin-sharp",
477+
"gatsby-transformer-sharp",
478478
{
479479
resolve: "gatsby-source-filesystem",
480480
options: {
@@ -628,7 +628,13 @@ module.exports = {
628628
policy: [{ userAgent: "*", allow: "/" }],
629629
},
630630
},
631+
{
632+
resolve: "gatsby-plugin-purgecss",
633+
options: {
634+
printRejected: true,
635+
}
636+
},
631637
"gatsby-plugin-meta-redirect",
632638
// make sure this is always the last one
633639
],
634-
};
640+
};

0 commit comments

Comments
 (0)