Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can I've a Docker file for this project? #134

Closed
iamrobins opened this issue Jun 23, 2022 · 5 comments
Closed

Can I've a Docker file for this project? #134

iamrobins opened this issue Jun 23, 2022 · 5 comments

Comments

@iamrobins
Copy link
Contributor

I've Ubuntu 22 and it has Ruby 3 and this project supports Ruby 2. I don't have any experience in Ruby so while installing I was having this error, I tried doing some tweaks to Gem file but didn't work.

Fetching commonmarker 0.17.13
Installing commonmarker 0.17.13 with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

current directory:
/usr/local/bundle/gems/commonmarker-0.17.13/ext/commonmarker
/usr/local/bin/ruby -I /usr/local/lib/ruby/2.7.0 -r
./siteconf20220623-1-152k5yh.rb extconf.rb
creating Makefile

current directory: /usr/local/bundle/gems/commonmarker-0.17.13/ext/commonmarker
make "DESTDIR=" clean
sh: make: not found

current directory: /usr/local/bundle/gems/commonmarker-0.17.13/ext/commonmarker
make "DESTDIR="
sh: make: not found

make failed, exit code 127

Gem files will remain installed in /usr/local/bundle/gems/commonmarker-0.17.13
for inspection.
Results logged to
/usr/local/bundle/extensions/x86_64-linux-musl/2.7.0/commonmarker-0.17.13/gem_make.out

An error occurred while installing commonmarker (0.17.13), and Bundler cannot
continue.
Make sure that `gem install commonmarker -v '0.17.13' --source
'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
  github-pages was resolved to 204, which depends on
    jekyll-commonmark-ghpages was resolved to 0.1.6, which depends on
      jekyll-commonmark was resolved to 1.3.1, which depends on
        commonmarker
The command '/bin/sh -c bundle install' returned a non-zero code: 5

This is the Dockerfile I was trying to make.

FROM ruby:2-alpine

WORKDIR /app

COPY . /app

RUN bundle install

CMD [ "bundle", "exec", "jekyll", "serve" ]
@jglovier
Copy link
Owner

Hi @iamrobins! 👋 Thanks for opening this issue. A dockerfile sounds like a great idea, but unfortunately I don't really have any experience configuring docker for projects and I won't have any development time for this project in which I could learn Docker and contribute what you asking myself in the foreseeable future.

Would you like to contribute the solution yourself? I'll be happy to review and test a PR for it if you take the time to do so! 🙂

@iamrobins
Copy link
Contributor Author

Yeah definitely, I've created a Dockerfile with Ruby 3.0 because older ruby versions were not working for me. Are you planning to upgrade the project to Ruby 3.0 with a new Gemfile.lock ?

I found the fix to run it on Ruby 3.0 in this issue #112

@iamrobins
Copy link
Contributor Author

Hi @jglovier now there is no need to upgrade the project to Ruby 3.0 I have created the Dockerfile which works perfectly with the current state of the project. I've made a PR with 2 lines of instructions in the README. please take a look when you get time.

@jglovier
Copy link
Owner

jglovier commented Jul 2, 2022

Thanks again, @iamrobins!! Resolved by #135.

@jglovier jglovier closed this as completed Jul 2, 2022
@jglovier
Copy link
Owner

jglovier commented Jul 2, 2022

jiggy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants