File tree 2 files changed +13
-40
lines changed
2 files changed +13
-40
lines changed Original file line number Diff line number Diff line change 17
17
echo "Extracting issue details..."
18
18
ISSUE_BODY="${{ github.event.issue.body }}"
19
19
VM_NAME=$(echo "$ISSUE_BODY" | grep -A 2 'VM Name' | tail -n 1 | xargs)
20
- VM_ID=$(echo "$ISSUE_BODY" | grep -A 2 'VM ID' | tail -n 1 | xargs)
20
+ VM_ID=$(echo "$ISSUE_BODY" | grep -A 2 'VM ID' | grep -v 'Clone VM ID' | tail -n 1 | xargs)
21
21
RAM=$(echo "$ISSUE_BODY" | grep -A 2 'RAM' | tail -n 1 | xargs)
22
22
CPUS=$(echo "$ISSUE_BODY" | grep -A 2 'CPU Cores' | tail -n 1 | xargs)
23
23
SCPU_TYPE=$(echo "$ISSUE_BODY" | grep -A 2 'CPU Type' | tail -n 1 | xargs)
@@ -100,3 +100,15 @@ jobs:
100
100
git add terraform/proxmox/$VM_NAME.tf
101
101
git commit -m "Add VM $VM_NAME configuration"
102
102
git push
103
+
104
+
105
+ - name : Trigger Terraform Apply Workflow
106
+ uses : https://github.com/actions/github-script@v6
107
+ with :
108
+ script : |
109
+ github.rest.actions.createWorkflowDispatch({
110
+ owner: context.repo.owner,
111
+ repo: context.repo.repo,
112
+ workflow_id: "tofu.yml",
113
+ ref: "main"
114
+ })
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments