fix
This commit is contained in:
46
share/gitea-tekton-org/postconfig.tf
Normal file
46
share/gitea-tekton-org/postconfig.tf
Normal file
@@ -0,0 +1,46 @@
|
||||
resource "kubectl_manifest" "postconfig" {
|
||||
count = var.autoCD?1:0
|
||||
yaml_body = <<-EOF
|
||||
apiVersion: tekton.dev/v1
|
||||
kind: TaskRun
|
||||
metadata:
|
||||
name: post-config-auto-cd-create
|
||||
namespace: ${var.namespace}
|
||||
ownerReferences: ${jsonencode(var.install_owner)}
|
||||
labels: ${jsonencode(local.common_labels)}
|
||||
annotations:
|
||||
mayfly.cloud.namecheap.com/expire: 336h
|
||||
spec:
|
||||
params:
|
||||
- name: artifactory-url
|
||||
value: git.${var.domain_name}
|
||||
- name: project-name
|
||||
value: deploy
|
||||
- name: project-path
|
||||
value: ${var.organization}/deploy
|
||||
- name: git-repository-url
|
||||
value: ssh://git@${var.gitea_ssh_prefix}.${var.domain_name}:${var.gitea_ssh_port}/${var.organization}/deploy.git
|
||||
- name: deploy-url
|
||||
value: ssh://git@${var.gitea_ssh_prefix}.${var.domain_name}:${var.gitea_ssh_port}/${var.organization}/deploy.git
|
||||
serviceAccountName: default
|
||||
taskRef:
|
||||
kind: Task
|
||||
name: auto-cd-create
|
||||
timeout: 1h0m0s
|
||||
workspaces:
|
||||
- name: source
|
||||
persistentVolumeClaim:
|
||||
claimName: source
|
||||
subPath: postconfig-cd
|
||||
- name: ssh-directory
|
||||
secret:
|
||||
items:
|
||||
- key: known_hosts
|
||||
path: known_hosts
|
||||
- key: ssh-privatekey
|
||||
path: id_rsa
|
||||
- key: ssh-publickey
|
||||
path: id_rsa.pub
|
||||
secretName: ssh-credentials
|
||||
EOF
|
||||
}
|
||||
Reference in New Issue
Block a user