> For the complete documentation index, see [llms.txt](https://docs.realmjoin.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.realmjoin.com/ja/zhan-kai/onboarding-realmjoin-portal/advanced-setup.md).

# 詳細設定

RealmJoin PowerShell モジュールは RealmJoin Tenant のセットアップを自動化します。次のことを行います:

* RealmJoin アプリケーションに必要な Microsoft Entra ID Service Principals を作成します
* 選択した機能に基づいて適切な Microsoft Graph のアクセス許可を割り当てます
* RealmJoin の機能（Portal、Intune LAPS、Autopilot、デバイス アクション、修復スクリプト、セキュリティ機能）を構成します
* 以前の構成からレガシー アプリケーションをクリーンアップします

モジュールは次の場所で公開されています: [PowerShell Gallery](https://www.powershellgallery.com/packages/RealmJoin).

## 前提条件

{% hint style="info" %}
必要な Microsoft Graph PowerShell モジュールは、コマンドを初めて実行したときに自動的にインストールされます。
{% endhint %}

* **PowerShell 5.1** 以降
* 次のアカウントでサインインしてください: **グローバル管理者** Entra ID Tenant の
* Service Principals を作成し、アクセス許可を割り当てるために、次の Microsoft Graph のアクセス許可が必要です:
  * `Organization.Read.All`
  * `Application.ReadWrite.All`
  * `AppRoleAssignment.ReadWrite.All`

## 推奨セットアップ

RealmJoin Portal に表示されるセットアップ コマンドでは、次の項目に対するアクセス許可が提供されます:

* コア機能
* Intune LAPS
* サインイン データ
* 修復スクリプト
* Autopilot
* Intune デバイス アクション

すべての機能または個別の機能を追加するには、次を参照してください: [その他のコマンド](#other-commands).

{% stepper %}
{% step %}

#### Windows/Mac で PowerShell を開く

Azure CloudShell ではなく、デバイスの PowerShell に RealmJoin PowerShell モジュールをインストールして実行することをお勧めします。
{% endstep %}

{% step %}

#### RealmJoin オンボーディング スクリプトをコピーして実行する

スクリプトは Microsoft Graph で認証するよう求めます。グローバル管理者としてサインインしてください。

```powershell
Install-Module -Force -Name RealmJoin
Complete-RJTenantOnboarding -Token 1234ABCD 6>&1
```

{% hint style="info" %}
**概要 `6>&1`:** これらのコマンドは、進行状況の更新を PowerShell の Information stream に書き込みます。 `6>&1` そのリダイレクトにより、その出力がコンソールに表示されます。これがないと、実行中に詳細な進行メッセージは表示されません。
{% endhint %}

<figure><img src="/files/e0564eae6fcc895120913859f05500044f0b66cb" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/8996616d4c81d9e27919ccdf118e770ffa76bc3e" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

#### RealmJoin の使用を開始

完了すると、スクリプトは RealmJoin Portal を起動します

<figure><img src="/files/590870932cb485cdf133c4c81fd62fd901131635" alt=""><figcaption></figcaption></figure>
{% endstep %}
{% endstepper %}

## その他のコマンド

### 対話形式のセットアップ

ガイド付きのメニュー方式の体験を行うには:

```powershell
Show-RJInteractiveSetup 6>&1
```

構成を行う前に利用可能な機能を確認するには:

```powershell
Show-RJFeatureInfo 6>&1
```

### カスタム構成

#### 既定の機能

必須のコア ポータル機能と、既定のオプション機能（RealmJoin Client を除くすべて）を有効にします:

```powershell
New-RJTenant 6>&1
```

#### 最小限の機能（必須機能のみ）

```powershell
New-RJTenant -Features @() 6>&1
```

#### フル機能セット

```powershell
New-RJTenant -All 6>&1
```

#### 読み取り専用アクセス許可

利用可能な場合は読み取り専用アクセス許可を割り当てます（例: `Group.ReadWrite.All` は次になります `Group.Read.All`):

```powershell
New-RJTenant -ReadOnly 6>&1
```

#### カスタム機能の選択

```powershell
New-RJTenant -Features @('RealmJoinPortal', 'IntuneLAPS', 'Autopilot') 6>&1
```

### 既存の構成の更新

`Update-RJTenant` は、すでに構成済みの Tenant を調整します。エイリアス `Complete-RJTenantOnboarding` は、次と同じように使用できます: `Update-RJTenant`.

#### 新しい機能の追加

```powershell
Update-RJTenant -AddFeatures @('SecurityFeatures') 6>&1
```

#### 機能の削除

```powershell
Update-RJTenant -RemoveFeatures @('ShowSignin') 6>&1
```

#### 読み取り専用アクセス許可に切り替える

```powershell
Update-RJTenant -ReadOnly 6>&1
```

#### 変更内容のプレビュー

```powershell
Update-RJTenant -AddFeatures @('SecurityFeatures') -WhatIf 6>&1
```

## 利用可能な機能

次の機能名を `-Features`, `-AddFeatures`および `-RemoveFeatures` パラメーターで使用します。必須機能は常に有効です。既定の構成（`New-RJTenant` パラメーターなし）は **クライアント**.

| Feature               | 説明                                         | 既定値 |
| --------------------- | ------------------------------------------ | :-: |
| `RealmJoinPortal`     | ユーザーのセルフサービスと管理者とのやり取りのためのコア ポータル機能（必須）    |  ☑️ |
| `IntuneLAPS`          | Intune LAPS を使用してローカル管理者パスワードを取得および管理する    |  ☑️ |
| `ShowSignin`          | ユーザーのサインイン履歴と監査ログを表示する                     |  ☑️ |
| `Autopilot`           | Windows Autopilot の展開プロファイルと状態を表示する        |  ☑️ |
| `DeviceIntuneActions` | 特権デバイス操作（同期、再起動、ワイプなど）を実行する                |  ☑️ |
| `DeviceHealthScript`  | PowerShell 修復スクリプトをデバイスに管理および展開する          |  ☑️ |
| `SecurityFeatures`    | 高度な脅威保護とセキュリティ分析（MDE ライセンスが必要）             |     |
| `クライアント`              | RealmJoin エージェント — デバイス管理用のクライアント アプリケーション |     |

## トラブルシューティング

{% hint style="warning" %}
**「権限が不足しています」** — サインインするアカウントがグローバル管理者であり、 [前提条件](#prerequisites).
{% endhint %}

モジュールが見つからない場合は、PowerShell Gallery が利用可能であることを確認し、再インストールしてください:

```powershell
Get-PSRepository 6>&1
Install-Module -Name RealmJoin -Force 6>&1
```

### ヘルプの取得

```powershell
Get-Help New-RJTenant -Full
Get-Help Update-RJTenant -Examples
Get-Help Show-RJInteractiveSetup -Detailed
```


---

# 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://docs.realmjoin.com/ja/zhan-kai/onboarding-realmjoin-portal/advanced-setup.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.
