summaryrefslogtreecommitdiffstats
path: root/scripts/host-del.sh
blob: 202100d9e6919f02e4e4b9f68036cc27f4030bd8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/sh +x

. ./include.sh

json="{
    \"method\": \"host_del\",
    \"params\": [
        [ \"dev.example.com\" ],
        {
            \"all\": true,
            \"rights\": true
        }
    ],
    \"id\": 0
}"\

curl\
  -H "Content-Type:application/json"\
  -H "Accept:applicaton/json"\
  --negotiate -u :\
  --cacert /etc/ipa/ca.crt\
  -d "$json"\
  -X POST\
  $IPA_JSON_URL