What is GitOps?

πHello, Hashnode community! I'm subbaramireddy, a passionate DevOps Engineer with a relentless commitment to optimizing software development workflows and infrastructure management. π Hands-on experience in the DevOps field, I've honed my skills in AWS cloud services, containerization, and CI/CD pipelines. As an AWS Certified Developer, I'm well-versed in leveraging cloud technologies to drive efficiency and innovation. π‘ I firmly believe in the power of continuous improvement. My journey began with an internship, where I immersed myself in the intricacies of DevOps, from deploying web applications to orchestrating containerized solutions. I've also delved into AWS CDK, enhancing security through RDS instance policies, and creating foundational infrastructure with precision. π My goal is to share insights, best practices, and the latest trends in the DevOps landscape. I'm excited to connect with like-minded professionals, engage in meaningful discussions, and learn from the diverse experiences of the Hashnode community. π Let's explore the ever-evolving world of DevOps together. Feel free to connect with me, ask questions, or share your own insights. Together, we can drive innovation and efficiency in the tech world!
GitOps
GitOps is a framework where the entire code is controlled by the git.
GitOps can be considered an extension of Infrastructure as Code (IaC) that uses Git as the Version control System.


GitOps Principles
Declarative vs imperative
Make use of Git.
Pull Request
Reconcile Loop

DevOps Vs GitOps


Push vs Pull based Deployments


GitOps Features

GitOps Benefits & Challenges
Pro's
Lightweight and Vendor-neutral
Faster, Safer, Immutablem and Reproducible Deployments
Eliminating configuration drift
uses familiar tools and processes
Revisions with history
Con's
Doesn't help with Secret Management
Number of Git repositories
Challenges with programmatic updates.
Governance other than PR approval.
Malformed YAML/Config manifests.
GitOps Projects/Tools

ArgoCD:
FluxCD
Atlantis
Autoapply
CloudBees Rollout:
JenkinsX: CI/CD Platform
Flagger:
Ignite: VM Manager
Faros
Helm Operator
Weave GitOps Core
KubeStack
Weave Cloud
GitKube
PipeCD
Werf
What is ArgoCD?
Argo CD is a declarative, GitOps continuous delivery tool for Kubernetes resources defined in a Git repository.
Continuously monitors running applications and compares their live state to the desired state.
It reports the deviations and provides visualizations to help developers manually or automatically sync the live state with the desired state.
Why use ArgoCD
It extends the benefits of declarative specifications and Git-based configuration management.
It is the first step in achieving continuous operations on monitoring, analytics, and automation remediation.
It can deploy to multiple clusters and is Enterprise-friendly( audibility, compliance, security, RBAC, SSO and a lot more.
How ArgoCD works?
- It follows the GitOps pattern by using Git repositories as the source of truth for the desired state of the app and the target deployment envs.
Kustomize applications
Helm Charts
Ksonnet applications Jsonnet files
YAML/JSON manifests
- It automates the synchronization of the desired application state with each of the specified target environments.

ArgoCD Concepts & Terminology

ArgoCD Features
Automated deployment of applications to specified target environments in multiple clusters.
Support for multiple config management/templating tools (Kustomize, Helm, Ksonnet, Jsonnet, plain-YAML).
SSO Integrations (OIDC, OAuth2, LDAP, SAML 2.0, GitHub, GitLab, Microsoft, Linkedin)
Multi-tenancy and RBAC policies for authorization.
Rollback/Roll-anywhere to any application configuration committed in the Git repository.
Health status analysis of application resources.
Automated configuration drift detection and visualization.
Out-of-the-box Prometheus metrics.
Audit trails for application events and API Calls
PreSync, Sync, and PostSync hooks to support complex application rollouts (e.g. blue/green & Canary upgrades).
Webhook integration (GitHub, BitBucket, GitLab).
CLI and access tokens for automation and CI integration.
Web UI which provides a real-time view of application activity.
Automated or manual syncing of applications to their desired state.

ArgoCD Architecture


Installation Options
ArgoCD has two types of installations.
Core
Multi-Tenant




ArgoCD Commands
argocd login ipaddress-argocd-server
argocd app list
argocd cluster list
ArgoCD Application


Creating application using the cli


Demo Application
ArgoCD CLIargocd app create application
argocd app list
argocd app sync application Name
argocd proj list
Reconciliation Loop
Using Timeout
The default timeout is 3 minutes


WebHook



Application Health Checks

ArgoCD supports custom health checks written in Lua.
Define a custom Health check in argocd-cm ConfigMap.
Contribute custom Health Checks.




Thanks for reading! I hope you found this helpful and informative.
I'm always happy to connect with fellow tech enthusiasts and answer any questions you may have. Don't forget to follow me for more updates on tech, programming, and more.ππ
Follow me on LinkedIn to see interesting posts like this : ) Linkedin






