build: remove ngcontainer Docker (#36421)
ngcontainer Dockerfile was noted as deprecated ~2 years ago, we no longer rely on it anymore nor do we publish it. PR Close #36421
This commit is contained in:
parent
bd9c1e6cfc
commit
20346ff192
|
@ -1009,7 +1009,6 @@ groups:
|
||||||
'tools/circular_dependency_test/**',
|
'tools/circular_dependency_test/**',
|
||||||
'tools/contributing-stats/**',
|
'tools/contributing-stats/**',
|
||||||
'tools/gulp-tasks/**',
|
'tools/gulp-tasks/**',
|
||||||
'tools/ngcontainer/**',
|
|
||||||
'tools/npm/**',
|
'tools/npm/**',
|
||||||
'tools/npm_integration_test/**',
|
'tools/npm_integration_test/**',
|
||||||
'tools/rxjs/**',
|
'tools/rxjs/**',
|
||||||
|
|
|
@ -1,66 +0,0 @@
|
||||||
FROM circleci/node:10.9.0-browsers
|
|
||||||
|
|
||||||
USER root
|
|
||||||
|
|
||||||
###
|
|
||||||
# Bazel install
|
|
||||||
# See https://bazel.build/versions/master/docs/install-ubuntu.html#using-bazel-custom-apt-repository-recommended
|
|
||||||
# Note, only the latest release is available, see https://github.com/bazelbuild/bazel/issues/4947
|
|
||||||
RUN BAZEL_VERSION="0.18.0" \
|
|
||||||
&& wget -q -O - https://bazel.build/bazel-release.pub.gpg | apt-key add - \
|
|
||||||
&& echo "deb [arch=amd64] http://storage.googleapis.com/bazel-apt stable jdk1.8" > /etc/apt/sources.list.d/bazel.list \
|
|
||||||
&& apt-get update \
|
|
||||||
&& apt-get install -y bazel=$BAZEL_VERSION \
|
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
|
||||||
|
|
||||||
###
|
|
||||||
# Brotli compression
|
|
||||||
# Not available on backports so we have to pull from Debian 9
|
|
||||||
# See https://packages.debian.org/search?keywords=brotli
|
|
||||||
RUN echo "deb http://deb.debian.org/debian stretch main contrib" > /etc/apt/sources.list.d/stretch.list \
|
|
||||||
&& apt-get update \
|
|
||||||
&& apt-get install -y --no-install-recommends brotli/stretch
|
|
||||||
|
|
||||||
###
|
|
||||||
# Buildifier
|
|
||||||
# TODO(alexeagle): remove this when all users use their locally built buildifier
|
|
||||||
# BUILD file formatter
|
|
||||||
# 'bazel clean --expunge' conserves size of the image
|
|
||||||
RUN git clone https://github.com/bazelbuild/buildtools.git \
|
|
||||||
&& (cd buildtools \
|
|
||||||
&& bazel build //buildifier \
|
|
||||||
&& cp bazel-bin/buildifier/linux_amd64_stripped/buildifier /usr/local/bin/ \
|
|
||||||
&& bazel clean --expunge \
|
|
||||||
) && rm -rf buildtools
|
|
||||||
|
|
||||||
###
|
|
||||||
# Skylint
|
|
||||||
# TODO(alexeagle): remove this when all users use their locally built skylint
|
|
||||||
# .bzl file linter
|
|
||||||
# Follows readme at https://github.com/bazelbuild/bazel/blob/master/site/docs/skylark/skylint.md#building-the-linter
|
|
||||||
# 'bazel clean --expunge' conserves size of the image
|
|
||||||
RUN git clone https://github.com/bazelbuild/bazel.git \
|
|
||||||
&& (cd bazel \
|
|
||||||
&& bazel build //src/tools/skylark/java/com/google/devtools/skylark/skylint:Skylint_deploy.jar \
|
|
||||||
&& cp bazel-bin/src/tools/skylark/java/com/google/devtools/skylark/skylint/Skylint_deploy.jar /usr/local/bin \
|
|
||||||
&& bazel clean --expunge \
|
|
||||||
) && rm -rf bazel
|
|
||||||
|
|
||||||
USER circleci
|
|
||||||
|
|
||||||
###
|
|
||||||
# Fix up npm global installation
|
|
||||||
# See https://docs.npmjs.com/getting-started/fixing-npm-permissions
|
|
||||||
RUN mkdir ~/.npm-global \
|
|
||||||
&& npm config set prefix '~/.npm-global' \
|
|
||||||
&& echo "export PATH=~/.npm-global/bin:$PATH" >> ~/.profile
|
|
||||||
|
|
||||||
###
|
|
||||||
# This version of ChromeDriver works with the Chrome version included
|
|
||||||
# in the circleci/*-browsers base image above.
|
|
||||||
# This variable is intended to be used by passing it as an argument to
|
|
||||||
# "postinstall": "webdriver-manager update ..."
|
|
||||||
ENV CHROMEDRIVER_VERSION_ARG "--versions.chrome 2.41"
|
|
||||||
|
|
||||||
WORKDIR /home/circleci
|
|
||||||
ENTRYPOINT ["/bin/bash", "--login"]
|
|
|
@ -1,55 +0,0 @@
|
||||||
# ngcontainer
|
|
||||||
|
|
||||||
This docker container provides everything needed to build and test Angular applications:
|
|
||||||
|
|
||||||
**Note**: This docker image will be no longer actively updated. Consider using other Docker
|
|
||||||
images that come with Node installed.
|
|
||||||
|
|
||||||
- node 10.9.0
|
|
||||||
- npm 6.2.0
|
|
||||||
- yarn 1.9.2
|
|
||||||
- Java 8 (for Closure Compiler and Bazel)
|
|
||||||
- Bazel build tool v0.18.0 - http://bazel.build
|
|
||||||
- Google Chrome 69.0.3497.81
|
|
||||||
- Mozilla Firefox 47.0.1
|
|
||||||
- xvfb (virtual framebuffer) for headless testing
|
|
||||||
- Brotli compression utility, making smaller files than gzip
|
|
||||||
|
|
||||||
By using this, you avoid installation steps in your CI scripts and get a more consistent dev environment.
|
|
||||||
|
|
||||||
## Example
|
|
||||||
|
|
||||||
See https://github.com/angular/closure-demo/blob/master/.circleci/config.yml
|
|
||||||
where this container is used in CircleCI.
|
|
||||||
|
|
||||||
To run locally:
|
|
||||||
|
|
||||||
```
|
|
||||||
$ docker run -it --rm angular/ngcontainer
|
|
||||||
```
|
|
||||||
|
|
||||||
## Running tests
|
|
||||||
|
|
||||||
Any program that needs to talk to a browser (eg. protractor) should be run under xvfb when executing on a headless machine like on CI. The nice way to factor this is to have your top-level test command which you run locally:
|
|
||||||
|
|
||||||
```
|
|
||||||
$ yarn test
|
|
||||||
```
|
|
||||||
|
|
||||||
Then in your CI configuration, you'd run
|
|
||||||
|
|
||||||
```
|
|
||||||
$ xvfb-run -a yarn test
|
|
||||||
```
|
|
||||||
|
|
||||||
## For Developers
|
|
||||||
|
|
||||||
Install Docker on your machine in order to build/pull/push this image.
|
|
||||||
|
|
||||||
Log in to `hub.docker.com` as `teamangular` using the following command:
|
|
||||||
|
|
||||||
`$ docker login`
|
|
||||||
|
|
||||||
Publish a new version:
|
|
||||||
|
|
||||||
`$ tools/ngcontainer/publish.sh [tag eg. 0.2.3]`
|
|
|
@ -1,13 +0,0 @@
|
||||||
set -e
|
|
||||||
|
|
||||||
TAG=$1
|
|
||||||
if [ -z $TAG ]
|
|
||||||
then echo "usage: $0 [tag]"; exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
docker build . -t angular/ngcontainer:$TAG
|
|
||||||
docker tag angular/ngcontainer:$TAG angular/ngcontainer:latest
|
|
||||||
docker push angular/ngcontainer:$TAG
|
|
||||||
docker push angular/ngcontainer:latest
|
|
||||||
git tag -a "ngcontainer_${TAG}" -m "published to docker"
|
|
||||||
git push --tags
|
|
Loading…
Reference in New Issue