Skip to content

Commit

Permalink
fix koyeb dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
storytellerF committed Jan 28, 2025
1 parent ca4db96 commit c09b224
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
8 changes: 1 addition & 7 deletions Dockerfile.patched
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,6 @@ ARG DATABASE_PASS
ENV DATABASE_PASS=$DATABASE_PASS
ARG DATABASE_FRONT_PORT
ENV DATABASE_FRONT_PORT=$DATABASE_FRONT_PORT
ARG HMAC_KEY
ENV HMAC_KEY=$HMAC_KEY
ARG BUNKER_VERSION
ENV BUNKER_VERSION=$BUNKER_VERSION
ARG BUNKER_PORT
Expand Down Expand Up @@ -108,8 +106,6 @@ ARG PRESET_ENCRYPTED_URI
ENV PRESET_ENCRYPTED_URI=$PRESET_ENCRYPTED_URI
ARG PRESET_ENCRYPTED_PASSWORD
ENV PRESET_ENCRYPTED_PASSWORD=$PRESET_ENCRYPTED_PASSWORD
ARG REMOTE_ENCODED_CERT
ENV REMOTE_ENCODED_CERT=$REMOTE_ENCODED_CERT
ARG SNAPSHOT_KEYSTORE_PATH
ENV SNAPSHOT_KEYSTORE_PATH=$SNAPSHOT_KEYSTORE_PATH
ARG SNAPSHOT_KEYSTORE_PASS
Expand Down Expand Up @@ -154,7 +150,6 @@ DATABASE_DRIVER=${DATABASE_DRIVER}
DATABASE_USER=${DATABASE_USER}
DATABASE_PASS=${DATABASE_PASS}
DATABASE_FRONT_PORT=${DATABASE_FRONT_PORT}
HMAC_KEY=${HMAC_KEY}
BUNKER_VERSION=${BUNKER_VERSION}
BUNKER_PORT=${BUNKER_PORT}
BUNKER_PORT_SECRET=${BUNKER_PORT_SECRET}
Expand All @@ -172,11 +167,10 @@ PRESET_WORKING_DIR=${PRESET_WORKING_DIR}
PRESET_SCRIPT=${PRESET_SCRIPT}
PRESET_ENCRYPTED_URI=${PRESET_ENCRYPTED_URI}
PRESET_ENCRYPTED_PASSWORD=${PRESET_ENCRYPTED_PASSWORD}
REMOTE_ENCODED_CERT=${REMOTE_ENCODED_CERT}
SNAPSHOT_KEYSTORE_PATH=${SNAPSHOT_KEYSTORE_PATH}
SNAPSHOT_KEYSTORE_PASS=${SNAPSHOT_KEYSTORE_PASS}
EOF
COPY ./${FLAVOR}.env ./build/envs/.env
RUN cp ./${FLAVOR}.env ./build/envs/.env


RUN find scripts/ -type f \( -name "*.sh" -o -name "*.js" \) -exec sed -i 's/\r$//' {} + && \
Expand Down
2 changes: 1 addition & 1 deletion scripts/tool_scripts/patch-koyeb-env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ while IFS= read -r key; do
done < "$env_filter_file"

# 完成 COPY 块的 EOF 部分
replace_string_2+="EOF\nCOPY ./\${FLAVOR}.env ./build/envs/.env\n"
replace_string_2+="EOF\nRUN cp ./\${FLAVOR}.env ./build/envs/.env\n"

# 使用 sed 替换 dockerfile 模板中的 #1 和 #2
sed -e "s|#1|$replace_string_1|" -e "s|#2|$replace_string_2|" -e "s|#3|$replace_string_3|" "$dockerfile_template" > "$dockerfile_output"
Expand Down

0 comments on commit c09b224

Please sign in to comment.