Skip to content

Commit a8d866e

Browse files
committed
fix log4j in dist build
1 parent ac4429d commit a8d866e

File tree

1 file changed

+15
-5
lines changed

1 file changed

+15
-5
lines changed

.github/workflows/ci.yml

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ jobs:
4343
echo "CLOWDER_VERSION=$(awk '/version = / { print $4 }' project/Build.scala | sed 's/"//g')" >> $GITHUB_ENV
4444
elif [ "$BRANCH" == "develop" ]; then
4545
echo "CLOWDER_VERSION=develop" >> $GITHUB_ENV
46-
else
46+
else
4747
echo "CLOWDER_VERSION=testing" >> $GITHUB_ENV
4848
fi
4949
- uses: actions/setup-java@v1
@@ -97,7 +97,7 @@ jobs:
9797
echo "CLOWDER_VERSION=$(awk '/version = / { print $4 }' project/Build.scala | sed 's/"//g')" >> $GITHUB_ENV
9898
elif [ "$BRANCH" == "develop" ]; then
9999
echo "CLOWDER_VERSION=develop" >> $GITHUB_ENV
100-
else
100+
else
101101
echo "CLOWDER_VERSION=testing" >> $GITHUB_ENV
102102
fi
103103
- uses: actions/setup-java@v1
@@ -141,7 +141,7 @@ jobs:
141141
echo "CLOWDER_VERSION=$(awk '/version = / { print $4 }' project/Build.scala | sed 's/"//g')" >> $GITHUB_ENV
142142
elif [ "$BRANCH" == "develop" ]; then
143143
echo "CLOWDER_VERSION=develop" >> $GITHUB_ENV
144-
else
144+
else
145145
echo "CLOWDER_VERSION=testing" >> $GITHUB_ENV
146146
fi
147147
- uses: actions/setup-java@v1
@@ -164,6 +164,16 @@ jobs:
164164
VERSION: ${{ env.CLOWDER_VERSION }}
165165
BUILDNUMBER: ${{ github.run_number }}
166166
GITSHA1: ${{ github.sha }}
167+
- name: fix log4j
168+
run: |
169+
ZIPFILE=$(ls -1rt target/universal/*.zip | head -1)
170+
DIR=$(basename ${ZIPFILE} .zip)
171+
unzip -q ${ZIPFILE}
172+
for x in $(find ${DIR} -name \*.jar); do
173+
zip -d $x org/apache/log4j/net/JMSAppender.class org/apache/log4j/net/SocketServer.class | grep 'deleting:' && echo "fixed $x"
174+
done
175+
rm ${ZIPFILE}
176+
zip -r ${ZIPFILE} ${DIR}
167177
- uses: actions/upload-artifact@v2
168178
with:
169179
name: clowder.zip
@@ -207,7 +217,7 @@ jobs:
207217
echo "CLOWDER_VERSION=$(awk '/version = / { print $4 }' project/Build.scala | sed 's/"//g')" >> $GITHUB_ENV
208218
elif [ "$BRANCH" == "develop" ]; then
209219
echo "CLOWDER_VERSION=develop" >> $GITHUB_ENV
210-
else
220+
else
211221
echo "CLOWDER_VERSION=testing" >> $GITHUB_ENV
212222
fi
213223
- uses: actions/setup-java@v1
@@ -247,7 +257,7 @@ jobs:
247257
key: ${{ secrets.SCP_KEY }}
248258
files: "target/scala-*/api/*"
249259
target: "CATS/${{ env.CLOWDER_VERSION }}/documentation/scaladoc"
250-
- name: sphinx
260+
- name: sphinx
251261
run: |
252262
cd doc/src/sphinx/
253263
python -m pip install -r requirements.txt

0 commit comments

Comments
 (0)