diff --git a/internal/pkg/cli/recorder/recorder.go b/internal/pkg/cli/recorder/recorder.go index 153d023cea..eeb7e5d409 100644 --- a/internal/pkg/cli/recorder/recorder.go +++ b/internal/pkg/cli/recorder/recorder.go @@ -401,16 +401,6 @@ func (r *Recorder) buildProfileCRD(writer io.Writer, spec *seccompprofileapi.Sec } func (r *Recorder) buildAppArmorProfileCRD(writer io.Writer, spec *apparmorprofileapi.AppArmorProfileSpec) error { - programName, err := filepath.Abs(r.options.commandOptions.Command()) - if err != nil { - return fmt.Errorf("get program name: %w", err) - } - // Raw apparmor profile is expected in the required policy field. - policy, err := crd2armor.GenerateProfile(programName, &spec.Abstract) - if err != nil { - return fmt.Errorf("generating raw apparmor profile: %w", err) - } - spec.Policy = policy profile := &apparmorprofileapi.AppArmorProfile{ TypeMeta: metav1.TypeMeta{ Kind: "AppArmorProfile",