forked from entrepreneur-interet-general/solidata_backend
-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f7f5fa9
commit ec7b774
Showing
25 changed files
with
851 additions
and
267 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
venv | ||
.git | ||
nginx |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -100,6 +100,7 @@ celerybeat-schedule | |
|
||
# Environments | ||
.env | ||
.env.* | ||
.venv | ||
env/ | ||
venv/ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
export APP=toktok | ||
|
||
export D_FOLDER=docker-files | ||
export DC_FOLDER=dockercomposes | ||
export DF_FOLDER=dockerfiles | ||
|
||
#other variable definition | ||
# DC := docker-compose | ||
# DF := Dockerfile. | ||
|
||
export DC=docker-compose | ||
export DF=Dockerfile. | ||
|
||
export DC_PREFIX= $(shell pwd)/${DC} | ||
export DC_PREFIX_FOLDER= $(shell pwd)/${D_FOLDER}/${DC_FOLDER}/${DC} | ||
|
||
export DC_FOLDER_SUBPATH= ${D_FOLDER}/${DC_FOLDER} | ||
export DF_FOLDER_SUBPATH= ${D_FOLDER}/${DF_FOLDER} | ||
|
||
export APP_PATH := $(shell pwd) | ||
|
||
export BACKEND=${APP_PATH} | ||
export FRONTEND=${APP_PATH} | ||
|
||
|
||
|
||
### ============ ### | ||
### network | ||
### ============ ### | ||
|
||
network-stop: | ||
docker network rm ${APP} | ||
network: | ||
@docker network create ${APP} 2> /dev/null; true | ||
|
||
|
||
### ============ ### | ||
### backend | ||
### ============ ### | ||
|
||
# dev | ||
gunicorn-dev: | ||
${DC} -f ${DC_PREFIX_FOLDER}-gunicorn-dev.yml up --build | ||
gunicorn-dev-stop: | ||
${DC} -f ${DC_PREFIX_FOLDER}-gunicorn-dev.yml down | ||
|
||
# prod | ||
gunicorn-prod: | ||
${DC} -f ${DC_PREFIX_FOLDER}-gunicorn-prod.yml up --build -d | ||
gunicorn-prod-stop: | ||
${DC} -f ${DC_PREFIX_FOLDER}-gunicorn-prod.yml down | ||
|
||
|
||
### ============================= ### | ||
### main make / docker commands | ||
### ============================= ### | ||
|
||
# dev | ||
up: network gunicorn-dev | ||
down: gunicorn-dev-stop network-stop | ||
restart: down up | ||
|
||
# prod | ||
up-prod: network gunicorn-prod | ||
down-prod: gunicorn-prod-stop network-stop | ||
restart-prod: down-prod up-prod |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.