Skip to content

Commit

Permalink
chore: prevent installing homebrew-core when installing homebrew (#201)
Browse files Browse the repository at this point in the history
- There are some default libraries that contain test code that triggers
  our security scanners. Having homebrew installed should be sufficient
  for users. This will eventually be the default for all brew users anyway.
  See Homebrew/brew#13794 (comment)
- Update installed Go to 1.20
- Update Ruby to 2.7.7
- Update docker-compose to 2.16.0
  • Loading branch information
sreya authored Feb 14, 2023
1 parent df40363 commit 0913166
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions images/base/Dockerfile.centos
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ RUN dnf config-manager --add-repo https://download.docker.com/linux/centos/docke
systemctl enable docker

# Add docker-compose
RUN curl -L "https://github.com/docker/compose/releases/download/v2.5.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
RUN curl -L "https://github.com/docker/compose/releases/download/v2.16.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
RUN chmod +x /usr/local/bin/docker-compose

# Make typing unicode characters in the terminal work.
Expand All @@ -51,5 +51,5 @@ RUN useradd coder \
USER coder

# install Homebrew, must be as a non-root user
RUN /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
RUN HOMEBREW_INSTALL_FROM_API=1 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
ENV PATH /home/linuxbrew/.linuxbrew/bin:${PATH}
4 changes: 2 additions & 2 deletions images/base/Dockerfile.ubuntu
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ RUN apt-get update && \
RUN systemctl enable docker

# Add docker-compose
RUN curl -L "https://github.com/docker/compose/releases/download/v2.5.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
RUN curl -L "https://github.com/docker/compose/releases/download/v2.16.0/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
RUN chmod +x /usr/local/bin/docker-compose

# Make typing unicode characters in the terminal work.
Expand All @@ -58,5 +58,5 @@ RUN useradd coder \
USER coder

# install Homebrew, must be as a non-root user
RUN /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
RUN HOMEBREW_INSTALL_FROM_API=1 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
ENV PATH /home/linuxbrew/.linuxbrew/bin:${PATH}
2 changes: 1 addition & 1 deletion images/golang/Dockerfile.centos
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ FROM codercom/enterprise-base:centos
USER root

# Install go
RUN curl -L "https://dl.google.com/go/go1.17.1.linux-amd64.tar.gz" | tar -C /usr/local -xzvf -
RUN curl -L "https://go.dev/dl/go1.20.linux-amd64.tar.gz" | tar -C /usr/local -xzvf -

# Setup go env vars
ENV GOROOT /usr/local/go
Expand Down
2 changes: 1 addition & 1 deletion images/golang/Dockerfile.ubuntu
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ FROM codercom/enterprise-base:ubuntu
USER root

# Install go
RUN curl -L "https://dl.google.com/go/go1.17.1.linux-amd64.tar.gz" | tar -C /usr/local -xzvf -
RUN curl -L "https://go.dev/dl/go1.20.linux-amd64.tar.gz" | tar -C /usr/local -xzvf -

# Setup go env vars
ENV GOROOT /usr/local/go
Expand Down
4 changes: 2 additions & 2 deletions images/ruby/install-ruby.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
set -euo pipefail

RUBY_MAJOR=2.7
RUBY_VERSION=2.7.2
RUBY_SHA256=6e5706d0d4ee4e1e2f883db9d768586b4d06567debea353c796ec45e8321c3d4
RUBY_VERSION=2.7.7
RUBY_SHA256=e10127db691d7ff36402cfe88f418c8d025a3f1eea92044b162dd72f0b8c7b90
RUBY_DOWNLOAD_PATH=/tmp/ruby.tar.gz
RUBY_SOURCE_DIR=/tmp/ruby-${RUBY_VERSION}

Expand Down

0 comments on commit 0913166

Please sign in to comment.