Firepear Container Control
- Shell 100%
| .fpc_local.sh | ||
| fpcc | ||
| LICENSE | ||
| README.md | ||
| RELEASE_NOTES.md | ||
fpcc
Firepear Container Control is my tool for standardizing, building, and maintaining containerized projects.
Config file extensions
fpc-ctl is primarily configured thorugh extensions to a project's
JSON configuration file by adding an fpc-ctl object at the top
level. Its children are objects representing build
configurations. Here's one from thrasher-media-service as an
example:
"fpc-ctl": {
"tms-backend": {
"buildcmd": "go build -o ${build_name} ./cmd/tms-backend",
"configmap": {
"tls": ".tls",
"musicdir": ".musicdir",
"listen-port": ".service.[\"listen-port\"]",
"redir-host": ".service.[\"redir-host\"]"
},
"preqs": "go deno",
"watchfiles": "client/mobile* client/common.js client/client.js cmd/tms-backend/*go *go"
}
}
An explanation of the build configuration points:
buildcmdis the command to run to generate the core build product. This is also used as a pre-build check to ensure that the build is viable before containerization kicks off.${build_name}should appear in the command where you would like the build name substituted.configmapcontrols what will be pulled from elsewhere in the config file for use in the build process. The values arejqexpressions, and the keys will become the keys of the ${config} variable infpc-ctlpreqsis a list of project/build specific prerequisites (only the binary names, no path)watchfilesis a list of paths and/or globs which will be watched for changes whenfpc-ctlis running in devmode
When multiple builds are defined, an attribute named default-build
must be added to the top level of the fpc-ctl object, whose value
specifies the default build.