使用GAE 1045 PHPMyAdmin错误

时间:2014-09-22 20:15:53

标签: php mysql google-app-engine phpmyadmin google-cloud-sql

要点: 当尝试登录在GAE上运行的PHPMyAdmin时,我不断收到MySQL 1045错误。

疑似问题: 我相信我没有正确连接到CloudSQL的PHP​​MyAdmin环境,但我不确定如何修复它。

文件:

app.yaml - 本教程中使用的原始版本没有用,但我找到了另一个允许我加载页面的版本。这是工作的。     

application: appname
version: phpmyadmin
runtime: php
api_version: 1

handlers:
- url: /phpMyAdmin/(.*\.(ico$|jpg$|png$|gif$))
  static_files: phpMyAdmin/\1
  upload: phpMyAdmin/(.*\.(ico$|jpg$|png$|gif$))
  application_readable: true

- url: /phpMyAdmin/(.*\.(htm$|html$|css$|js$))
  static_files: phpMyAdmin/\1
  upload: phpMyAdmin/(.*\.(htm$|html$|css$|js$))
  application_readable: true

- url: /(.*\.(ico$|jpg$|png$|gif$))
  static_files: phpMyAdmin/\1
  upload: phpMyAdmin/(.*\.(ico$|jpg$|png$|gif$))
  application_readable: true

- url: /(.*\.(htm$|html$|css$|js$))
  static_files: phpMyAdmin/\1
  upload: phpMyAdmin/(.*\.(htm$|html$|css$|js$))
  application_readable: true

- url: /phpMyAdmin/(.*\.(php$))
  script: phpMyAdmin/\1
  login: admin

- url: /(.*\.(php$))
  script: phpMyAdmin/\1
  login: admin

- url: /(.+)
  script: phpMyAdmin/index.php
  login: admin

- url: /.*
  script: phpMyAdmin/index.php
  login: admin

config.inc.php - 我尽可能少编辑。     

/*
 * Servers configuration
 */
$i = 0;
$host = '/cloudsql/gae-project-name:appname';
$type = 'socket';

/*
 * First server
 */
$i++;
/* Authentication type */
$cfg['Servers'][$i]['auth_type'] = 'cookie';
/* Server parameters */
//$cfg['Servers'][$i]['username'] = 'root';
//$cfg['Servers'][$i]['password'] = 'thepassword';
$cfg['Servers'][$i]['socket'] = $host;
//$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['connect_type'] = $type;
$cfg['Servers'][$i]['compress'] = false;
/* Select mysql if your server does not have mysqli */
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['AllowNoPassword'] = false;


//The bottom of the file
$cfg['McryptDisableWarning'] = true;
$cfg['PmaNoRelation_DisableWarning'] = true;
$cfg['ExecTimeLimit'] = 60;
$cfg['CheckConfigurationPermissions'] = false;

GAE: 据我所知,该应用程序已在GAE中列入白名单。它应该可以访问CloudSQL实例。我已多次重置密码,并且我确定它在两个位置都匹配。

背景 我对GAE非常陌生。我仍然不了解GAE,但我已经按照一些基本教程将PHPMyAdmin作为我的应用程序版本加载。原始教程(here)让我无法看到PHPMyAdmin页面。经过一些谷歌搜索后,我发现我需要改变一些app.yaml设置。该页面现在正在运行,但我根本无法登录PHPMyAdmin。

过去我曾使用像WAMP和XAMPP这样的东西来运行MySQL。我过去总是有一个GUI可用于解决这类问题。我也真的只熟悉PHPMyAdmin的MySQL交互,所以如果没有它,我就会失去它。

我会提供您可能需要的任何信息,以帮助我了解问题所在。请告诉我您的需求。

0 个答案:

没有答案