diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index fd052c819..76071ff92 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -3,7 +3,7 @@ stages: - lint tests: - image: "ruby:2.6.8" + image: "ruby:2.7.4" stage: test services: - postgres:10.10 @@ -34,7 +34,7 @@ tests: # PRONTO_GITLAB_API_PRIVATE_TOKEN to your repository CI/CD settings # giving it the value of the Personal Access Token linters: - image: "ruby:2.6.8" + image: "ruby:2.7.4" stage: lint cache: key: consul diff --git a/.ruby-version b/.ruby-version index 743af5e12..a4dd9dba4 100644 --- a/.ruby-version +++ b/.ruby-version @@ -1 +1 @@ -2.6.8 +2.7.4 diff --git a/Dockerfile b/Dockerfile index 6274055fd..9fc8d5e51 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM ruby:2.6.8-buster +FROM ruby:2.7.4-buster ENV DEBIAN_FRONTEND noninteractive @@ -34,9 +34,6 @@ COPY Gemfile.lock Gemfile.lock COPY Gemfile_custom Gemfile_custom -# Prevent bundler warnings; ensure that the bundler version executed is >= that which created Gemfile.lock -RUN gem install bundler - # Finish establishing our Ruby environment RUN bundle install --full-index diff --git a/Gemfile.lock b/Gemfile.lock index cd9f7cdd8..fdb96a2f4 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -795,4 +795,4 @@ DEPENDENCIES wkhtmltopdf-binary (~> 0.12.6) BUNDLED WITH - 1.17.2 + 2.1.4 diff --git a/README.md b/README.md index 06689b681..101fb333c 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ You can access the main website of the project at [http://consulproject.org](htt **NOTE**: For more detailed instructions check the [docs](https://docs.consulproject.org) -Prerequisites: install git, Ruby 2.6.8, CMake, pkg-config, shared-mime-info, Node.js and PostgreSQL (>=9.5). +Prerequisites: install git, Ruby 2.7.4, CMake, pkg-config, shared-mime-info, Node.js and PostgreSQL (>=9.5). ```bash git clone https://github.com/consul/consul.git diff --git a/README_ES.md b/README_ES.md index dbef26e87..afbae802d 100644 --- a/README_ES.md +++ b/README_ES.md @@ -36,7 +36,7 @@ Puedes acceder a la página principal del proyecto en [http://consulproject.org] **NOTA**: para unas instrucciones más detalladas consulta la [documentación](https://docs.consulproject.org) -Prerequisitos: tener instalado git, Ruby 2.6.8, CMake, pkg-config, shared-mime-info, Node.js y PostgreSQL (9.5 o superior). +Prerequisitos: tener instalado git, Ruby 2.7.4, CMake, pkg-config, shared-mime-info, Node.js y PostgreSQL (9.5 o superior). ```bash git clone https://github.com/consul/consul.git diff --git a/config/initializers/paperclip.rb b/config/initializers/paperclip.rb new file mode 100644 index 000000000..97a4079d9 --- /dev/null +++ b/config/initializers/paperclip.rb @@ -0,0 +1,13 @@ +class Paperclip::UrlGenerator + private + + # Code copied from the paperclip gem, only replacing + # `URI.escape` with `URI::DEFAULT_PARSER.escape` + def escape_url(url) + if url.respond_to?(:escape) + url.escape + else + URI::DEFAULT_PARSER.escape(url).gsub(escape_regex) { |m| "%#{m.ord.to_s(16).upcase}" } + end + end +end