Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

As a developer, I want to manage the versioning of my deployment/application. #20

Open
5 of 11 tasks
ThomasCardin opened this issue Jan 16, 2024 · 2 comments
Open
5 of 11 tasks
Assignees
Labels

Comments

@ThomasCardin
Copy link
Member

ThomasCardin commented Jan 16, 2024

Executive summary

We want to manage the different versions of our applications and test them progressively (for example, a frontend developer wants to test the version of the backend that is in the testing phase on a PR). We need to have a deployment for each version.

Context

If a user creates a PR, an automatic deployment should be carried out with the correct version (via the Dockerfile, based on the specific file of each directory. For example, for the frontend, it should refer to the package.json). Afterward, the URL of this deployment should be displayed in the pull request (for example, https://v1-0-0.nachet.ninebasetwo.xyz/ for the frontend and https://v1-0-0.nachet.ninebasetwo.xyz/api for the backend). Subsequently, a developer could test https://"x".nachet.ninebasetwo.xyz at any time.

How to do it

  • Automatic deployment of an image version (application) with ArgoCD to Kubernetes.
  • Tag the Docker image with the version specified in the specific file (for example, package.json for the frontend).
  • For routing, modify the LB Ingress NGINX to point to a specific version. For example, if a frontend application is on version v1.0.0, its URL would be https://v1-0-0.nachet.ninebasetwo.xyz/. When someone clicks on this URL, the backend will automatically communicate with https://v1-0-0.nachet.ninebasetwo.xyz/api (v1-0-0 being the corresponding version for the backend).

Summary

Regarding the Dockerfiles of the projects, ARGs need to be retained at build time (for example, docker build...).

Steps:

EDIT:

After some research, @SonOfLope found this workflow. This could save us a lot of time. If the solution works, some of the earlier steps won't need to be done.

@ThomasCardin ThomasCardin moved this to Todo in DevSecOps Jan 16, 2024
@ThomasCardin ThomasCardin changed the title As a DevOps, I want to manage the versioning of my deployment/application. As a developer, I want to manage the versioning of my deployment/application. Jan 16, 2024
@rngadam
Copy link

rngadam commented Jan 16, 2024

review ADR: https://github.com/ai-cfia/dev-rel-docs/blob/main/adr/006-database-change-management.md

also : https://www.ietf.org/rfc/rfc1034.txt#:~:text=They%20must%20start%20with%20a,be%2063%20characters%20or%20less.&text=information%2C%20which%20may%20be%20empty.)

They must start with a letter, end with a letter or digit, and have as interior characters only letters, digits, and hyphen. There are also some restrictions on the length. Labels must be 63 characters or less. information, which may be empty.

I suggest substituting . for - so v2.3.30 becomes v2-3-30

@SonOfLope
Copy link
Contributor

https://github.com/marketplace/actions/preview-pull-requests-in-kubernetes

@ThomasCardin ThomasCardin removed the status in DevSecOps Apr 22, 2024
@ThomasCardin ThomasCardin moved this to Todo in DevSecOps Apr 22, 2024
@ThomasCardin ThomasCardin moved this from Todo to In Progress in DevSecOps May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: In Progress
Development

No branches or pull requests

3 participants