Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
docker run \
> -d \
> -p 80:80 \
> --name saas-nginx \
> --network=odoo-saas \
> -t itprojectsllc/docker-odoo-nginx
Unable to find image 'itprojectsllc/docker-odoo-nginx:latest' locally
latest: Pulling from itprojectsllc/docker-odoo-nginx
43c265008fae: Pull complete
e4c030a565b1: Pull complete
685b7631c1ce: Pull complete
28178f28eca1: Pull complete
Digest: sha256:d85f9a96e9a83337fbe2ede4137f07ff0204ed5dfbd7a46934394dea4e4c5b41
Status: Downloaded newer image for itprojectsllc/docker-odoo-nginx:latest
b9e02568c6e135477b4c03a8804d25725773e8de22b40e5dd6ff733fa4ee7b10
MacBook-Pro-4:oodoo aale$
MacBook-Pro-4:oodoo aale$ INIT_SAAS_TOOLS_VALUE=' \
> --portal-create \
> --server-create \
> --plan-create \
> --odoo-script=/mnt/odoo-source/odoo-bin \
> --odoo-config=/mnt/config/odoo-server.conf \
> --portal-db-name=portal \
> --server-db-name=server-1 \
> --server-hosts-template={dbname}.{base_saas_domain_1} \
> --plan-template-db-name=template-1 \
> --plan-clients=demo-%i \
> ' && docker exec -u root -t odoo /bin/bash \
> -c "export INIT_SAAS_TOOLS='$INIT_SAAS_TOOLS_VALUE'; bash /install-odoo-saas.sh"
SYSTEM=supervisor
PLATFORM=unknown
OS_RELEASE=jessie
-su: /root/.bash_profile: Permission denied
2018-06-03 18:37:19
saas.py >>> Read odoo config, /mnt/config/odoo-server.conf
2018-06-03 18:37:19
saas.py >>> Waiting for port, 127.0.0.1, 8069
2018-06-03 18:37:19
saas.py >>> Port is used. Probably, odoo is already running. Let's try to use it. It it will fail, you need either stop odoo or pass another port to saas.py via --xmlrpc-port arg
2018-06-03 18:37:19
saas.py >>> create database via xmlrpc, portal
2018-06-03 18:38:58
saas.py >>> auth, ('portal', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:38:58
saas.py >>> RPC Execute, ir.module.module, search, [[('state', '=', 'uninstalled'), ('name', 'in', ['saas_portal_start', 'saas_portal', 'saas_portal_sale_online'])]], {}
2018-06-03 18:38:58
saas.py >>> auth, ('portal', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:38:58
saas.py >>> RPC Execute, ir.module.module, button_immediate_install, [[1064, 565, 137]], {}
2018-06-03 18:40:35
saas.py >>> auth, ('portal', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:40:35
saas.py >>> RPC Execute, ir.config_parameter, set_param, ['saas_portal.base_saas_domain', 'portal'], {}
2018-06-03 18:40:35
saas.py >>> auth, ('portal', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:40:35
saas.py >>> RPC Execute, ir.config_parameter, set_param, ['auth_signup.allow_uninvited', 'True'], {}
2018-06-03 18:40:35
saas.py >>> create database via xmlrpc, server-1
2018-06-03 18:42:08
saas.py >>> auth, ('server-1', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:08
saas.py >>> RPC Execute, ir.module.module, search, [[('state', '=', 'uninstalled'), ('name', 'in', ['saas_server'])]], {}
2018-06-03 18:42:08
saas.py >>> auth, ('server-1', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:08
saas.py >>> RPC Execute, ir.module.module, button_immediate_install, [[485]], {}
2018-06-03 18:42:27
saas.py >>> auth, ('server-1', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:27
saas.py >>> RPC Execute, ir.model.data, xmlid_to_res_id, ['saas_server.saas_oauth_provider'], {}
2018-06-03 18:42:27
saas.py >>> auth, ('server-1', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:27
saas.py >>> RPC Execute, auth.oauth.provider, read, [4], {}
2018-06-03 18:42:27
saas.py >>> auth, ('server-1', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:27
saas.py >>> RPC Execute, auth.oauth.provider, write, [[4], {'local_host': 'localhost', 'local_port': '8069', 'validation_endpoint': 'http://portal/oauth2/tokeninfo', 'auth_endpoint': 'http://portal/oauth2/auth'}], {}
2018-06-03 18:42:28
saas.py >>> auth, ('server-1', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:28
saas.py >>> RPC Execute, ir.config_parameter, get_param, ['database.uuid'], {}
2018-06-03 18:42:28
saas.py >>> auth, ('portal', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:28
saas.py >>> RPC Execute, saas_portal.server, create, [{'local_host': 'localhost', 'clients_host_template': '{dbname}.{base_saas_domain_1}', 'name': 'server-1', 'client_id': '9e5776d0-675d-11e8-a65d-0242ac1d0003', 'local_port': '8069', 'password': 'admin'}], {}
2018-06-03 18:42:28
saas.py >>> auth, ('portal', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:28
saas.py >>> RPC Execute, saas_portal.server, search, [[]], {}
2018-06-03 18:42:29
saas.py >>> search server, [1]
2018-06-03 18:42:29
saas.py >>> auth, ('portal', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:29
saas.py >>> RPC Execute, saas_portal.database, create, [{'name': 'template-1'}], {}
2018-06-03 18:42:29
saas.py >>> auth, ('portal', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:29
saas.py >>> RPC Execute, saas_portal.plan, create, [{'server_id': 1, 'dbname_template': 'demo-%i', 'name': 'Plan', 'template_id': 1}], {}
2018-06-03 18:42:29
saas.py >>> Dropping database template-1
2018-06-03 18:42:29
saas.py >>> Result: DROP DATABASE
2018-06-03 18:42:29
saas.py >>> EXEC: , rm -rf /mnt/data-dir/filestore/template-1
2018-06-03 18:42:29
saas.py >>> auth, ('portal', <ServerProxy for localhost:8069/xmlrpc/2/object>, 1, 'admin')
2018-06-03 18:42:29
saas.py >>> RPC Execute, saas_portal.plan, create_template, [[1]], {}
MacBook-Pro-4:oodoo aale$
MacBook-Pro-4:oodoo aale$
MacBook-Pro-4:oodoo aale$
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment