-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
43 lines (32 loc) · 1.05 KB
/
Makefile
File metadata and controls
43 lines (32 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
TAG := $(shell date -u +"17-%Y%m%dT%HZ" )
all: lint build test
build:
docker build \
--tag odoo:latest \
--tag ghcr.io/cbdq-io/odoo:latest \
--tag ghcr.io/cbdq-io/odoo:$(TAG) \
.
clean:
docker compose down -t 0
cleanall: clean
docker system prune --all --force
docker volume prune --all --force
lint:
docker run --rm -i hadolint/hadolint < Dockerfile
pushLatest:
docker push ghcr.io/cbdq-io/odoo:latest
pushTag:
docker push ghcr.io/cbdq-io/odoo:$(TAG)
releaseBranch:
git flow release start $(TAG)
tag:
@echo $(TAG)
test:
docker compose up -d --wait odoo
docker compose exec odoo /usr/local/bin/restore.sh -a secret -d odoo -f /mnt/restore/odoo.zip
docker compose exec odoo /usr/local/bin/backup.sh -a secret -d odoo -f /tmp/test-backup.zip
docker compose exec odoo ls -l /tmp/test-backup.zip
trivy:
trivy image --ignore-unfixed odoo:latest
update-trivy-ignore:
trivy image --format json --ignore-unfixed --severity HIGH,CRITICAL odoo:latest | jq -r '.Results[1].Vulnerabilities[].VulnerabilityID' | sort -u | tee .trivyignore