<commit_before>import {getRoutes} from '../shared/routes';
import respond from './view/html-renderer';
import Root from '../shared/views/root/root';
import {configureStore} from '../shared/store/create';

const defaultPort = 3333;
const port = process.env.PORT || defaultPort;

export default {
  server: {connections: {routes: {security: true}}},
  connections: [{port}],
  registrations: [
    {plugin: 'scooter'},
    {
      plugin: {
        register: 'blankie',
        options: {
          reportOnly: true,
          reportUri: 'https://travi.report-uri.io/r/default/csp/reportOnly',
          defaultSrc: 'https:',
          styleSrc: [
            'self',
            'fonts.googleapis.com'
          ],
          scriptSrc: [
            'self',
            'cdn.polyfill.io',
            'www.google-analytics.com'
          ],
          fontSrc: [
            'data:',
            'fonts.gstatic.com'
          ]
        }
      }
    },
    {plugin: 'inert'},
    {plugin: 'vision'},
    {plugin: 'h2o2'},
    {
      plugin: {
        register: 'visionary',
        options: {
          engines: {mustache: 'hapi-mustache'},
          path: './lib/server/view'
        }
      }
    },
    {
      plugin: {
        register: 'good',
        options: {
          ops: false,
          reporters: {
            console: [
              {
                module: 'good-squeeze',
                name: 'Squeeze',
                args: [{log: '*', request: '*', response: '*', error: '*'}]<commit_msg>fix(csp): allowed images from gravatar and google analytics<commit_after>import {getRoutes} from '../shared/routes';
import respond from './view/html-renderer';
import Root from '../shared/views/root/root';
import {configureStore} from '../shared/store/create';

const defaultPort = 3333;
const port = process.env.PORT || defaultPort;

export default {
  server: {connections: {routes: {security: true}}},
  connections: [{port}],
  registrations: [
    {plugin: 'scooter'},
    {
      plugin: {
        register: 'blankie',
        options: {
          reportOnly: true,
          reportUri: 'https://travi.report-uri.io/r/default/csp/reportOnly',
          defaultSrc: 'https:',
          styleSrc: [
            'self',
            'fonts.googleapis.com'
          ],
          scriptSrc: [
            'self',
            'cdn.polyfill.io',
            'www.google-analytics.com'
          ],
          fontSrc: [
            'data:',
            'fonts.gstatic.com'
          ],
          imgSrc: [
            'www.gravatar.com',
            'www.google-analytics.com'
          ]
        }
      }
    },
    {plugin: 'inert'},
    {plugin: 'vision'},
    {plugin: 'h2o2'},
    {
      plugin: {
        register: 'visionary',
        options: {
          engines: {mustache: 'hapi-mustache'},
          path: './lib/server/view'
        }
      }
    },
    {
      plugin: {
        register: 'good',
        options: {
          ops: false,
          reporters: {
            console: [
              {
                module: 'good-squeeze',
                name: 'Squeeze',
                args: [{log: '*', request: '*', response: '*', error: '*'}]
{'fraction_non_alphanumeric': 0.1565847511027095, 'fraction_numerical': 0.003780718336483932, 'mean_word_length': 1.5563607085346216, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5593399', 'n_tokens_mistral': 968, 'n_tokens_neox': 947, 'n_words': 184}