Switch between modes

Change PEG to the forwarding mode and then back to the review mode.

Prerequisites

By default, PEG initially starts in the review mode.

Procedure

  1. To switch to the forwarding mode:
    1. Edit the ~/peg/text_pipeline/values-gpu.yaml file. At the end of the file, change the forward_to_fluentd value to true and save the changes.
      forward_to_fluentd: "true"
    2. Push the change to PEG by running the following from any folder:
      source ~/peg/scripts/vars.sh
      kubectl delete cronjob.batch/text-pipeline-masking-masking-cron -n text-pipeline
      kubectl get pods --output=jsonpath={.items..metadata.name} -n text-pipeline -o=name | grep cron | xargs -n1 kubectl delete --grace-period=0 --force -n text-pipeline
      helm upgrade text-pipeline ${text_pipeline_dir} -f ${values_file_t} --namespace text-pipeline --set ocr.name=st-fiq-$new_gen_uuid.$apex_domain --set masking.name=dlp-fiq-$new_gen_uuid.$apex_domain
  2. To switch back to the review mode:
    1. Edit the ~/peg/text_pipeline/values-gpu.yaml file. At the end of the file, change the forward_to_fluentd value to false and save the changes.
      forward_to_fluentd: "false"
    2. Push the change to PEG by running the following from any folder:
      source ~/peg/scripts/vars.sh
      kubectl delete cronjob.batch/text-pipeline-masking-masking-cron -n text-pipeline
      kubectl get pods --output=jsonpath={.items..metadata.name} -n text-pipeline -o=name | grep cron | xargs -n1 kubectl delete --grace-period=0 --force -n text-pipeline
      helm upgrade text-pipeline ${text_pipeline_dir} -f ${values_file_t} --namespace text-pipeline --set ocr.name=st-fiq-$new_gen_uuid.$apex_domain --set masking.name=dlp-fiq-$new_gen_uuid.$apex_domain