Merge branch '8784-dir-listings'
[arvados.git] / tools / arvbox / lib / arvbox / docker / service / vm / run
1 #!/bin/bash
2 # Copyright (C) The Arvados Authors. All rights reserved.
3 #
4 # SPDX-License-Identifier: AGPL-3.0
5
6 set -e
7
8 . /usr/local/lib/arvbox/common.sh
9
10 git config --system "credential.http://$localip:${services[arv-git-httpd]}/.username" none
11 git config --system "credential.http://$localip:${services[arv-git-httpd]}/.helper" '!cred(){ cat >/dev/null; if [ "$1" = get ]; then echo password=$ARVADOS_API_TOKEN; fi; };cred'
12
13 /usr/local/lib/arvbox/runsu.sh $0-service
14
15 cd /usr/src/arvados/services/login-sync
16
17 export ARVADOS_API_HOST=$localip:${services[api]}
18 export ARVADOS_API_HOST_INSECURE=1
19 export ARVADOS_API_TOKEN=$(cat /var/lib/arvados/superuser_token)
20 export ARVADOS_VIRTUAL_MACHINE_UUID=$(cat /var/lib/arvados/vm-uuid)
21
22 while true ; do
23       bundle exec arvados-login-sync
24       sleep 120
25 done