Windows
Learn how to install Cachet on your Windows server.
Overview
Cachet is constantly evolving, therefore we advise you to download and checkout the latest tagged release. Using a branch such as master
could result in a broken or unstable environment.
Download with Git
Configuring a database
By default, Cachet comes with a .env.example
file. You’ll need to rename this file to just .env
regardless of what environment you’re working on. This is how Laravel 5 deals with configurations.
It’s now just a case of editing this new .env
file and setting the values of your setup.
Here is an example Windows file with a MySQL database:
If you’re using SQLite then your .env
file should not contain a DB_HOST
key. You’ll also need to touch ./database/database.sqlite
and give it the required permissions.
After installation, don’t forget to set APP_DEBUG
to false
to avoid other people to see your application info!
Now, in your Command Prompt, navigate to your Cachet install and run:
Once you have decided on the database driver you’ll be using, you now need to run the migrations to create the tables.
You should see the output of the current project migration files being migrated to your database.
Security Key
Before going any further, we need to set the APP_KEY
config. This is used for all encryption used in Cachet.
Installing Cachet
Cachet comes with an installation command that will:
- Run migrations
- Run seeders (of which there are none)
Never change the APP_KEY
after installation on production environment. This will result in all encrypted/hashed data being lost.
php.ini
Config
Some extensions need to be uncommented in your php.ini
file.
Apache vHosts
Apache is one of the easier installations. We simply need to create a new Virtual Host and add it to our HOSTS
file.
To do this, we simply add the following Virtual Host to our httpd-vhosts.conf
file. Do change this to suit your setup:
❗️ You Need to Enable
mod_rewrite
for Apache.You can do this by finding your
httpd.conf
file and uncommenting the following line:
#LoadModule rewrite_module modules/mod_rewrite.so
The rest of the contents of my httpd.conf
file are as follows: