FROM node:22
WORKDIR /usr/src/app

ARG SITE=default
ENV SITE=$SITE

COPY package*.json ./
RUN npm install
ADD . .
RUN npm run build

FROM php:7.4-apache
COPY  --from=0 /usr/src/app/dist /var/www/html/
