From 51276134ebf042a370359e7a30a336cf3d27fc08 Mon Sep 17 00:00:00 2001 From: cnphpbb Date: Sun, 26 Jan 2025 04:35:49 +0800 Subject: [PATCH] add(builder): add golang stack --- builder/golang/compose.yml | 17 +++++++++++++++++ builder/golang/env.cnf | 5 +++++ 2 files changed, 22 insertions(+) create mode 100644 builder/golang/compose.yml create mode 100644 builder/golang/env.cnf diff --git a/builder/golang/compose.yml b/builder/golang/compose.yml new file mode 100644 index 0000000..dcf10b6 --- /dev/null +++ b/builder/golang/compose.yml @@ -0,0 +1,17 @@ +# path:: mkdir -pv /data/volumes/memos/data +# run:: docker compose -p memos --env-file ./memos/env.cfg -f ./memos/prod.stack.yml up -d + +services: + + golang: + image: ${IMAGE_TAG_BASH} + container_name: "build-golang" + restart: always + tty: true + command: bash + volumes: + - ${Volumes_Path}/mygits:/app + working_dir: /app + environment: + - GOPROXY=https://goproxy.cn + - GO111MODULE=on \ No newline at end of file diff --git a/builder/golang/env.cnf b/builder/golang/env.cnf new file mode 100644 index 0000000..1c46af6 --- /dev/null +++ b/builder/golang/env.cnf @@ -0,0 +1,5 @@ +IMAGE_TAG_BASH=golang:1.23.5-bookworm +IMAGE_TAG_ASH=golang:1.23.5-alpine +#IMAGE_TAG_BASH=golang:1.22.11-bookworm +#IMAGE_TAG_ASH=golang:1.22.11-alpine +Volumes_Path=/data/volumes \ No newline at end of file