More staging fun

This commit is contained in:
Karl Cordes 2020-07-14 17:24:53 +10:00
parent b63cd779d5
commit a88e007e78
2 changed files with 1 additions and 39 deletions

View file

@ -1,28 +1,5 @@
<?php <?php
//CakePHP is pretty awful. I was so foolish.
if($_SERVER["SERVER_NAME"] == "localhost") {
class DATABASE_CONFIG {
var $default = array(
'driver' => 'mysql',
'persistent' => false,
'host' => '172.17.0.1',
'login' => 'cmc',
'password' => 'cmc',
'database' => 'cmc',
'prefix' => '',
);
}
} else {
class DATABASE_CONFIG { class DATABASE_CONFIG {
var $default = array( var $default = array(
@ -35,18 +12,3 @@ if($_SERVER["SERVER_NAME"] == "localhost") {
'prefix' => '', 'prefix' => '',
); );
// there are no tests...
var $test = array(
'driver' => 'mysql',
'persistent' => false,
'host' => 'localhost',
'login' => 'user',
'password' => 'password',
'database' => 'test_database_name',
'prefix' => '',
);
}
}

View file

@ -1,3 +1,3 @@
ID=$(docker ps -f ancestor=cmc:staging -q) ID=$(docker ps -f ancestor=cmc:stg -q)
docker kill $ID docker kill $ID
docker build -f Dockerfile_stg . -t "cmc:stg" docker build -f Dockerfile_stg . -t "cmc:stg"