Coder Social home page Coder Social logo

argocd-demo's Introduction

Deploying Go Application in Kubernetes using Argo CD

This repository demonstrates an example of deploying a Go application in Kubernetes using Argo CD, a declarative continuous delivery tool. Argo CD automates the synchronization of your Kubernetes cluster with the desired state defined in a Git repository, ensuring a reliable and automated deployment process.

Prerequisites

Before deploying the Go application, ensure you have the following prerequisites:

  • Kubernetes cluster up and running
  • Argo CD installed in your Kubernetes cluster

Getting Started

To get started with deploying the Go application using Argo CD, follow these steps:

1- Clone this repository:

git clone https://github.com/mahmoudmohamed22/GitOps.git

2- Modify the Kubernetes manifests:

Navigate to the Deployment-App directory. Update the deployment.yaml, service.yaml files with your specific application configurations.

3- Configure Argo CD:

Ensure Argo CD is configured and accessible in your Kubernetes cluster. Update the application.yaml file with the correct application and repository details.

4- Push changes to your repository:

Commit and push the modified Kubernetes manifests and the updated application.yaml file to your repository.

5- Access the Argo CD UI:

  • Open the Argo CD UI in your web browser.
  • Log in using the appropriate credentials.
  • Create an application in Argo CD, specifying the repository and target cluster details.
  • Argo CD will automatically detect the changes and begin deploying the Go application to the Kubernetes cluster.

install ArgoCD in local Kubernetes

kubectl create namespace argocd
kubectl apply -n argocd -f https://raw.githubusercontent.com/argoproj/argo-cd/stable/manifests/install.yaml

get argocd pods

image

get SVC in k8s

image

to access argocd from ui , need edit service to forward

kubectl port-forward -n argocd svc/argocd-server 8080:443

to get password from secrets and then decode with base64 to solve hashing password to right password

kubectl get secret  argocd-initial-admin-secret -n argocd -o yaml

To run Argocd Config "application.yaml" to run app and sync app from git

kubectl apply -f application.yaml

image

ArgoCd

image

ArgoCd To Maange App in k8s and montiring Status app

image

test automatic sync

image

Update Deployment to Test Prune Sync

image image

Contributing

Contributions to this repository are welcome! If you encounter any issues or have suggestions for improvements, feel free to open an issue or submit a pull request.

Acknowledgements

This project is inspired by the GitOps methodology and leverages the power of Argo CD for automated deployment in Kubernetes.

argocd-demo's People

Contributors

mahmoudmohamed22 avatar

Watchers

 avatar  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.