summaryrefslogtreecommitdiffstats
path: root/scripts/group-remove-member.sh
blob: f58b7b0d867c234e20be8d74cf1816c03303aaa5 (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
25
#!/bin/sh +x

. ./include.sh

json="{
    \"method\": \"group_remove_member\",
    \"params\": [
        [ \"testgroup\" ],
        {
            \"user\": \"testuser,admin\"
        }
    ]
}"

# \"user\": [ \"testuser\", \"admin\" ]
#    \"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