create-directus-docker 1.3.5 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -37,6 +37,10 @@ As an alternative, you can install this package by following these steps. Once y
|
|
|
37
37
|
|
|
38
38
|
*Note that you'll only have to do these two steps the first time you run this.*
|
|
39
39
|
|
|
40
|
+
### Seeding MySQL data
|
|
41
|
+
|
|
42
|
+
If you want to seed your database with data on first launch, place your .sql file(s) in the "init" directory at the root of this package. MySQL will run any files in this directory the first time it launches.
|
|
43
|
+
|
|
40
44
|
### Starting/stopping with Docker Compose
|
|
41
45
|
|
|
42
46
|
To **stop** your running containers, simply run `docker compose down` in your terminal from within the project directory. All containers will be stopped.
|
|
@@ -56,6 +56,12 @@ try {
|
|
|
56
56
|
});
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
+
if (fs.existsSync(path.join(rootPath, 'init')) === false) {
|
|
60
|
+
fs.mkdir(path.join(rootPath, 'init'), () => {
|
|
61
|
+
//console.log(`'init' directory created. If you want to seed your database on first lanch, place your .sql file(s) in this directory BEFORE running services.`);
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
|
|
59
65
|
inquirer.prompt([
|
|
60
66
|
{
|
|
61
67
|
name: 'ADMIN_EMAIL',
|
|
@@ -169,7 +175,9 @@ try {
|
|
|
169
175
|
|
|
170
176
|
writeStream.end();
|
|
171
177
|
|
|
172
|
-
console.log("\nYou can always edit the variables that we've just set in the .env file manually.\n");
|
|
178
|
+
console.log("\nYou can always edit the variables that we've just set in the .env file manually.\n\n");
|
|
179
|
+
console.log(chalk.redBright("If you want to seed your database on first launch, place your .sql file(s) in the \"init\" directory BEFORE running services."));
|
|
180
|
+
console.log("");
|
|
173
181
|
|
|
174
182
|
inquirer.prompt([
|
|
175
183
|
{
|