1.8 KiB
Makefile
Reason
Great to simplify and standardize commons and repetitive tasks.
Definitions
Following the patterns of the definitions document, every task related to
the compilation os preparation of the server for execution will build as part of the name,
while tasks related to the execution itself will be call run.
Common instructions
Build
-
create-build-container: creates the container for building, usingDockerfile.build -
build: build the server inside the container and gets the binary -
build-loc: callsbuildusing local (loc) environment -
build-dev: callsbuildusing development (dev) environment -
build-stg: callsbuildusing staging (stg) environment -
build-prd: callsbuildusing production (prd) environment
Run
-
create-run-container: creates the container for execution, usingDockerfile.run -
run: executes the app inside the container -
run-loc: callsrunusing local (loc) environment -
run-dev: callsrunusing development (dev) environment -
run-stg: callsrunusing staging (stg) environment -
run-prd: callsrunusing production (prd) environment -
run-host: executes the app without a container, directly on the local host
Environment
-
set-loc: defines the environment as "local" (loc) -
set-dev: defines the environment as "development" (dev) -
set-stg: defines the environment as "staging" (stg) -
set-prd: defines the environment as "production" (prd)
Database
migrate: executes the full migration of the database
Tests
test: executes the whole battery of tests
Others
clean: remove binaries and compiled files