You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dlab.apache.org by dm...@apache.org on 2019/04/26 13:29:14 UTC
[incubator-dlab] branch DLAB-433 updated: [DLAB-433] Fixed syntax
error in fab.py
This is an automated email from the ASF dual-hosted git repository.
dmysakovets pushed a commit to branch DLAB-433
in repository https://gitbox.apache.org/repos/asf/incubator-dlab.git
The following commit(s) were added to refs/heads/DLAB-433 by this push:
new 4fb6bad [DLAB-433] Fixed syntax error in fab.py
4fb6bad is described below
commit 4fb6bad5202067751e8b42e37d0a06a2e3975c1c
Author: Dyoma33 <de...@gmail.com>
AuthorDate: Fri Apr 26 16:28:52 2019 +0300
[DLAB-433] Fixed syntax error in fab.py
---
infrastructure-provisioning/src/general/lib/os/fab.py | 6 +++---
.../src/jupyter-docker/scripts/configure_jupyter-docker_node.py | 1 -
2 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/infrastructure-provisioning/src/general/lib/os/fab.py b/infrastructure-provisioning/src/general/lib/os/fab.py
index c551ab2..ff1ea95 100644
--- a/infrastructure-provisioning/src/general/lib/os/fab.py
+++ b/infrastructure-provisioning/src/general/lib/os/fab.py
@@ -193,7 +193,7 @@ def configure_jupyter(os_user, jupyter_conf_file, templates_dir, jupyter_version
print('Error:', str(err))
sys.exit(1)
-def configure_docker(os_user, docker_version):
+def configure_docker(os_user, docker_version, docker_conf_file):
try:
if not exists('/home/' + os_user + '/.ensure_dir/docker_ensured'):
sudo('curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add -')
@@ -208,8 +208,8 @@ def configure_docker(os_user, docker_version):
sudo('touch {}'.format(https_file))
sudo('echo -e \'[Service] \nEnvironment=\"\'$http_proxy\'\"\' > {}'.format(https_file))
sudo('mkdir /home/{}/.docker'.format(os_user))
- sudo('touch {}'.format(docker_conf_file))
- sudo('echo -e \'{\n "proxies":\n {\n "default":\n {\n "httpProxy":"\'$http_proxy\'",\n "httpsProxy":"\'$http_proxy\'"\n }\n }\n}\' > {}'.format(docker_conf_file))
+ sudo('touch /home/{}/.docker/config.json'.format(os_user))
+ sudo('echo -e \'{\n "proxies":\n {\n "default":\n {\n "httpProxy":"\'$http_proxy\'",\n "httpsProxy":"\'$http_proxy\'"\n }\n }\n}\' > /home/dlab-user/.docker/config.json')
sudo('usermod -a -G docker ' + os_user)
sudo('update-rc.d docker defaults')
sudo('update-rc.d docker enable')
diff --git a/infrastructure-provisioning/src/jupyter-docker/scripts/configure_jupyter-docker_node.py b/infrastructure-provisioning/src/jupyter-docker/scripts/configure_jupyter-docker_node.py
index 384fe86..eecdb22 100644
--- a/infrastructure-provisioning/src/jupyter-docker/scripts/configure_jupyter-docker_node.py
+++ b/infrastructure-provisioning/src/jupyter-docker/scripts/configure_jupyter-docker_node.py
@@ -55,7 +55,6 @@ else:
docker_version = '18.09.4'
http_file = '/etc/systemd/system/docker.service.d/http-proxy.conf'
https_file = '/etc/systemd/system/docker.service.d/https-proxy.conf'
-docker_conf_file = '/home/' + os_user + '/.docker/config.json'
jupyter_dir = '/home/' + args.os_user + '/.jupyter/'
pyspark_local_path_dir = '/home/' + args.os_user + '/.jupyter/kernels/pyspark_local/'
py3spark_local_path_dir = '/home/' + args.os_user + '/.jupyter/kernels/py3spark_local/'
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@dlab.apache.org
For additional commands, e-mail: commits-help@dlab.apache.org