Git Product home page Git Product logo

serverlessapp-pipeline's Introduction

Serverless CI/CD with Google Cloud Run

This project is a side project aimed at providing a simple example of a serverless application deployment using Google Cloud Run. It utilizes Docker containers for the application, with a CI/CD (which also serverless thanks to GitHub) process for seamless deployment. This project is a part of the learning journey into the serverless world.

Overview

The project implements a CI/CD process that includes building a Docker image, testing the application, and deploying it on Google Cloud Run as serverless services.

Usage

  1. Import this Repository and Add Your Application:

    Import this repository to your repository and place your application code in the app/ directory. Ensure your application adheres to the necessary structure and dependencies for successful deployment on Google Cloud Run.

  2. Set up GitHub Secrets: Change the relevant variables the .yaml files:

    • SERVICE_NAME: The name for the Cloud Run service.
    • TEST_SERVICE_NAME: The name for the testing Cloud Run service.

    Add the following relevant variables to your GitHub repository secrets:

    • DOCKER_USERNAME: Docker repository username.
    • DOCKER_PASSWORD: Docker repository password.
    • GCP_SERVICE_ACCOUNT_KEY: Google service account credentials.
    • PROJECT_ID: Google Cloud Platform (GCP) Project ID.
    • REGION: Google Cloud Run deployment region.

    If needed add the app variables in your GCP secrets:

    • API_KEY: API key for the application.
  3. Ensure GCP Service Account Permissions:

    Ensure that the GCP service account being used for this deployment has the "Cloud Run Admin" role assigned to it for proper authorization.

  4. Manual Trigger (Initial Setup):

    Execute the initial.yaml workflow manually to set up the initial deployment and ensure the Docker repository has at least one image.

  5. Activate the Workflow:

    Push any changes to the main branch to automatically trigger the CI/CD process using GitHub Actions.

serverlessapp-pipeline's People

Contributors

raz-dahan avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.