データ・ラベリングでクロス・テナンシ・ポリシーを設定するには、このステップに従います。
クロス・テナンシ・ポリシーを使用すると、リソースを別のテナンシのユーザーと共有できます。たとえば、ソース・テナント内のIAMグループのユーザーが宛先テナンシのデータセットに対して操作を実行できるようにするクロス・テナント・ポリシーを作成できます。クロス・テナンシ・ポリシーの詳細は、「テナンシをまたがったオブジェクト・ストレージ・リソースへのアクセス」を参照してください。
次の例では、テナンシsource-tenancy内のグループgroup-nameのユーザーは、destination-tenancyという別のテナンシでデータ・ラベリング機能を使用します。
-
source-tenancyにグループを作成し、そのグループにユーザーを追加します。
-
group-nameが承認され、destination-tenancy内のデータセットを管理できるように、source-tenancyに次のポリシーを追加します。
DEFINE tenancy destination-tenancy AS <destination-tenancy-ocid>
ENDORSE group group-name TO manage data-labeling-family IN tenancy destination-tenancy
-
destination-tenancyで、group-nameがデータセットを操作できるようにするポリシー・ステートメントを追加します:
DEFINE tenancy source-tenancy AS <source-tenancy-ocid>
DEFINE group group-name AS <source-tenancy-group-ocid>
ADMIT group group-name OF tenancy source-tenancy TO manage data-labeling-family IN tenancy
- (オプション)ポリシーを追加して、
destination-tenancy内の特定のコンパートメントにアクセスを制限できます。この例では、コンパートメントはdataset-compartmentと呼ばれます:
DEFINE tenancy source-tenancy AS <source-tenancy-ocid>
DEFINE group group-name AS <source-tenancy-group-ocid>
ADMIT group group-name OF tenancy source-tenancy TO manage data-labeling-family IN compartment dataset-compartment
- (オプション)バケットが
destination-tenancyに存在する場合は、オブジェクト・ストレージ・リソースにもクロステナンシ・ポリシーを追加する必要があります。次のポリシー・ステートメントを追加して、グループgroup-nameがdestination-tenancy内のオブジェクト・ストレージ・リソースにアクセスできるようにします:
source-tenancyで、次を追加します:
ENDORSE group group-name to read buckets in tenancy destination-tenancy
ENDORSE group group-name to manage objects in tenancy destination-tenancy
ENDORSE group group-name to read objectstorage-namespaces in tenancy destination-tenancy
destination-tenancyで、次を追加します:
ADMIT group group-name of tenancy source-tenancy to read buckets in tenancy
ADMIT group group-name of tenancy source-tenancy to manage objects in tenancy
ADMIT group group-name of tenancy source-tenancy to read objectstorage-namespaces in tenancy