This commit is contained in:
@@ -24,11 +24,9 @@ jobs:
|
||||
# pull: true
|
||||
# no-cache: true
|
||||
# tags: "git.vanespen.dev/evanespen/blog:latest"
|
||||
- name: Setup argocd
|
||||
- name: Setup Kubectl
|
||||
run: |
|
||||
git config --global user.name gitea
|
||||
git config --global user.email gitea@git.vanespen.dev
|
||||
wget https://github.com/argoproj-labs/argocd-autopilot/releases/download/v0.4.20/argocd-autopilot-linux-amd64.tar.gz
|
||||
tar xzvf argocd-autopilot-linux-amd64.tar.gz
|
||||
GIT_TOKEN=${{ secrets.TOKEN }} ./argocd-autopilot-linux-amd64 repo bootstrap --repo https://git.vanespen.dev/evanespen/blog.git
|
||||
mkdir ~/.kube && echo ${{ secrets.KUBECONFIG }} > ~/.kube/config
|
||||
apt update && apt install -y kubectl
|
||||
kubectl apply -f argo.yaml
|
||||
|
||||
|
||||
18
argo.yaml
Normal file
18
argo.yaml
Normal file
@@ -0,0 +1,18 @@
|
||||
apiVersion: argoproj.io/v1alpha1
|
||||
kind: Application
|
||||
metadata:
|
||||
name: blog-argo
|
||||
namespace: argocd
|
||||
spec:
|
||||
project: default
|
||||
source:
|
||||
repoURL: "https://git.vanespen.dev/evanespen/blog"
|
||||
path: "k8s"
|
||||
targetRevision: developer
|
||||
destination:
|
||||
server: "https://kubernetes.default.svc"
|
||||
namespace: argocd
|
||||
syncPolicy:
|
||||
automated:
|
||||
prune: true
|
||||
selfHeal: true
|
||||
10
k8s/deployment.yaml
Normal file
10
k8s/deployment.yaml
Normal file
@@ -0,0 +1,10 @@
|
||||
apiVersion: v1
|
||||
kind: Pod
|
||||
metadata:
|
||||
name: blog-pod
|
||||
spec:
|
||||
containers:
|
||||
- name: blog-container
|
||||
image: git.vanespen.dev/evanespen/blog:latest
|
||||
ports:
|
||||
- containerPort: 80
|
||||
Reference in New Issue
Block a user