This repository was archived by the owner on Nov 15, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 69
Expand file tree
/
Copy pathAzkfile.js
More file actions
69 lines (68 loc) · 2.04 KB
/
Azkfile.js
File metadata and controls
69 lines (68 loc) · 2.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
/**
* Documentation: http://docs.azk.io/Azkfile.js
*/
// Adds the systems that shape your system
systems({
orcamentos: {
// Dependent systems
depends: ["mysql"],
// More images: http://images.azk.io
image: {"docker": "azukiapp/php-fpm:5.6"},
// Steps to execute before running instances
provision: [
"composer update",
],
workdir: "/azk/#{manifest.dir}",
shell: "/bin/bash",
wait: {"retry": 20, "timeout": 1000},
command: "./start.sh",
mounts: {
'/azk/#{manifest.dir}': sync("."),
'/azk/#{manifest.dir}/vendor': persistent("./vendor"),
'/azk/#{manifest.dir}/composer.lock': path("./composer.lock"),
'/azk/#{manifest.dir}/.env.php': path("./.env.php"),
'/azk/#{manifest.dir}/bootstrap/compiled.php': path("./bootstrap/compiled.php"),
},
scalable: {"default": 1},
http: {
domains: [ "#{system.name}.#{azk.default_domain}" ]
},
ports: {
// exports global variables
http: "80/tcp",
},
envs: {
// Make sure that the PORT value is the same as the one
// in ports/http below, and that it's also the same
// if you're setting it in a .env file
PUBLIC_DIR: "/azk/#{manifest.dir}",
},
},
mysql: {
// Dependent systems
depends: [],
// More images: http://images.azk.io
image: {"docker": "azukiapp/mysql:5.6"},
shell: "/bin/bash",
wait: {"retry": 25, "timeout": 1000},
mounts: {
'/var/lib/mysql': persistent("mysql_#{manifest.dir}"),
},
ports: {
// exports global variables
data: "3306:3306/tcp",
},
envs: {
// set instances variables
MYSQL_ROOT_PASSWORD: "orcamentos",
MYSQL_USER: "orcamentos",
MYSQL_PASS: "orcamentos",
MYSQL_DATABASE: "orcamentos",
},
export_envs: {
// check this gist to configure your database
// https://gist.github.com/gullitmiranda/62082f2e47c364ef9617
DATABASE_URL: "mysql2://#{envs.MYSQL_USER}:#{envs.MYSQL_PASS}@#{net.host}:#{net.port.data}/${envs.MYSQL_DATABASE}",
},
},
});