【发布时间】:2014-07-02 12:13:19
【问题描述】:
请允许我的菜鸟,我正在学习如何使用 Linux Openshift。在阅读一本书时,我尝试从命令行 [Bash] 在线连接到服务器。我跑了
rhc port-forward
并显示:
Checking available ports ... done
Forwarding ports ...
To connect to a service running on OpenShift, use the Local address
Service Local OpenShift
---------- -------------- ---- ---------------
httpd 127.0.0.1:8080 => 127.7.74.1:8080
postgresql 127.0.0.1:5432 => 127.7.74.2:5432
Press CTRL-C to terminate port forwarding
书上说我应该跑
psql -h 127.0.0.1 -p 5433 -U username password
现在为什么每次我运行命令时 bash 都会抱怨,
psql -h 127.0.0.1 ...
它说,找不到 psql 命令。
【问题讨论】:
-
Git?就像在源代码控制中一样? git与psql有什么关系?你真的应该发布整个命令。
-
这是我在 git 中写的全部命令。导航到我的工作文件夹后,我写道:psql -h 127.0.0.1 -p 5433 -U myUsername myAppName。我收到一个错误,即找不到 sh.exe" psql 命令。
-
不,你不要用git写,看看git是什么。你可能是指MINGW。检查您使用的工具以及它们是什么。
-
我已经在 git 中运行了之前的评论,教程没有说我应该改变写字板。请问你用openshift写过应用吗?
-
请参考git文档git-scm.com/documentation它应该可以帮助您了解git是什么,它不是什么。
标签: postgresql openshift psql