#!/usr/bin/env bash
set -euo pipefail

cd "$(dirname "$0")/.."
source deploy/env.sh

export K8S_NAMESPACE="$STAGING_NAMESPACE"
export APP_HOST="$STAGING_HOST"
export NEXT_PUBLIC_SITE_URL="https://${STAGING_HOST}"
export NEXT_PUBLIC_API_BASE="https://${STAGING_HOST}/api"
export APP_ENV="staging"
export CLUSTER_ISSUER="$STAGING_CLUSTER_ISSUER"
export INGRESS_CLASS

# optionally set AUTH_SECRET (and other secrets) in the environment before running
bash deploy/deploy.sh
