-
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'live' into refact/mv-lifecycle-indicat8rs-home
- Loading branch information
Showing
89 changed files
with
11,632 additions
and
3,150 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
3.3.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,154 @@ | ||
/** | ||
* @file Dynamic Babel configuration. | ||
* | ||
* Notes: | ||
* 1. Plugins run before presets. | ||
* 2. Plugin ordering is first to last. | ||
* 3. Preset ordering is reversed (last to first). | ||
* | ||
* @author The OpenINF Authors & Friends | ||
* @module {ES6Module} /.config/babel | ||
* @license MIT OR Apache-2.0 OR BlueOak-1.0.0 | ||
* @see https://babeljs.io/docs/en/plugins#plugin-ordering | ||
*/ | ||
|
||
// ----------------------------------------------------------------------------- | ||
// Requirements | ||
// ----------------------------------------------------------------------------- | ||
|
||
import { packageConfig } from 'shared/constants'; | ||
|
||
// ----------------------------------------------------------------------------- | ||
// Presets | ||
// ----------------------------------------------------------------------------- | ||
|
||
const nodeDevelopmentPresets = [ | ||
[ | ||
// https://babeljs.io/docs/en/babel-preset-env | ||
'@babel/preset-env', | ||
{ | ||
// Module transformations are unnecessary as Node is in ES module context. | ||
// Additionally, CommonJS cannot be treeshaken. | ||
modules: false, | ||
targets: { | ||
esmodules: false, | ||
node: true, | ||
}, | ||
useBuiltIns: 'entry', | ||
corejs: packageConfig.dependencies['core-js'], | ||
}, | ||
], | ||
]; | ||
|
||
const nodeProductionPresets = [ | ||
[ | ||
// https://babeljs.io/docs/en/babel-preset-env | ||
'@babel/preset-env', | ||
{ | ||
// Module transformations are necessary as Node is in CommonJS context. | ||
// modules: false, | ||
// modules: '', | ||
targets: { | ||
esmodules: true, | ||
node: 'current', | ||
}, | ||
loose: true, | ||
include: ['@babel/plugin-transform-classes'], | ||
// 'exclude': ['transform-es2015-typeof-symbol'], | ||
useBuiltIns: 'usage', | ||
corejs: { | ||
version: packageConfig.dependencies['core-js'], | ||
proposals: true, | ||
}, | ||
}, | ||
], | ||
]; | ||
|
||
// ----------------------------------------------------------------------------- | ||
// Plugins | ||
// ----------------------------------------------------------------------------- | ||
|
||
const commonNodePlugins = [ | ||
// https://babeljs.io/docs/en/babel-plugin-proposal-class-properties | ||
// [ | ||
// '@babel/plugin-proposal-class-properties', | ||
// { | ||
// 'loose': true, | ||
// }, | ||
// ], | ||
// https://babeljs.io/docs/en/babel-plugin-syntax-import-meta | ||
'@babel/plugin-syntax-import-meta', | ||
// https://babeljs.io/docs/en/babel-plugin-syntax-dynamic-import | ||
'@babel/plugin-syntax-dynamic-import', | ||
// '@babel/plugin-proposal-object-rest-spread', | ||
'babel-plugin-dynamic-import-node-sync', | ||
// '@babel/plugin-transform-classes', | ||
// https://babeljs.io/docs/en/babel-plugin-transform-modules-commonjs | ||
[ | ||
'@babel/plugin-transform-modules-commonjs', | ||
{ | ||
allowTopLevelThis: false, | ||
}, | ||
], | ||
]; | ||
|
||
const nodeDevelopmentPlugins = [ | ||
// https://babeljs.io/docs/en/babel-plugin-transform-runtime | ||
[ | ||
'@babel/plugin-transform-runtime', | ||
{ | ||
corejs: { version: 3, proposals: true }, | ||
helpers: true, | ||
regenerator: true, | ||
useESModules: false, | ||
}, | ||
], | ||
]; | ||
|
||
const nodeProductionPlugins = [ | ||
// https://babeljs.io/docs/en/babel-plugin-transform-runtime | ||
[ | ||
'@babel/plugin-transform-runtime', | ||
{ | ||
corejs: { version: 3, proposals: true }, | ||
helpers: true, | ||
regenerator: true, | ||
useESModules: true, | ||
}, | ||
], | ||
]; | ||
|
||
// ----------------------------------------------------------------------------- | ||
// Export | ||
// ----------------------------------------------------------------------------- | ||
|
||
const config = (api) => { | ||
// https://babeljs.io/docs/en/config-files#apienv | ||
const envName = api.env(); | ||
|
||
// eslint-disable-next-line no-console | ||
console.log(`Babel was loaded with the '${envName}' environment.`); | ||
|
||
switch (envName) { | ||
case 'development': | ||
return { | ||
presets: nodeDevelopmentPresets, | ||
plugins: commonNodePlugins.concat(nodeDevelopmentPlugins), | ||
ignore: [], | ||
}; | ||
case 'production': | ||
return { | ||
presets: nodeProductionPresets, | ||
plugins: commonNodePlugins.concat(nodeProductionPlugins), | ||
ignore: [], | ||
}; | ||
default: | ||
return { | ||
presets: nodeDevelopmentPresets, | ||
plugins: commonNodePlugins.concat(nodeDevelopmentPlugins), | ||
ignore: [], | ||
}; | ||
} | ||
}; | ||
|
||
export default config; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
|
||
nodeProductionOptions = nodeProductionOptions.join(' '); | ||
nodeDevelopmentOptions = nodeDevelopmentOptions.join(' '); | ||
|
||
// ----------------------------------------------------------------------------- | ||
// Export | ||
// ----------------------------------------------------------------------------- | ||
|
||
export default { | ||
'development': { | ||
// Development | ||
// https://github.com/visionmedia/debug#environment-variables | ||
'DEBUG': '*', | ||
// https://www.dynatrace.com/news/blog/the-drastic-effects-of-omitting-node-env-in-your-express-js-applications/ | ||
// https://dzone.com/articles/what-you-should-know-about-node-env | ||
'NODE_ENV': 'development', | ||
// https://nodejs.org/api/all.html#cli_node_options_options | ||
'NODE_OPTIONS': nodeDevelopmentOptions, | ||
}, | ||
'production': { | ||
// Production | ||
// https://github.com/visionmedia/debug#environment-variables | ||
'DEBUG': false, | ||
// https://nodejs.org/en/docs/guides/simple-profiling/ | ||
// https://webpack.js.org/guides/environment-variables/ | ||
'NODE_ENV': 'production', | ||
// https://nodejs.org/api/all.html#cli_node_options_options | ||
'NODE_OPTIONS': nodeProductionOptions, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
FROM openinf/grimesai-salvage-tex:lunar@sha256:85db277df2bb6b07922478085cd612a67a9a7d3923b09135a7f6bd9bd65ca89a | ||
|
||
ARG USERNAME=vscode | ||
ARG NPM_GLOBAL=/usr/local/share/npm-global | ||
|
||
# Add NPM global to PATH. | ||
ENV PATH=${NPM_GLOBAL}/bin:${PATH} | ||
|
||
ARG USERNAME=vscode | ||
ARG USER_UID=1000 | ||
ARG USER_GID=$USER_UID | ||
ARG UPGRADE_PACKAGES="true" | ||
|
||
USER 0 | ||
|
||
# COPY library-scripts/*.sh /tmp/library-scripts/ | ||
# skipcq: DOK-DL3008 | ||
RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \ | ||
# && /bin/bash /tmp/library-scripts/common-debian.sh "${USERNAME}" "${USER_UID}" "${USER_GID}" "${UPGRADE_PACKAGES}" \ | ||
# && /bin/bash /tmp/library-scripts/fish-debian.sh "${USERNAME}" \ | ||
# && /bin/bash /tmp/library-scripts/sshd-debian.sh "2222" "${USERNAME}" "true" "root" \ | ||
# | ||
# **************************************************************************** | ||
# * TODO: Add any additional OS packages you want included in the definition * | ||
# * here. We want to do this before cleanup to keep the "layer" small. * | ||
# **************************************************************************** | ||
&& apt-get -y install --no-install-recommends build-essential default-jre ruby-dev git-lfs \ | ||
&& apt-get clean \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
USER vscode | ||
|
||
# ENV Variables required by Jekyll. | ||
ENV LANG=en_US.UTF-8 \ | ||
LANGUAGE=en_US:en \ | ||
TZ=Etc/UTC \ | ||
LC_ALL=en_US.UTF-8 \ | ||
LANG=en_US.UTF-8 \ | ||
LANGUAGE=en_US | ||
|
||
ENTRYPOINT ["/usr/local/share/ssh-init.sh"] | ||
CMD ["sleep", "infinity"] |
Oops, something went wrong.