From f88529642a845ab8997d6306f62ed91e76ec86ce Mon Sep 17 00:00:00 2001 From: Vincent Fiduccia Date: Tue, 24 Apr 2018 11:21:49 -0700 Subject: [PATCH 1/2] Base URL --- Dockerfile.staging | 2 +- gulpfile.babel.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile.staging b/Dockerfile.staging index 54510d5450e..93247e0817a 100644 --- a/Dockerfile.staging +++ b/Dockerfile.staging @@ -23,5 +23,5 @@ RUN gulp build-staging RUN stat /run/public/index.html FROM nginx -COPY --from=build /run/public /usr/share/nginx/html/ +COPY --from=build /run/public /usr/share/nginx/html/docs/ COPY nginx.conf /etc/nginx/conf.d/default.conf diff --git a/gulpfile.babel.js b/gulpfile.babel.js index 2a4d0b2aa45..08f66e8dd36 100644 --- a/gulpfile.babel.js +++ b/gulpfile.babel.js @@ -45,14 +45,14 @@ gulp.task('build-dev', () => { }); gulp.task('hugo', (cb) => { - return spawn('hugo', ['--buildFuture'], { stdio: 'inherit' }).on('close', (/* code */) => { + return spawn('hugo', ['--buildFuture', '--baseURL=/docs'], { stdio: 'inherit' }).on('close', (/* code */) => { browserSync.reload(); cb(); }); }); gulp.task('hugo-staging', (cb) => { - return spawn('hugo', ['--buildDrafts', '--buildFuture'], { stdio: 'inherit' }).on('close', (/* code */) => { + return spawn('hugo', ['--buildDrafts', '--buildFuture', '--baseURL=/docs'], { stdio: 'inherit' }).on('close', (/* code */) => { browserSync.reload(); cb(); }); From 851959ab80b2d7604eb8c20235f612fd785aad50 Mon Sep 17 00:00:00 2001 From: Vincent Fiduccia Date: Tue, 24 Apr 2018 16:47:03 -0700 Subject: [PATCH 2/2] Force pull on dev script --- scripts/dev | 1 + 1 file changed, 1 insertion(+) diff --git a/scripts/dev b/scripts/dev index 20b02f180be..62d0a96d660 100755 --- a/scripts/dev +++ b/scripts/dev @@ -64,4 +64,5 @@ if [[ "$THEME" ]]; then THEMEVOLUME="-v ${ABSOLUTE}:/run/node_modules/rancher-website-theme" fi +docker pull rancher/docs:dev docker run --rm -p ${PORT}:${PORT} -it -v $(pwd):/site ${THEMEVOLUME} rancher/docs:dev dev --port=${PORT}