简体   繁体   English

Google App Engine上的codeigniter应用程序

[英]codeigniter application on google app engine

I am trying to move a codeigniter application to google app engine.I am using the google app engine launcher to deploy my app.The app seems to load on the localhost as it is throwing me a database error.(I have not connected yet to database ).The following is the output of the app on localhost. 我正在尝试将codeigniter应用程序移动到google app引擎。我正在使用google app引擎启动器来部署我的应用程序。该应用程序似乎已加载到本地主机上,因为它引发了数据库错误。(我尚未连接到数据库)。以下是localhost上应用程序的输出。

A Database Error Occurred.Unable to connect to your database server using the provided settings. 发生数据库错误。无法使用提供的设置连接到数据库服务器。

But when i deployed the app on live server (google app engine) the app was throwing a diffrent error . 但是,当我将应用程序部署到实时服务器(谷歌应用程序引擎)上时,该应用程序抛出了一个不同的错误。

Your application folder path does not appear to be set correctly. 您的应用程序文件夹路径似乎没有正确设置。 Please open the following file and correct this: index.php 请打开以下文件并更正此文件:index.php

The following is my app.yaml for codeignitor 以下是我的codeignitor的app.yaml

application: wantroltd
version: 1
runtime: php
api_version: 1
threadsafe: false

handlers:

- url: /application/*
static_dir: application

- url: /install/*
static_dir: install

- url: /install/*
script: index.php

- url: /(.+\.php)$
script: \1

- url: ./*
script: index.php

I tried changing the application path to './application' and even tried keeping it blank ,but it does not resolve my error . 我尝试将应用程序路径更改为“ ./application” ,甚至尝试将其保留为空白,但无法解决我的错误。 Also my Application folder and index.php are in the same folder and the deployment was successful.What wrong am i doing ? 我的Application文件夹和index.php也在同一个文件夹中,并且部署成功。我在做什么错?

This is a codeignitor error related to your routes being incorrect. 这是与您的路线不正确有关的代码初始化错误。 I would make sure you really understand how codeignitor works in terms of where it expects files to be, and I would double-check that you understand how the app.yaml configuration file works to make sure this aligns with what codeignitor is expecting. 我将确保您确实了解codeignitor在预期文件位置方面的工作方式,并且会再次检查您是否了解app.yaml配置文件的工作方式,以确保它与codeignitor预期的内容保持一致。

The issue here seems very similar . 这里的问题似乎非常相似 You can compare with knowledge of apache's htaccess file to see if your error is the same, but with app.yaml insead of .htaccess. 您可以将其与apache的htaccess文件的知识进行比较,以查看您的错误是否相同,但是app.yaml包含.htaccess。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM