リポジトリメタデータ
リポジトリメタデータを署名できるようにするにはカスタムGPGキーが必要です。
|
To access a shell inside the Server container run |
As the root user, use the
gpgcommand to generate a new key:mgrctl exec -it -- gpg --full-generate-keyAt the prompts, select
RSAas the key type, with a size of 2048 bits, and select an appropriate expiry date for your key. Check the details for your new key, and typeyto confirm.プロンプトが表示されたら、キーに関連付けられた名前と電子メールアドレスを入力します。 You can also add a comment to help you identify the key, if desired. When you are happy with the user identity, type
Oto confirm.プロンプトが表示されたら、キーを保護するパスフレーズを入力します。
キーは自動的にキーリングに追加されます。 キーリングにキーを一覧表示して確認できます。
mgrctl exec -- gpg --list-keysAdd the password for your keyring to the
/etc/rhn/signing.confconfiguration file, by opening the file in your text editor and adding this line:GPGPASS="password"
GPGキーの更新については、同期のトラブルシューティングを参照してください。
You can manage metadata signing on the command line using the mgr-sign-metadata-ctl command.
使用するキーの短い識別子を知っている必要があります。 使用可能な公開鍵を短い形式で一覧表示できます。
mgrctl exec -- gpg --keyid-format short --list-keys ... pub rsa4096/3E7BFE0A 2019-04-02 [SC] [expires: 2029-04-01] A43F9EC645ED838ED3014B035CFA51BF3E7BFE0A uid [ultimate] SUSE Manager sub rsa4096/118DE7FF 2019-04-02 [E] [expires: 2029-04-01]Enable metadata signing with the
mgr-sign-metadata-ctlcommand:mgrctl exec -- mgr-sign-metadata-ctl enable 3E7BFE0A OK. Found key 3E7BFE0A in keyring. DONE. Set key 3E7BFE0A in /etc/rhn/signing.conf. DONE. Enabled metadata signing in /etc/rhn/rhn.conf. DONE. Exported key 3E7BFE0A to /srv/susemanager/salt/gpg/mgr-keyring.gpg. DONE. Exported key 3E7BFE0A to /var/spacewalk/gpg/<KEY_NAME>.key. NOTE. For the changes to become effective run: mgr-sign-metadata-ctl regen-metadataこのコマンドを使用して設定が正しいことを確認できます。
mgrctl exec -- mgr-sign-metadata-ctl check-configRestart the container for the configuration changes to be detected.
mgradm restartSchedule metadata regeneration to replace all metadata with new signed versions.
mgrctl exec -- mgr-sign-metadata-ctl regen-metadata
You can also use the mgr-sign-metadata-ctl command to perform other tasks. Use mgr-sign-metadata-ctl --help to see the complete list.
リポジトリメタデータ署名はグローバルオプションです。 有効にすると、サーバ上のすべてのソフトウェアチャンネルで有効になります。 これは、サーバに接続されているすべてのクライアントが、パッケージをインストールまたは更新できるようにするために、新しいGPGキーを信頼する必要があることを意味します。
GPGキーをクライアントに配備すると、salt状態で動作します。
SUSE Multi-Linux Manager Web UIを使用してhighstateを適用します。
GPGキーのトラブルシューティングの詳細については、同期のトラブルシューティングを参照してください。