Exopods Docs
DashboardPricing
  • Getting Started
    • Introduction
  • Knowledge Base
    • Supported Apps
    • Terms/Misc
    • Understand Pricing
    • Why Exopods?
  • Tutorials
    • Getting Started
      • How to Deploy Docker Apps on Exopods?
      • How to deploy Github Project on Exopods?
    • Deploy docker images using private registries
      • AWS ECR
      • Google GCR
      • JFrog
      • Dockerhub
    • Deploy your web app on Exopods
      • Effortless deploy React apps with Exopods
      • Deploy Node.js application using Exopods
    • Deploy One Click Templates
      • Grafana Template deployment on Exopods
      • Deploying portainer in Exopods
      • Deploying Gitea template on Exopods
  • News
    • What's new in Exopods?
  • help and support
    • Common Issues?
  • knowledge share
    • Managed K8s Vs Exopods?
    • How to configure SSL in Exopods?
Powered by GitBook
On this page
  • Prerequisite
  • How to get GCP credentials
  • Configure Docker Image
  • Enable Private Registry
  • Select/Create Docker Pull Secrets
  • Test and Configure
  • Configure Deployment
  • Deploy
  • Conclusion
  1. Tutorials
  2. Deploy docker images using private registries

Google GCR

This guide outlines the steps to deploy a Docker image from Google Container Registry (GCR) to Exopods.

PreviousAWS ECRNextJFrog

Last updated 9 months ago

Prerequisite

  • Kubernetes cluster: A Kubernetes cluster where you want to deploy your application.

  • Google Cloud account: A Google Cloud account with necessary permissions to access your GCR repository.

  • Exopods account: An Exopods account.

  • Docker image: A Docker image built from your application code and pushed to your GCR repository.

  • Basic understanding of Kubernetes and Docker: Familiarity with Kubernetes concepts and Docker images is helpful.

  • GCP credentials: A service account key or username and password for your Google Cloud account.

How to get GCP credentials

To get Google Cloud Platform (GCP) credentials for your Google Container Registry (GCR) repository, you can follow these steps:

1. Create a Service Account Key:

  • Log in to the Google Cloud Console ()

  • Go to the IAM & Admin section and select "Service accounts".

  • Click "Create Service Account".

  • Give your service account a name (e.g., "gcr-access").

  • Grant the service account the "Cloud Container Registry" role.

  • Click "Create".

  • Click on the newly created service account.

  • Go to the "Keys" tab and click "Add key".

  • Select "Create new key".

  • Choose a file name for your service account key (e.g., "gcr-service-account.json").

  • Click "Create".

  • Download the JSON file. Keep this file secure, as it contains your service account credentials.

2. Use the Service Account Key:

  • You can use the downloaded JSON file as your "service account key" when configuring your Exopods deployment.

Configure Docker Image

  1. Deployment Name: Provide a unique name for your deployment.

  2. Docker Repo/Registry URL: Enter the URL of your GCR repository. This usually follows the format: gcr.io/project-id/repo-name.

  3. Image Tag: Enter the image tag (e.g., latest, or any other version tag of your image).

Enable Private Registry

  • Toggle the Private Registry option to enable pulling from a private Google Cloud Registry (GCR).

Select/Create Docker Pull Secrets

  1. Select Secret: Choose GCR from the dropdown under the "Select Secret" option.

  2. Add New Secret: If no GCR credentials are stored yet, click Add new and perform the following:

    • Registry Provider: Select GCR.

    • Secret Name: Provide a custom name for the secret (e.g., GCR_Pull_Secret).

    • Repo URL: Provide the URL of your GCR repository.

    • Username: Enter _json_key for GCR.

    • Email: This field is optional for GCR.

    • Password: Paste the base64-encoded service account key JSON.

  3. Submit Secret: Once the secret is filled, click Submit to add the pull secret for GCR.

Test and Configure

  1. Test Connection: After the secrets are configured, click Test to verify the connection with your GCR repository.

  2. Registry Provider Selection: Select the Registry Provider as GCR from the list.

  3. Repo URL, Username, Email, Password: Confirm and re-enter the following details if necessary:

    • Repo URL (your GCR URL)

    • Username: _json_key

    • Email (optional)

    • Password (service account key)

  4. Continue: If the test is successful, click Continue to finalize the Docker image configuration.

Configure Deployment

Once the Docker image is successfully configured, proceed to the deployment settings.

Configure Deployment Details:

  1. Port Mapping: Define the ports required for your application.

  2. Command and Arguments: Set custom Docker commands and arguments (if any) to run when the container starts.

  3. Environment Variables: Specify any environment variables needed for the container's runtime.

  4. Pricing/Resource Allocation: Configure the resource allocation (e.g., CPU, RAM) and select a pricing tier that suits your deployment.

Deploy

Once all configurations are in place, click Deploy to launch your containerized application from GCR. The system will now pull the Docker image from the private Google Cloud Registry and deploy it.

Conclusion

By completing these steps, you've successfully configured a Docker image from Google Cloud Registry (GCR) and deployed it. After reviewing your resource allocation and pricing, the deployment is now live. This guide provides a clear, beginner-friendly approach to deploying containerized applications with GCR, while also allowing for more advanced configurations as your understanding deepens.

https://console.cloud.google.com/