diff --git a/sh/build.sh b/sh/build.sh new file mode 100644 index 0000000..aff0cf4 --- /dev/null +++ b/sh/build.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +source ./config.sh + +docker build -t "${IMAGE}:${VERSION}" . --no-cache + +docker tag "${IMAGE}:${TAGS_NAME}" ${ADDRESS}:${TAGS_NAME} + +docker push ${ADDRESS}:${TAGS_NAME} \ No newline at end of file diff --git a/sh/create_produce.sh b/sh/build_produce.sh similarity index 86% rename from sh/create_produce.sh rename to sh/build_produce.sh index 8282428..929170a 100644 --- a/sh/create_produce.sh +++ b/sh/build_produce.sh @@ -5,7 +5,7 @@ RPC_CONTAINER="transfer_middleware" RPC_PORT="10001" V_REFLECT="" TAGS_NAME="v1" -ADDRESS="registry.cn-chengdu.aliyuncs.com/go_ls/transfer_middleware_produce" +ADDRESS="registry.cn-chengdu.aliyuncs.com/go_ls/transfer_middleware" docker build -t "${IMAGE}:${TAGS_NAME}" . --no-cache diff --git a/sh/build_test.sh b/sh/build_test.sh new file mode 100644 index 0000000..929170a --- /dev/null +++ b/sh/build_test.sh @@ -0,0 +1,14 @@ +#!/bin/bash + +IMAGE="transfer_middleware" +RPC_CONTAINER="transfer_middleware" +RPC_PORT="10001" +V_REFLECT="" +TAGS_NAME="v1" +ADDRESS="registry.cn-chengdu.aliyuncs.com/go_ls/transfer_middleware" + +docker build -t "${IMAGE}:${TAGS_NAME}" . --no-cache + +docker tag "${IMAGE}:${TAGS_NAME}" ${ADDRESS}:${TAGS_NAME} + +docker push ${ADDRESS}:${TAGS_NAME} \ No newline at end of file diff --git a/sh/config.sh b/sh/config.sh new file mode 100644 index 0000000..e69de29 diff --git a/sh/create.sh b/sh/depoly.sh similarity index 51% rename from sh/create.sh rename to sh/depoly.sh index 1c7b921..f5c9aa2 100755 --- a/sh/create.sh +++ b/sh/depoly.sh @@ -7,4 +7,8 @@ V_REFLECT="" docker build -t "${IMAGE}" . --no-cache +docker stop "${RPC_CONTAINER}" +docker rm "${RPC_CONTAINER}" + +#docker run -it -p "${RPC_PORT}:${RPC_PORT}" --name "$RPC_CONTAINER" "${IMAGE}" \ No newline at end of file diff --git a/until/Dockerfile b/until/Dockerfile deleted file mode 100644 index d219bff..0000000 --- a/until/Dockerfile +++ /dev/null @@ -1,5 +0,0 @@ -FROM alpine:latest AS runtime -RUN apk update && apk add supervisor -RUN apk add make -RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g' /etc/apk/repositories -ENV TZ Asia/Shanghai \ No newline at end of file diff --git a/until/env.go b/until/env.go new file mode 100644 index 0000000..12923ba --- /dev/null +++ b/until/env.go @@ -0,0 +1 @@ +package until