GitOps Toolchain
jira-github
->github-repo-scaffolding-golang
githubactions-golang
->github-repo-scaffolding-golang
argocdapp
-> andgithub-repo-scaffolding-golang
Note: These dependencies are not consistent, such as when the repo operated by jira-github
and github-repo-scaffolding-golang
are not the same, the dependencies disappear.
We should use the dependency
according to the actual usage situation.
Download DevStream (dtm
)
Download the appropriate dtm
version for your platform from .
Copy the gitops.yaml, and variables-gitops.yaml to your working directory:
Then modify the variables-gitops.yaml
file accordingly.
For me I can set these variables like:
export GITHUB_TOKEN="YOUR_GITHUB_TOKEN_HERE"
export JIRA_API_TOKEN="YOUR_JIRA_API_TOKEN_HERE"
export DOCKERHUB_TOKEN="YOUR_DOCKERHUB_TOKEN_HERE"
If you don’t know how to create these three tokens, check out:
- GITHUB_TOKEN:
- JIRA_API_TOKEN: Creating a personal access token
3. Initialize
Run:
Run:
dtm apply -f config-gitops.yaml
and confirm to continue, then you should see similar output to:
5. Check the Results
Let’s continue to look at the results of the apply
command.
- The repository scaffolding we got looks like this:
- How do Jira and Github integrate? Let’s create a new issue:
- The issue will be renamed automatically like this:
- We can find this auto-synced in Jira:
- If we continue to leave a comment on this issue:
- The comment will also be automatically synced to Jira:
- What does CI do here?
- The CI processes also build an image, and this image is automatically pushed to DockerHub:
- Of course, the ArgoCD must have been installed as expected.
- Our code has just been built into an image, at this time the image is automatically deployed to our k8s as a Pod:
Run:
dtm destroy
and you should see similar output: