#!/bin/bash

ENV_CONFIG=$(cat /app/site-config.$ENDPOINTS_ENV.json | tr -d '[:space:]')
sed -i "s|'@@SITE_CONFIG@@'|$ENV_CONFIG|g" /srv/index.html
nginx -c /etc/nginx/nginx.conf -g "daemon off;"
