Skip to content

GitLab Next

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
A
auto-deploy-app
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
    • Iterations
  • Merge Requests 0
    • Merge Requests 0
  • Requirements
    • Requirements
    • List
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Code Review
    • Insights
    • Issue
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GitLab.org
  • charts
  • auto-deploy-app
  • Issues
  • #51

Closed (moved)
Open
Opened Feb 27, 2020 by imran malik@hayderimran7💬

Autodevops production service selector points to both canary+production deployments ( it shouldnt point to canary)

when doing canary deployments, ideally you want to have a service that points to the canary deployment only. You then control the traffic via your ingress(e.g. in nginx-ingress , create a separate canary ingress that has annotation nginx.ingress.kubernetes.io/canary: "true" set and points to canary service backend. However even with that set, i found out my production service points to both production deployment and production-canary deployment. To fix this, i had to add release: {{ .Release.Name }} as selector so production-canary release service points to production-canary deployment and likewise for production. The fix is as simple as changing the service.yaml to:

  selector:
    app: {{ template "appname" . }}
    release: {{ .Release.Name }}
    tier: "{{ .Values.application.tier }}"

PS: this is just one of implementation of how i achieved canary deployment . Open to suggestions/ideas

Link

  • https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/annotations/#canary
Edited Feb 28, 2020 by Thong Kuah
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None
Reference: gitlab-org/charts/auto-deploy-app#51