Closed josemrs closed 3 years ago
there were some issues in Rundeck 3.3 regarding regarding scm, maybe try Rundeck 3.3.11 release. I will close this issue as it is not specific to the rundeck-cli project. If you still have issues after trying the latest rundeck server release, please file any issues in https://github.com/rundeck/rundeck/issues
Hi, I am working with Rundeck CLI to automate some importing when I found that job deletion does not work as I expected.
Scenario
Steps to reproduce
$ java -jar ~/Downloads/rundeck-cli-1.3.4-all.jar projects scm status -i import -p runooks synchState: CLEAN message: actions:
diff --git a/job1.xml b/job1.xml index 0e9e825..0dce92a 100644 --- a/job1.xml +++ b/job1.xml @@ -6,7 +6,7 @@
diff --git a/job2.xml b/job2.xml deleted file mode 100644 index d5b95b7..0000000 --- a/job2.xml +++ /dev/null @@ -1,21 +0,0 @@ -
-
Status is fine:
SCM inputs is not ok, it is missing the deletion:
Items: itemId: job1.xml deleted: false tracked: true job: jobName: job1 jobId: 44dccdf9-72e8-460a-8012-e561fc7520aa groupPath: group1/Admin
status: IMPORT_NEEDED
$ java -jar ~/Downloads/rundeck-cli-1.3.4-all.jar projects scm perform --integration import --project runooks --action import-jobs --allitems
Action import-jobs was successful.
Result: SCM import Action was Successful: import-jobs
$ java -jar ~/Downloads/rundeck-cli-1.3.4-all.jar projects scm status -i import -p runooks synchState: DELETE_NEEDED message: 1 tracked file(s) were deleted actions: import-jobs
~/git/rundeck-testing [master] [None] $ java -jar ~/Downloads/rundeck-cli-1.3.4-all.jar projects scm inputs -i import -p runooks -a import-jobs Import remote Changes: Import the modifications to Rundeck Fields:
Items: itemId: job1.xml deleted: false tracked: true job: jobName: job1 jobId: 44dccdf9-72e8-460a-8012-e561fc7520aa groupPath: group1/Support
status: CLEAN
$ java -jar ~/Downloads/rundeck-cli-1.3.4-all.jar projects scm perform --integration import --project runooks --action import-jobs --allitems
Action import-jobs was successful.
Result: SCM import Action was Successful: import-jobs
$ java -jar ~/Downloads/rundeck-cli-1.3.4-all.jar projects scm status -i import -p runooks synchState: CLEAN message: actions:
$ java -jar ~/Downloads/rundeck-cli-1.3.4-all.jar projects scm inputs -i import -p runooks -a import-jobs Import remote Changes: Import the modifications to Rundeck Fields:
Items: itemId: job1.xml deleted: false tracked: true job: jobName: job1 jobId: 44dccdf9-72e8-460a-8012-e561fc7520aa groupPath: group1/Support
status: CLEAN