This repository was archived by the owner on Jan 25, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +28
-1
lines changed Expand file tree Collapse file tree 3 files changed +28
-1
lines changed Original file line number Diff line number Diff line change @@ -48,6 +48,7 @@ RUN export DEBIAN_FRONTEND=noninteractive && \
48
48
emacs25-nox \
49
49
esl-erlang \
50
50
expect \
51
+ file \
51
52
fontconfig \
52
53
fontconfig-config \
53
54
g++ \
@@ -465,7 +466,6 @@ ENV DOTNET_ROOT "/opt/buildhome/.dotnet"
465
466
# populate local package cache
466
467
RUN dotnet new
467
468
468
-
469
469
# ###############################################################################
470
470
#
471
471
# Swift
@@ -479,6 +479,20 @@ ENV PATH "$SWIFTENV_ROOT/bin:$SWIFTENV_ROOT/shims:$PATH"
479
479
RUN swiftenv install ${NETLIFY_BUILD_SWIFT_VERSION}
480
480
RUN swift --version
481
481
482
+ # ###############################################################################
483
+ #
484
+ # Homebrew
485
+ #
486
+ # ###############################################################################
487
+ USER buildbot
488
+ RUN /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
489
+ ENV PATH "/opt/buildhome/.linuxbrew/bin:$PATH"
490
+ ENV HOMEBREW_PREFIX "/opt/buildhome/.linuxbrew"
491
+ ENV HOMEBREW_CELLAR "/opt/buildhome/.linuxbrew/Cellar"
492
+ ENV HOMEBREW_REPOSITORY "/opt/buildhome/.linuxbrew/Homebrew"
493
+ ENV HOMEBREW_CACHE "/opt/buildhome/.homebrew-cache"
494
+ RUN brew tap homebrew/bundle
495
+
482
496
WORKDIR /
483
497
484
498
# Cleanup
Original file line number Diff line number Diff line change @@ -72,3 +72,8 @@ The specific patch versions included will depend on when the image was last buil
72
72
* [ Doxygen] ( http://www.doxygen.org ) - 1.8.6
73
73
* [ WASMER] ( https://github.com/wasmerio/wasmer )
74
74
* [ WAPM] ( https://github.com/wasmerio/wapm-cli )
75
+
76
+ * [ Homebrew] ( https://brew.sh/ )
77
+ - Any linux formula is supported: https://formulae.brew.sh/formula-linux/
78
+ - Formulae from a ` Brewfile ` are installed automatically via [ ` brew bundle ` ] ( https://github.com/Homebrew/homebrew-bundle#readme )
79
+ - ` HOMEBREW_BUNDLE_FILE ` is respected
Original file line number Diff line number Diff line change @@ -55,6 +55,7 @@ mkdir -p $NETLIFY_CACHE_DIR/.composer
55
55
mkdir -p $NETLIFY_CACHE_DIR /.gimme_cache/gopath
56
56
mkdir -p $NETLIFY_CACHE_DIR /.gimme_cache/gocache
57
57
mkdir -p $NETLIFY_CACHE_DIR /.wasmer/cache
58
+ mkdir -p $NETLIFY_CACHE_DIR /.homebrew-cache
58
59
59
60
: ${YARN_FLAGS=" " }
60
61
: ${NPM_FLAGS=" " }
@@ -652,6 +653,12 @@ install_dependencies() {
652
653
rm -rf $GOPATH /src/$GO_IMPORT_PATH
653
654
ln -s /opt/buildhome/repo ${GOPATH} /src/$GO_IMPORT_PATH
654
655
fi
656
+
657
+ # Homebrew from Brewfile
658
+ if [ -f Brewfile ] || [ ! -z " $HOMEBREW_BUNDLE_FILE " ]
659
+ then
660
+ brew bundle
661
+ fi
655
662
}
656
663
657
664
#
@@ -675,6 +682,7 @@ cache_artifacts() {
675
682
cache_home_directory " .boot" " boot dependencies"
676
683
cache_home_directory " .composer" " composer dependencies"
677
684
cache_home_directory " .wasmer/cache" , " wasmer cache"
685
+ cache_home_directory " .homebrew-cache" , " homebrew cache"
678
686
679
687
# Don't follow the Go import path or we'll store
680
688
# the origin repo twice.
You can’t perform that action at this time.
0 commit comments