tsuru / mysqlapi

MySQL service API for tsuru PaaS.
BSD 3-Clause "New" or "Revised" License
14 stars 18 forks source link

Error: Failed to create the instance xxx: no such route #39

Closed liudonghua123 closed 8 years ago

liudonghua123 commented 8 years ago

I installed tsuru with now script and following the tutorial Deploying Python applications in tsuru and HOWTO Install a MySQL service, but when I create mysql service instance, I got the following error message.

wlzx@ubuntu:~/tsuru/tsuru-django-sample$ tsuru app-list
+-----------------+-------------------------+-------------------------------------+
| Application     | Units State Summary     | Address                             |
+-----------------+-------------------------+-------------------------------------+
| blog            | 0 of 0 units in-service | blog.113.55.12.64.nip.io            |
+-----------------+-------------------------+-------------------------------------+
| mysql-api       | 1 of 1 units in-service | mysql-api.113.55.12.64.nip.io       |
+-----------------+-------------------------+-------------------------------------+
| tsuru-dashboard | 1 of 1 units in-service | tsuru-dashboard.113.55.12.64.nip.io |
+-----------------+-------------------------+-------------------------------------+
wlzx@ubuntu:~/tsuru/tsuru-django-sample$ tsuru app-info --app blog
Application: blog
Repository: git@113.55.12.64.nip.io:blog.git
Platform: python
Teams: admin
Address: blog.113.55.12.64.nip.io
Owner: admin@example.com
Team owner: admin
Deploys: 0
Pool: theonepool
Quota: 0/-1 units

App Plan:
+---------------+--------+------+-----------+--------+---------+
| Name          | Memory | Swap | Cpu Share | Router | Default |
+---------------+--------+------+-----------+--------+---------+
| autogenerated | 0      | 0    | 100       |        | false   |
+---------------+--------+------+-----------+--------+---------+

wlzx@ubuntu:~/tsuru/tsuru-django-sample$
wlzx@ubuntu:~/tsuru/tsuru-django-sample$ tsuru service-list
+----------+-----------+
| Services | Instances |
+----------+-----------+
| mysqlapi |           |
+----------+-----------+
wlzx@ubuntu:~/tsuru/tsuru-django-sample$ cat ../mysql-api/manifest.yaml 
id: mysqlapi
username: admin
password: admin
team: admin
endpoint:
  production: 113.55.12.64
wlzx@ubuntu:~/tsuru/tsuru-django-sample$ 
wlzx@ubuntu:~/tsuru/tsuru-django-sample$ tsuru service-add mysqlapi blogsq
Error: You must provide a team to execute this action.
wlzx@ubuntu:~/tsuru/tsuru-django-sample$ tsuru service-add mysqlapi blogsq -t admin
Error: Failed to create the instance blogsq: no such route
wlzx@ubuntu:~/tsuru/tsuru-django-sample

Any ideas?

andrewsmedina commented 8 years ago

The mysqlapi endpoint should be the mysql api address. The proper value is mysql-api.113.55.12.64.nip.io instead 113.55.12.64.

You can edit the manifest.yaml and use crane update to update the mysqlapi service.

liudonghua123 commented 8 years ago

@andrewsmedina Yes, that's works, thanks a lot :smile: