Merge branch 'master' into 4186-install-doc-improvements
[arvados.git] / doc / admin / cheat_sheet.html.textile.liquid
1 ---
2 layout: default
3 navsection: admin
4 title: Cheat Sheet
5 ...
6
7
8
9 h3. CLI setup
10
11 <pre>
12 ARVADOS_API_HOST={{ site.arvados_api_host }}
13 ARVADOS_API_TOKEN=1234567890qwertyuiopasdfghjklzxcvbnm1234567890zzzz
14 </pre>
15
16 h3. Create VM
17
18 <pre>
19 arv virtual_machine create --virtual-machine '{"hostname":"xxxxxxxchangeme.example.com"}'
20 </pre>
21
22 h3. Activate user
23
24 <pre>
25 user_uuid=xxxxxxxchangeme
26
27 arv user update --uuid "$user_uuid" --user '{"is_active":true}'
28 </pre>
29
30 h3. User &rarr; VM
31
32 Give @$user_uuid@ permission to log in to @$vm_uuid@ as @$target_username@
33
34 <pre>
35 user_uuid=xxxxxxxchangeme
36 vm_uuid=xxxxxxxchangeme
37 target_username=xxxxxxxchangeme
38
39 read -rd $'\000' newlink <<EOF; arv link create --link "$newlink"
40 {
41 "tail_uuid":"$user_uuid",
42 "head_uuid":"$vm_uuid",
43 "link_class":"permission",
44 "name":"can_login",
45 "properties":{"username":"$target_username"}
46 }
47 EOF
48 </pre>
49
50 h3. User &rarr; repo
51
52 Give @$user_uuid@ permission to commit to @$repo_uuid@ as @$repo_username@
53
54 <pre>
55 user_uuid=xxxxxxxchangeme
56 repo_uuid=xxxxxxxchangeme
57 repo_username=xxxxxxxchangeme
58
59 read -rd $'\000' newlink <<EOF; arv link create --link "$newlink"
60 {
61 "tail_uuid":"$user_uuid",
62 "head_uuid":"$repo_uuid",
63 "link_class":"permission",
64 "name":"can_write",
65 "properties":{"username":"$repo_username"}
66 }
67 EOF
68 </pre>