Skip to content

Commit

Permalink
⤵️ automation(synchronize) Applying changes from upstream repository.
Browse files Browse the repository at this point in the history
  • Loading branch information
Megabyte Labs committed Feb 18, 2022
1 parent 339bc3a commit 8765b56
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 7 deletions.
19 changes: 15 additions & 4 deletions .config/taskfiles/docker/Taskfile-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,29 @@ tasks:
sh: echo "{{.DOCKERHUB_PROFILE}}/{{if .CLI_ARGS}}{{.CLI_ARGS}}{{else}}$(jq -r '.blueprint.slug' package.json){{end}}"
REVISION:
sh: git rev-parse HEAD
SLUG:
sh: |
{{if .CLI_ARGS}}
if echo '{{.CLI_ARGS}}' | grep 'codeclimate-' > /dev/null; then
echo '{{.CLI_ARGS}}'
else
echo 'false'
fi
{{else}}
echo "codeclimate-$(jq -r '.blueprint.slug' package.json)"
{{end}}
VERSION: latest
log:
error: Error building `{{.DOCKER_IMAGE}}:{{.VERSION}}`
start: Building Docker container `{{.DOCKER_IMAGE}}:{{.VERSION}}` (also tagged as latest)
success: Successfully built Docker container named `{{.DOCKER_IMAGE}}:{{.VERSION}}`
cmds:
- .config/log info 'Running `docker build --build-arg BUILD_DATE={{.BUILD_DATE}} --build-arg REVISION={{.REVISION}} --build-arg VERSION={{.VERSION}}
--tag {{.DOCKER_IMAGE}}:latest --tag {{.DOCKER_IMAGE}}:{{.VERSION}}
{{if eq .REPOSITORY_SUBTYPE "codeclimate"}}--tag codeclimate/codeclimate-{{.SLUG}}:latest{{end}}{{if .CLI_ARGS}} --target {{.CLI_ARGS}}{{end}} .`'
--tag {{.DOCKER_IMAGE}}:latest --tag {{.DOCKER_IMAGE}}:{{.VERSION}} {{if eq .REPOSITORY_SUBTYPE "codeclimate"}}{{if ne .SLUG "false"}}
--tag codeclimate/{{.SLUG}}:latest{{end}}{{end}}{{if .CLI_ARGS}} --target {{.CLI_ARGS}}{{end}} .`'
- docker build --build-arg BUILD_DATE={{.BUILD_DATE}} --build-arg REVISION={{.REVISION}} --build-arg VERSION={{.VERSION}}
--tag {{.DOCKER_IMAGE}}:latest --tag {{.DOCKER_IMAGE}}:{{.VERSION}}
{{if eq .REPOSITORY_SUBTYPE "codeclimate"}}--tag codeclimate/codeclimate-{{.SLUG}}:latest{{end}}{{if .CLI_ARGS}} --target {{.CLI_ARGS}}{{end}} .
--tag {{.DOCKER_IMAGE}}:latest --tag {{.DOCKER_IMAGE}}:{{.VERSION}}{{if eq .REPOSITORY_SUBTYPE "codeclimate"}}{{if ne .SLUG "false"}}
--tag codeclimate/{{.SLUG}}:latest{{end}}{{end}}{{if .CLI_ARGS}} --target {{.CLI_ARGS}}{{end}} .
sources:
- Dockerfile
- package.json
Expand Down
13 changes: 10 additions & 3 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 8765b56

Please sign in to comment.