build.yml 1.0 KB

12345678
  1. version: 0.2
  2. phases:
  3. build:
  4. commands:
  5. - docker login -u AWS -p $(aws ecr get-login-password --region $AWS_REGION) $ECR_ENDPOINT
  6. - docker build -t builtimage --build-arg NEXT_PUBLIC_VERCEL_ENV=$NEXT_PUBLIC_VERCEL_ENV --build-arg NEXT_PUBLIC_VERCEL_URL=$NEXT_PUBLIC_VERCEL_URL --build-arg NEXT_PUBLIC_GOOGLE_ANALYTICS_ID=$NEXT_PUBLIC_GOOGLE_ANALYTICS_ID --build-arg NEXT_PUBLIC_TARTEEL_VS_API_KEY=$NEXT_PUBLIC_TARTEEL_VS_API_KEY --build-arg NEXT_PUBLIC_FS_API_KEY=$NEXT_PUBLIC_FS_API_KEY --build-arg NEXT_PUBLIC_FS_AUTH_DOMAIN=$NEXT_PUBLIC_FS_AUTH_DOMAIN --build-arg NEXT_PUBLIC_FS_PROJECT_ID=$NEXT_PUBLIC_FS_PROJECT_ID --build-arg NEXT_PUBLIC_FS_STORAGE_BUCKET=$NEXT_PUBLIC_FS_STORAGE_BUCKET --build-arg NEXT_PUBLIC_FS_MESSAGING_SENDER_ID=$NEXT_PUBLIC_FS_MESSAGING_SENDER_ID --build-arg NEXT_PUBLIC_FS_APP_ID=$NEXT_PUBLIC_FS_APP_ID --build-arg NEXT_PUBLIC_FS_MEASUREMENT_ID=$NEXT_PUBLIC_FS_MEASUREMENT_ID .
  7. - docker tag builtimage:latest $ECR_IMAGE_URL:latest
  8. - docker push $ECR_IMAGE_URL:latest