Skip to content

Commit

Permalink
Refinements
Browse files Browse the repository at this point in the history
Signed-off-by: osamamagdy <[email protected]>
  • Loading branch information
osamamagdy committed May 16, 2024
1 parent 69a4208 commit e3e4f24
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 4 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@ on:
push:
paths-ignore:
- '**.md'
- '.github/workflows/**'
pull_request:
paths-ignore:
- '**.md'
- '.github/workflows/**'
env:
DOCKER_REGISTRY: 'ghcr.io'
PUSH_TO_MAIN: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
Expand Down
3 changes: 3 additions & 0 deletions config.mk
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ DOCKER_CMD := docker
# - DOCKER_BASE_RT_IMAGE_APT_ADD_PKGS (for all infrastructure containers)
# - DOCKER_BASE_DEV_IMAGE_APT_ADD_PKGS (for all images which build fabric/fpc code)
# - DOCKER_DEV_IMAGE_APT_ADD_PKGS (for dev image)
# - You can mount your local go mod cache directory
# to that of the docker image which allows caching of the dependencies and faster builds
# - GOMODCACHE_PATH (the path of your local go packages usually known by `go env GOMODCACHE`)


# SGX related settings
Expand Down
11 changes: 7 additions & 4 deletions utils/docker/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -78,15 +78,18 @@ endif
# allows to override with `buildx build`
DOCKER_BUILD_CMD ?= build

# allows docker to look for packages mounted on the host
PACKAGE_MOUNT ?=
# allows to mount host gomodcache into the container
GOMODCACHE_PATH ?=
DOCKER_GOMODCACHE=/project/pkg/mod

# Docker run options
# ------------------
DOCKER_DEV_RUN_OPTS ?=
DOCKER_DEV_RUN_OPTS += --rm
# - mount local packages from the host to activate caching
DOCKER_DEV_RUN_OPTS += $(PACKAGE_MOUNT)
# - mount local gomodcache from the host
ifneq ($(GOMODCACHE_PATH),)
DOCKER_DEV_RUN_OPTS += -v "$(GOMODCACHE_PATH)":"$(DOCKER_GOMODCACHE)"
endif
# - import docker daemon socket (so dev container can run docker)
DOCKER_DEV_RUN_OPTS += -v "$(DOCKER_DAEMON_SOCKET)":"$(DOCKER_SOCKET)"
# - mount local fpc repo into the dev container so development inside container is
Expand Down

0 comments on commit e3e4f24

Please sign in to comment.