开发者

Suggestions on packaging a website for dynamic deployment

开发者 https://www.devze.com 2023-02-06 16:48 出处:网络
I\'m working on a website that I would like to package and have a download-and-ins开发者_如何学编程tall archive, much like wikimedia engine.

I'm working on a website that I would like to package and have a download-and-ins开发者_如何学编程tall archive, much like wikimedia engine.

What are some of the things I need to be considering? Obviously I have to have my index.php file check for user permissions, access to database, then create the tables etc...

What may I be forgetting, or what may be overlooked?


Common things that I think people sometimes overlook in these types of deployments include the following:

1. Eliminating the Dependency on a Specific Hostname.

There should be no mention in the code of any specific hostname. For instance, if you used the url "dev.example.com" when developing the application, and if this is hard-coded in the application, it would create problems during the deployment.

2. Proper and Helpful Error Handling

Unfortunately, most of your users will not have their environment configured exactly as yours.

For example, MySQL database may not be running on the same port, path, etc that it is on your system. Therefore, if the application doesn't connect to the database, it should try to help diagnose why and then print a helpful error message. "MySQL cannot be located, please use port XXXX and make sure it's running at path /var/db/mysql. Edit the XYXYZ.xml configuration file to specify your port and path".

This is just one of many examples. I suggest you try a deployment on a fresh machine -- such as a Virtual Machine -- and then go through the deployment issues one by one and see if you can simplify them.

A hallway usability test with a potential user may also be helpful as it will open your eyes to things you may have missed.

3. Web Server Configuration

Is the web server embedded in your application? Containers like Jetty, Resin, and Restlets for Java can be embedded inside the application. I believe this lowers the configuration overhead as you could control this from within your application much easier than having to force your user to configure IIS or Apache (or whatever web server you are using)

I am not aware if Apache can be embedded, but this may be something to look into: Mongoose Web Server

4. Useful, Easy to Understand Documentation

Oftentimes, I feel many developers overlook this aspect of software development. It's not exciting, but it's absolutely critical for adoption of your product.

I recommend YouTube videos, or just visuals in general. My company started using YouTube as a way to demonstrate how to get started using different products, and people really seem to like it. A picture speaks a thousand words, and they can quickly convey a message that would otherwise take paragraphs to describe.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号