2015年8月11日 星期二

Cloud9-RoR-mysql安裝篇

在Cloud9的視窗下方,有個「bash-帳號-專案-不知名編號」的視窗,輸入下方連結的指令

https://docs.c9.io/docs/setup-a-database 官網提供的文件


安裝mysql

$ mysql-ctl install

不過本來就有安裝了,所以會先stop然後在starting,然後秀出

MySQL 5.5 database added.  Please make note of these credentials:

Root User: username
Database Name: c9

mysql的使用ip是127.0.0.1,port則是3306。

控制mysql

$ mysql-ctl cli
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 24
Server version: 5.5.37-0ubuntu0.14.04.1 (Ubuntu)

Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql>  show databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| c9                 |
| mysql              |
| performance_schema |
+--------------------+
4 rows in set (0.15 sec)

接著就是安裝phpmyadmin了,下一篇唄。(先不做,apache會與rails衝途)






沒有留言:

張貼留言