Fixing cleanup script, adding ARM support to dockerfile, as well as adding ARM client.
This commit is contained in:
parent
f8fa52f1b9
commit
9ad9860a9c
|
@ -20,6 +20,8 @@ RUN node /pinVersions.js && yarn && yarn build && /cleanup.sh
|
|||
|
||||
FROM couchdb:3.2.1
|
||||
|
||||
ARG TARGETARCH
|
||||
|
||||
COPY --from=build /app /app
|
||||
COPY --from=build /worker /worker
|
||||
|
||||
|
@ -66,7 +68,7 @@ RUN mkdir /etc/nginx/logs && \
|
|||
WORKDIR /
|
||||
RUN mkdir -p scripts/integrations/oracle
|
||||
ADD packages/server/scripts/integrations/oracle scripts/integrations/oracle
|
||||
RUN /bin/bash -e ./scripts/integrations/oracle/instantclient/linux/x86-64/install.sh
|
||||
RUN /bin/bash -e ./scripts/integrations/oracle/instantclient/linux/install.sh
|
||||
|
||||
# setup clouseau
|
||||
WORKDIR /
|
||||
|
|
Binary file not shown.
|
@ -0,0 +1,23 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Must be root to continue
|
||||
if [[ $(id -u) -ne 0 ]] ; then echo "Please run as root" ; exit 1 ; fi
|
||||
|
||||
# Allow for re-runs
|
||||
rm -rf /opt/oracle
|
||||
|
||||
echo "Installing oracle instant client"
|
||||
|
||||
# copy and unzip package
|
||||
mkdir -p /opt/oracle
|
||||
cp scripts/integrations/oracle/instantclient/linux/arm64/basiclite-19.10.zip /opt/oracle
|
||||
cd /opt/oracle
|
||||
unzip -qq basiclite-19.10.zip -d .
|
||||
rm *.zip
|
||||
mv instantclient* instantclient
|
||||
|
||||
# update runtime link path
|
||||
sh -c "echo /opt/oracle/instantclient > /etc/ld.so.conf.d/oracle-instantclient.conf"
|
||||
ldconfig /etc/ld.so.conf.d
|
||||
|
||||
echo "Installation complete"
|
|
@ -0,0 +1,9 @@
|
|||
#!/bin/bash
|
||||
if [[ $TARGETARCH == arm* ]] ;
|
||||
then
|
||||
echo "Installing ARM Oracle instant client..."
|
||||
arm64/install.sh
|
||||
else
|
||||
echo "Installing x86-64 Oracle instant client..."
|
||||
x86-64/install.sh
|
||||
fi
|
|
@ -1,11 +1,16 @@
|
|||
#!/bin/bash
|
||||
dir=$(pwd)
|
||||
mv dist /
|
||||
mv package.json /
|
||||
declare -a keep=("dist" "package.json" "yarn.lock" "client" "builder" "build" "pm2.config.js" "docker_run.sh")
|
||||
for moveDir in "${keep[@]}"
|
||||
do
|
||||
mv $moveDir / 2>/dev/null
|
||||
done
|
||||
cd /
|
||||
rm -r $dir
|
||||
mkdir $dir
|
||||
mv /dist $dir
|
||||
mv /package.json $dir
|
||||
for keepDir in "${keep[@]}"
|
||||
do
|
||||
mv /$keepDir $dir/ 2>/dev/null
|
||||
done
|
||||
cd $dir
|
||||
NODE_ENV=production yarn
|
||||
|
|
Loading…
Reference in New Issue