Compare commits

..

3 Commits

4 changed files with 60 additions and 12 deletions

View File

@ -1,11 +1,35 @@
# Logs
logs
*.log
# Runtime data
pids
*.pid
*.seed
# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov
# Coverage directory used by tools like istanbul
coverage
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt
# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release
# Dependency directory
# Deployed apps should consider commenting this line out:
# see https://npmjs.org/doc/faq.html#Should-I-check-my-node_modules-folder-into-git
node_modules
# Webpack output
/dist
###
.git*
Dockerfile
.dockerignore
docker-compose.yml
.git*
*.md

17
Dockerfile Normal file
View File

@ -0,0 +1,17 @@
FROM icedream/caddy
COPY . /src/
RUN \
(cd /src \
&& apk add --no-cache --virtual .build-deps \
nodejs-lts \
&& npm i \
&& NODE_ENV=production npm run build \
&& rm -rf /data \
&& mv dist /data \
&& apk del --no-cache .build-deps \
) \
&& rm -rf /src /tmp/* /var/tmp/*
WORKDIR /data
EXPOSE 2015

View File

@ -39,3 +39,13 @@ module.exports = {
},
},
};
// @HACK - workaround for https://github.com/webpack/webpack/issues/1866
function batchresolve(arr) {
return arr.map(require.resolve);
}
module.exports.babel.presets = batchresolve(module.exports.babel.presets);
module.exports.babel.plugins = batchresolve(module.exports.babel.plugins);

View File

@ -3,7 +3,6 @@ import PropTypes from 'prop-types';
import moment from 'moment-timezone';
import Countdown from './Countdown';
import Header from './Header';
import ProgressCircle from './ProgressCircle';
import getUpcomingDate from './getUpcomingDate';
import style from './App.sass';
@ -61,12 +60,10 @@ class App extends React.Component {
</Header>
<div className={style.content}>
<div className={style.contentContainer}>
<p>
<p>
The next VIzon draw is on {nextUpcomingDate.format('dddd')}, {nextUpcomingDate.format('L LT')}.
</p>
<Countdown date={nextUpcomingDate} />
</div>
</p>
<Countdown date={nextUpcomingDate} />
</div>
</div>
);