TeamCatalogProps.java

  1. package no.nav.data.common;

  2. import lombok.AllArgsConstructor;
  3. import lombok.Data;
  4. import lombok.NoArgsConstructor;
  5. import org.springframework.boot.context.properties.ConfigurationProperties;

  6. @Data
  7. @AllArgsConstructor
  8. @NoArgsConstructor
  9. @ConfigurationProperties(prefix = "team-catalog")
  10. public class TeamCatalogProps {

  11.     private String envlevel;

  12.     private String defaultProductareaUuid;

  13.     /**
  14.      * returns true for main catalog, false for sandbox env (nais yaml wont accept bools, not even 'string-bools')
  15.      */
  16.     public boolean isPrimary() {
  17.         return envlevel.equals("primary");
  18.     }
  19. }