Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/components/Header/Header.astro
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ const primaryLink = isEnterpriseSection
margin: 0;
}

@media (max-width: 87em) {
@media (max-width: 68em) {
.nav-buttons {
display: none !important;
}
Expand Down
10 changes: 8 additions & 2 deletions src/components/PageContent/PageContent.astro
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
import { CollectionEntry } from 'astro:content';
import type { CollectionEntry } from 'astro:content';
export interface Props {
content: CollectionEntry<'docs'>['data'];
}
Expand All @@ -18,7 +18,13 @@ const suppressTitle = content.suppressTitle;
<section class="main-section">
<header>
<slot name="before-title" />
{!suppressTitle && <h1 class="content-title" id="overview" set:html={title} />}
{!suppressTitle && (
<h1
class:list={['content-title', content.hubAccent && 'hero-accent']}
id="overview"
set:html={title}
/>
)}
{!suppressTitle && (
<h2 class="content-subtitle" data-toc-ignore set:html={description} />
)}
Expand Down
42 changes: 33 additions & 9 deletions src/components/RightSidebar/RightSidebar.astro
Original file line number Diff line number Diff line change
@@ -1,30 +1,54 @@
---
import generateToc from '../../util/generateToc';
import PageFeedback from '../PageFeedback.astro';
import TableOfContents from './TableOfContents';

const { headings } = Astro.props;
---

<nav aria-label={'Secondary'}>
{
headings && (
{
headings && (
<nav aria-label={'Secondary'}>
<TableOfContents
client:media="(min-width: 50em)"
toc={generateToc(headings)}
labels={{ onThisPage: 'On this page' }}
isMobile={false}
/>
)
}
</nav>
</nav>
)
}

<div class="page-actions">
<PageFeedback />
</div>

<style>
nav {
nav,
.page-actions {
width: 100%;
padding-block: var(--doc-padding-block);
padding-inline-end: var(--min-spacing-inline);
padding-inline-start: 0;
overflow: auto;
font-size: var(--theme-text-md);
}
nav {
padding-block: var(--doc-padding-block);
overflow: auto;
}
.page-actions {
margin-top: 2rem;
margin-bottom: 2rem;
padding-top: 1.25rem;
border-top: 1px solid var(--theme-divider);
display: flex;
flex-direction: column;
gap: 1rem;
}
/* PageFeedback was designed for the article footer with its own
margin-top + padding-top. Inside .page-actions those are redundant
(the wrapper already separates from the ToC), so zero them out. */
.page-actions :global(.page-feedback) {
margin-top: 0;
padding-top: 0;
}
</style>
1 change: 1 addition & 0 deletions src/content.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ const docs = defineCollection({
title: z.string(),
description: z.string(),
suppressTitle: z.boolean().optional(),
hubAccent: z.boolean().optional(),
}),
});

Expand Down
1 change: 1 addition & 0 deletions src/content/docs/ci-insights.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
title: CI Insights
description: Optimize your CI run time, catch flaky tests, and give developers actionable insights so your team ships code faster.
hubAccent: true
---

import Docset from '../../components/DocsetGrid/Docset.astro';
Expand Down
93 changes: 46 additions & 47 deletions src/content/docs/enterprise/advanced-features.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ MERGIFYENGINE_LOG_DATADOG=udp://<my-datadog-agent-host>:10518

CI test traces can be exported to Mergify CI Insights and Test Insights by backing these features
with object storage. Set `MERGIFYENGINE_CI_TRACES_BACKEND` and bucket credentials according to your
provider. Both providers support two authentication modes: a static credential set you manage
yourself, or automatic discovery through your cloud workload identity (recommended when running
on GKE, EKS, GCE, or EC2 to avoid manual key rotation).
provider. Both providers support two authentication modes: automatic discovery through your cloud
workload identity (recommended when running on GKE, EKS, GCE, or EC2 to avoid manual key rotation),
or a static credential set you manage yourself.

### Google Cloud Storage

Expand All @@ -69,21 +69,7 @@ MERGIFYENGINE_CI_TRACES_INCOMING_BUCKET="<mycompany>-mergify-ci-traces-incoming"
MERGIFYENGINE_CI_TRACES_DONE_BUCKET="<mycompany>-mergify-ci-traces-done"
```

#### Option A: Service Account JSON key

Generate a JSON key for the Service Account and base64-encode it:

```sh
base64 < credentials.json | tr -d '\n'
```

Add the encoded key to the engine:

```ini
MERGIFYENGINE_GCS_CREDENTIALS="base64-encoded-credentials-json"
```

#### Option B: Application Default Credentials
#### Option A: Application Default Credentials (recommended)

Set `MERGIFYENGINE_GCS_CREDENTIALS="auto"` to let Mergify resolve credentials from the Google
[Application Default Credentials](https://cloud.google.com/docs/authentication/application-default-credentials)
Expand All @@ -100,6 +86,20 @@ Bind the Kubernetes Service Account that runs the engine to the Google Service A
bucket access. Google issues and rotates the credentials automatically, so no further
configuration is needed.

#### Option B: Service Account JSON key

Generate a JSON key for the Service Account and base64-encode it:

```sh
base64 < credentials.json | tr -d '\n'
```

Add the encoded key to the engine:

```ini
MERGIFYENGINE_GCS_CREDENTIALS="base64-encoded-credentials-json"
```

### Amazon S3

Requirements:
Expand All @@ -109,44 +109,26 @@ Requirements:

- An IAM identity with read/write/delete rights on those buckets

Common settings. Mergify reads the standard AWS environment variables, so no `MERGIFYENGINE_`
prefix is required:
Mergify reads the standard AWS environment variables, so no `MERGIFYENGINE_` prefix is required
for the common settings below:

```ini
MERGIFYENGINE_CI_TRACES_BACKEND="s3"
MERGIFYENGINE_CI_TRACES_INCOMING_BUCKET="<mycompany>-mergify-ci-traces-incoming"
MERGIFYENGINE_CI_TRACES_DONE_BUCKET="<mycompany>-mergify-ci-traces-done"
AWS_ACCOUNT_ID=123456789012
# Optional
AWS_REGION=us-west-2
# Custom S3 implementation endpoint
AWS_ENDPOINT_URL_S3=https://my-s3-domain.example.com:1234/
```

:::note
The `MERGIFYENGINE_AWS_*` variants (`MERGIFYENGINE_AWS_ACCOUNT_ID`,
`MERGIFYENGINE_AWS_ACCESS_KEY_ID`, `MERGIFYENGINE_AWS_SECRET_ACCESS_KEY`,
`MERGIFYENGINE_AWS_REGION_NAME`, `MERGIFYENGINE_AWS_ENDPOINT_URL_S3`) are still accepted for
backwards compatibility but are deprecated. Prefer the unprefixed `AWS_*` names. They are the
same variables the AWS CLI and SDKs use.
:::

#### Option A: IAM user access key

Create an IAM user, attach a policy granting access to the two buckets, generate an access key,
and provide it to the engine:

```ini
AWS_ACCESS_KEY_ID=<access-key-id>
AWS_SECRET_ACCESS_KEY=<secret-access-key>
```
#### Option A: IAM role discovery (recommended)

#### Option B: IAM role discovery
Mergify uses the standard
[boto3 credential chain](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html)
to resolve credentials. Attach an IAM role granting access to the two buckets to the workload
running the engine, and there is nothing else to configure. AWS issues and rotates short-lived
credentials automatically, so no key rotation is required.

Leave both `AWS_ACCESS_KEY_ID` and `AWS_SECRET_ACCESS_KEY` unset. Mergify falls back to the
standard
[boto3 credential chain](https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html),
which can resolve credentials from any of:
The credential chain can resolve credentials from any of:

- IAM Roles for Service Accounts ([IRSA](https://docs.aws.amazon.com/eks/latest/userguide/iam-roles-for-service-accounts.html))
or [EKS Pod Identity](https://docs.aws.amazon.com/eks/latest/userguide/pod-identities.html)
Expand All @@ -158,8 +140,25 @@ which can resolve credentials from any of:

- A profile or shared credentials file mounted into the container

Attach an IAM role granting access to the two buckets to the workload running the engine. AWS
issues and rotates short-lived credentials automatically, so no key rotation is required.
#### Option B: IAM user access key

Create an IAM user, attach a policy granting access to the two buckets, generate an access key,
and provide it to the engine:

```ini
AWS_ACCESS_KEY_ID=<access-key-id>
AWS_SECRET_ACCESS_KEY=<secret-access-key>
# Optional
AWS_REGION=us-west-2
```

:::note
The `MERGIFYENGINE_AWS_*` variants (`MERGIFYENGINE_AWS_ACCESS_KEY_ID`,
`MERGIFYENGINE_AWS_SECRET_ACCESS_KEY`, `MERGIFYENGINE_AWS_REGION_NAME`,
`MERGIFYENGINE_AWS_ENDPOINT_URL_S3`, `MERGIFYENGINE_AWS_ACCOUNT_ID`) are still accepted for
backwards compatibility but are deprecated. Prefer the unprefixed `AWS_*` names. The standard
names match what the AWS CLI and SDKs use; `AWS_ACCOUNT_ID` is no longer required for S3 access.
:::

## Slack Integration

Expand Down
6 changes: 3 additions & 3 deletions src/content/docs/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ import mergeQueueHero from './images/merge-queue-hero.jpg';
{/* -------------- PROBLEM CARDS -------------- */}

<section class="home-problems">
<h2 class="no-counter">What problem are you solving?</h2>
<h2>What problem are you solving?</h2>
<div class="home-problems-grid">
<a href="/merge-queue" class="home-problem-card" data-product="merge-queue">
<div class="home-problem-title">Broken main, slow merges</div>
Expand Down Expand Up @@ -91,7 +91,7 @@ import mergeQueueHero from './images/merge-queue-hero.jpg';
{/* -------------- PRODUCTS -------------- */}

<section id="products" class="home-products">
<h2 class="no-counter">Products</h2>
<h2>Products</h2>
<div class="home-products-grid">
<DocsetGrid>
<Docset title="Merge Queue" path="/merge-queue" icon="mergify:merge-queue">
Expand Down Expand Up @@ -141,7 +141,7 @@ import mergeQueueHero from './images/merge-queue-hero.jpg';
{/* -------------- COMMUNITY -------------- */}

<section class="community">
<h2 class="no-counter">Community</h2>
<h2>Community</h2>
<p>Share feedback, ask questions, and see what other teams build with Mergify.</p>
<div class="community-buttons">
<CommunityButton href="https://github.com/Mergifyio/mergify/discussions" icon="simple-icons:github" />
Expand Down
1 change: 1 addition & 0 deletions src/content/docs/merge-queue.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
title: Merge Queue
description: Ship faster with zero broken builds. Parallel testing, smart batching, and CI cost optimization.
hubAccent: true
---

import Button from '~/components/Button.astro';
Expand Down
1 change: 1 addition & 0 deletions src/content/docs/test-insights.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
title: Test Insights
description: Monitor, detect, and manage unreliable tests across your repositories.
hubAccent: true
---

Test Insights helps you manage test reliability across the full lifecycle.
Expand Down
1 change: 1 addition & 0 deletions src/layouts/BaseLayout.astro
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ const canonicalURL = new URL(Astro.url.pathname.replace(/([^/])$/, '$1/'), Astro
}
#right-sidebar {
display: flex;
flex-direction: column;
}
}
</style>
Expand Down
18 changes: 16 additions & 2 deletions src/layouts/MainLayout.astro
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ const { content, headings, breadcrumbTitle, showMarkdownActions = true } = Astro
---

<BaseLayout {...Astro.props}>
<RightSidebar slot="secondary-sidebar" {...{ content, headings }} />
<RightSidebar slot="secondary-sidebar" headings={headings} />
<PageContent {...{ content }}>
{
Astro.url.pathname !== '/' && (
Expand Down Expand Up @@ -63,10 +63,24 @@ const { content, headings, breadcrumbTitle, showMarkdownActions = true } = Astro
{
Astro.url.pathname !== '/' && (
<Fragment slot="after-content">
<PageFeedback />
{/* PageFeedback also lives in the right sidebar (visible ≥82em).
Hide this footer copy on wide viewports so it doesn't double up. */}
<div class="article-page-feedback">
<PageFeedback />
</div>
{showMarkdownActions && <PageMeta pathname={Astro.url.pathname} />}
</Fragment>
)
}
</PageContent>
</BaseLayout>

<style>
/* The right sidebar (≥82em) hosts a PageFeedback widget. To avoid showing
the same widget twice on wide viewports, hide the article-footer copy. */
@media (min-width: 82em) {
.article-page-feedback {
display: none;
}
}
</style>
15 changes: 0 additions & 15 deletions src/pages/changelog/[slug].astro
Original file line number Diff line number Diff line change
Expand Up @@ -147,14 +147,6 @@ const accent = getProductAccent(primaryTag);
font-size: 1.75rem;
}
}
/* Disable global heading auto-numbering */
.changelog-detail .detail-title {
counter-increment: none !important;
}
.changelog-detail .detail-title::before {
content: none !important;
}

.detail-date {
font-size: 0.8125rem;
color: var(--theme-text-muted);
Expand Down Expand Up @@ -300,13 +292,6 @@ const accent = getProductAccent(primaryTag);
font-weight: 700;
margin: 0 0 14px;
}
/* Disable global heading auto-numbering on related-heading */
.changelog-detail .related-heading {
counter-increment: none !important;
}
.changelog-detail .related-heading::before {
content: none !important;
}
.related-grid {
display: grid;
grid-template-columns: 1fr 1fr;
Expand Down
7 changes: 0 additions & 7 deletions src/pages/changelog/index.astro
Original file line number Diff line number Diff line change
Expand Up @@ -283,13 +283,6 @@ const description = 'Latest product updates from Mergify.';
background: var(--theme-text);
}

/* Year / month headings — disable global numbering */
.changelog-page .cl-year > .cl-year-heading {
counter-increment: none !important;
}
.changelog-page .cl-year > .cl-year-heading::before {
content: none !important;
}
.cl-year {
margin-bottom: 0;
}
Expand Down
5 changes: 0 additions & 5 deletions src/styles/api-reference.css
Original file line number Diff line number Diff line change
Expand Up @@ -113,11 +113,6 @@
margin: 0 0 0.5rem !important;
color: var(--theme-text);
scroll-margin-top: calc(var(--theme-navbar-height) + 1rem);
counter-increment: none;
}

.endpoint-heading::before {
content: none !important;
}

.endpoint-head {
Expand Down
Loading