File tree Expand file tree Collapse file tree 4 files changed +27
-4
lines changed
actions/release-server-sync Expand file tree Collapse file tree 4 files changed +27
-4
lines changed Original file line number Diff line number Diff line change 6363 - name : Upload to build server
6464 run : |
6565 ssh $USERNAME@$HOST mkdir -p /home/$USERNAME/apt
66- rsync --include="*/" --include="*.rpm" --include="*.deb" --exclude="*" -amvz packaging/releases/ $USERNAME@$HOST:/home/$USERNAME/apt
66+ rsync --include="*/" \
67+ --include="*.rpm" \
68+ --include="*.deb" \
69+ --include="*.exe" \
70+ --include="*.zip" \
71+ --include="fluent-bit-schema*.json" \
72+ --exclude="*" -amvz \
73+ packaging/releases/ $USERNAME@$HOST:/home/$USERNAME/apt
6774 env :
6875 HOST : ${{ inputs.server_hostname }}
6976 USERNAME : ${{ inputs.server_username }}
Original file line number Diff line number Diff line change @@ -318,8 +318,8 @@ jobs:
318318
319319 - name : Generate schema
320320 run : |
321- docker run --rm -t ${{ inputs.registry }}/${{ inputs.image }}:${{ inputs.version }} -J > fluent-bit-schema.json
322- cat fluent-bit-schema.json | jq -M > fluent-bit-schema-pretty.json
321+ docker run --rm -t ${{ inputs.registry }}/${{ inputs.image }}:${{ inputs.version }} -J > fluent-bit-schema-${{ inputs.version }} .json
322+ cat fluent-bit-schema.json | jq -M > fluent-bit-schema-pretty-${{ inputs.version }} .json
323323 shell : bash
324324
325325 - name : Upload the schema
Original file line number Diff line number Diff line change 9696
9797 - name : Display structure of downloaded files
9898 run : |
99- ls -R
99+ ls -R artifacts/
100100 shell : bash
101101
102102 - name : Push schema to S3 bucket
Original file line number Diff line number Diff line change @@ -122,4 +122,20 @@ if compgen -G "$SOURCE_DIR/windows/*$VERSION*" > /dev/null; then
122122 echo " Copying Windows artefacts"
123123 # shellcheck disable=SC2086
124124 cp -vf " $SOURCE_DIR " /windows/* $VERSION * /var/www/releases.fluentbit.io/releases/" $MAJOR_VERSION " /
125+ else
126+ echo " Missing Windows builds"
127+ fi
128+
129+ # Handle the JSON schema by copying in the new versions (if they exist) and then updating the symlinks that point at the latest.
130+ if compgen -G " $SOURCE_DIR /fluent-bit-schema*.json" > /dev/null; then
131+ echo " Updating JSON schema"
132+ cp -vf " $SOURCE_DIR " /fluent-bit-schema* .json /var/www/releases.fluentbit.io/releases/" $MAJOR_VERSION /"
133+
134+ # Simpler than 'ln --relative --target-directory=/var/www/releases.fluentbit.io/releases/"$MAJOR_VERSION"'
135+ pushd /var/www/releases.fluentbit.io/releases/" $MAJOR_VERSION "
136+ ln -sf " fluent-bit-schema-$VERSION .json" fluent-bit-schema.json
137+ ln -sf " fluent-bit-schema-pretty-$VERSION .json" fluent-bit-schema-pretty.json
138+ popd
139+ else
140+ echo " Missing JSON schema"
125141fi
You can’t perform that action at this time.
0 commit comments