> For the complete documentation index, see [llms.txt](https://help.aikido.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.aikido.dev/docs/docs-ja/kdosukyan/scanning-practices/ignore-via-code-with-aikido-files.md).

# .aikidoファイルを使ったスキャン設定

その `.aikido` このファイルを使うと、Aikido が特定のリポジトリをどのように扱うかを細かく調整できます。Aikido は各スキャン時に自動的にこれを読み込みます。

## デフォルトの動作とカスタマイズ

Aikido はすでに、不要な多くのファイルやディレクトリをデフォルトで除外しています。ほとんどのリポジトリでは、追加の設定は不要です。

使用 `.aikido` リポジトリ固有の例外や動作が必要な場合に使用します。一般的なユースケースには、特定のパスの除外、理由付きで受け入れ済みの CVE の無視、そのリポジトリ向けの AutoFix 動作にカスタムコンテキストを与えることが含まれます。

## .aikido ファイルの設定 <a href="#setting-up-the-aikido-file" id="setting-up-the-aikido-file"></a>

作成してください `.aikido` ファイル **リポジトリのルート内に**.

<div data-with-frame="true"><img src="/files/3517c77e9e3f201040a643b05aec6a55594d3051" alt=".aikido 設定ファイルを含むプロジェクトディレクトリ。" width="375"></div>

### 特定のパスやファイルを除外する <a href="#exclude-specific-paths" id="exclude-specific-paths"></a>

その `除外` キーと `パス` サブキーを使うと、Aikido のコードスキャンで特定のファイルやディレクトリをスキャン対象から除外できます。これにより、自動的に **シークレット、SAST の問題、ロックファイル、コード品質のスキャンが除外されます。**

{% hint style="info" %}
**注意：** のパスマッチングは `.aikido` に基づいています **単純な文字列の包含**.

設定した値が完全なファイルパスのどこかに含まれていれば、除外されます。\
ワイルドカードと正規表現は **サポートされていません**.
{% endhint %}

```yaml
exclude:
  paths:
    - src/useless-folder
    - docs/example.js
    - .gen.ts
```

### CVE を無視する <a href="#ignore-cves" id="ignore-cves"></a>

CVE を無視するには、次の項目に追加してください `.aikido` 理由を YAML ファイルに記載します。Aikido の UI でも、これらの特定の CVE が次の参照とともに無視されていることが表示されます `.aikido` ファイル。

```yaml
ignore:
  cves:
    CVE-2020-8203:
      reason: この CVE は重要ではありません
    CVE-2025-22869:
      reason: これは対応済みです
```

<div data-with-frame="true"><img src="/files/3a7d5eaefe78919710605b55b92bd143ee7b7aff" alt="重大度の高い CVE が .aikido 設定ファイル経由で格下げされました。" width="375"></div>

## 無視の代替方法 <a href="#excluding-sast-findings-using-comments" id="excluding-sast-findings-using-comments"></a>

**コードコメントで SAST を無視する**

無視することもできます [コード内のコメントを使って SAST の検出結果を](/docs/docs-ja/kdosukyan/scanning-practices/excluding-sast-findings-using-comments.md).

### その他の .aikido のユースケース

その `.aikido` このファイルでは、リポジトリ固有の AutoFix の動作も設定できます。

これを使って、カスタムのブランチプレフィックスや、リポジトリ全体で 1 つの AutoFix PR などの設定を定義できます。

参照: [AutoFix PR 設定](/docs/docs-ja/autofix-to/configure/autofix-pr-configuration.md) 対応している `Autofix` 設定と例について。


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://help.aikido.dev/docs/docs-ja/kdosukyan/scanning-practices/ignore-via-code-with-aikido-files.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
