Files
Krow-workspace/create-missing-repository.sh
bwnyasse 3bd2dfc002 refactor(Makefile): remove App Engine configs and scripts, migrate launchpad to Cloud Run
This commit removes legacy App Engine deployment artifacts and updates the Makefile to reflect the successful migration of the `internal-launchpad` service to Cloud Run.

The following changes were made:

- Deleted obsolete permission scripts:
 - `fix-appengine-permissions-complete.sh`
 - `fix-project-level-permissions.sh`
 - `create-missing-repository.sh`
- Removed the `firebase/internal-launchpad/app.yaml` file.
- Updated `firebase.json` to remove the `launchpad` hosting configuration.

These changes streamline the repository, reduce developer confusion, and prevent the accidental use of outdated deployment logic.
2025-11-16 08:10:31 -05:00

57 lines
1.9 KiB
Bash
Executable File

#!/bin/bash
set -e
PROJECT_ID="krow-workforce-dev"
PROJECT_NUMBER="933560802882"
echo "============================================"
echo "Création du repository us.gcr.io manquant"
echo "============================================"
echo ""
# 1. Créer le repository us.gcr.io qui n'existe pas
echo "1. Création du repository us.gcr.io dans Artifact Registry..."
gcloud artifacts repositories create us.gcr.io \
--repository-format=docker \
--location=us \
--description="GCR compatibility layer for App Engine" \
--project=${PROJECT_ID} || echo "Repository existe déjà"
echo ""
echo "2. Configuration des permissions sur us.gcr.io..."
# Permissions pour Cloud Build Service Account
gcloud artifacts repositories add-iam-policy-binding us.gcr.io \
--location=us \
--member="serviceAccount:${PROJECT_NUMBER}@cloudbuild.gserviceaccount.com" \
--role="roles/artifactregistry.reader" \
--project=${PROJECT_ID}
gcloud artifacts repositories add-iam-policy-binding us.gcr.io \
--location=us \
--member="serviceAccount:${PROJECT_NUMBER}@cloudbuild.gserviceaccount.com" \
--role="roles/artifactregistry.writer" \
--project=${PROJECT_ID}
# Permissions pour App Engine Service Account
gcloud artifacts repositories add-iam-policy-binding us.gcr.io \
--location=us \
--member="serviceAccount:${PROJECT_ID}@appspot.gserviceaccount.com" \
--role="roles/artifactregistry.reader" \
--project=${PROJECT_ID}
echo ""
echo "3. Vérification des repositories existants..."
gcloud artifacts repositories list \
--location=us \
--project=${PROJECT_ID} \
--format="table(name,format,location)"
echo ""
echo "============================================"
echo "✅ Repository us.gcr.io créé et configuré!"
echo "============================================"
echo ""
echo "Attends 1-2 minutes puis relance:"
echo " make deploy-launchpad"
echo ""