mirror of
https://github.com/yavook/kiwi-scp.git
synced 2024-11-21 12:23:00 +00:00
rename docker-compose variables
This commit is contained in:
parent
261ee7bf59
commit
b30188c8dc
2 changed files with 9 additions and 9 deletions
|
@ -31,7 +31,7 @@ services:
|
|||
environment:
|
||||
MYSQL_ROOT_PASSWORD: changeme
|
||||
volumes:
|
||||
- "${TARGETDIR}/db:/var/lib/mysql"
|
||||
- "${KIWI_PROJECT}/db:/var/lib/mysql"
|
||||
|
||||
adminer:
|
||||
# admin interface for databases
|
||||
|
@ -46,10 +46,10 @@ services:
|
|||
- "8081:8080"
|
||||
|
||||
another-web:
|
||||
# Another webserver just to show off the ${CONFIGDIR} variable
|
||||
# Another webserver just to show off the ${KIWI_CONFIG} variable
|
||||
image: nginx:stable-alpine
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- "8082:80"
|
||||
volumes:
|
||||
- "${CONFIGDIR}/html/index.html:/usr/share/nginx/html/index.html:ro"
|
||||
- "${KIWI_CONFIG}/html/index.html:/usr/share/nginx/html/index.html:ro"
|
||||
|
|
|
@ -39,18 +39,18 @@ class Project:
|
|||
directory: Path = self.directory
|
||||
project_name: str = self.name
|
||||
kiwi_hub_name: str = self.parent_instance.config.network.name
|
||||
target_root_dir: Path = self.parent_instance.config.storage.directory
|
||||
conf_dir: Path = target_root_dir.joinpath(CONFIG_DIRECTORY_NAME)
|
||||
target_dir: Path = target_root_dir.joinpath(project_name)
|
||||
kiwi_instance_dir: Path = self.parent_instance.config.storage.directory
|
||||
kiwi_config_dir: Path = kiwi_instance_dir.joinpath(CONFIG_DIRECTORY_NAME)
|
||||
kiwi_project_dir: Path = kiwi_instance_dir.joinpath(project_name)
|
||||
|
||||
result: Dict[str, Any] = {
|
||||
"cwd": str(directory),
|
||||
"env": {
|
||||
"COMPOSE_PROJECT_NAME": project_name,
|
||||
"KIWI_HUB_NAME": kiwi_hub_name,
|
||||
"TARGETROOT": str(target_root_dir),
|
||||
"CONFIGDIR": str(conf_dir),
|
||||
"TARGETDIR": str(target_dir),
|
||||
"KIWI_INSTANCE": str(kiwi_instance_dir),
|
||||
"KIWI_CONFIG": str(kiwi_config_dir),
|
||||
"KIWI_PROJECT": str(kiwi_project_dir),
|
||||
},
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue