potiuk commented on a change in pull request #4938: [AIRFLOW-4117]
Multi-staging Image - Travis CI tests [Step 3/3]
URL: https://github.com/apache/airflow/pull/4938#discussion_r298467844
##########
File path: docs/build.sh
##########
@@ -18,38 +18,74 @@
# specific language governing permissions and limitations
# under the License.
-set -e
+set -euo pipefail
-FWDIR="$(cd "`dirname "$0"`"; pwd)"
-cd "$FWDIR"
+MY_DIR="$(cd "`dirname "$0"`"; pwd)"
+pushd "${MY_DIR}" || exit 1
-NUM_INCORRECT_USE_LITERALINCLUDE_DIRECTIVE=$(grep -inR --include \*.rst
'literalinclude::.\+example_dags' .\
- tee /dev/tty |\
+if [[ ${APT_DEPS_IMAGE:=""} != "" ]]; then
+ # We are inside the container which means that we should fix permissions
of the _build folder files
+ # Those files are mounted from the host!
+ echo "Changing ownership of docs/_build folder to
${AIRFLOW_USER}:${AIRFLOW_USER}"
+ sudo chown ${AIRFLOW_USER}:${AIRFLOW_USER} _build
+ echo "Changed ownership of docs/_build folder to
${AIRFLOW_USER}:${AIRFLOW_USER}"
Review comment:
I see your point. I actually like to have before/after clearly displayed in
the logs in case something fails. It's not a big overhead (and of course you
could just could just echo when you start. But being a little more verbose is I
think better (and you see exactly when things fail - you see it from the logs
rather than by looking into the sources of the script). I found it really
useful at a number of times.
Besides in come CI systems (we are considering switching now) you can see
the timings for each line - and it makes it a bit easier to see start/stop and
calculate length of a task.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services