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

Dockerfile will not build #88

Open
pvalena opened this issue Sep 27, 2018 · 6 comments
Open

Dockerfile will not build #88

pvalena opened this issue Sep 27, 2018 · 6 comments
Labels

Comments

@pvalena
Copy link
Contributor

pvalena commented Sep 27, 2018

Because content is no .git repository.

  • Possibly missing VOLUME in Dockerfile
  • Make build non-failing in case content is not a git repository.

https://hub.docker.com/r/developerportal/devel/builds/

@pvalena pvalena added the bug label Sep 27, 2018
@darshkpatel darshkpatel mentioned this issue Oct 3, 2018
@Joshua-rose
Copy link
Contributor

Joshua-rose commented Apr 21, 2020

I ran into this same issue. The content folder is a git submodule. It should be downloaded because --recursive is called in the Dockerfile.

I resolved it by cloning the content repo into the website -> content folder.

Here is more information on git submodules. https://git-scm.com/book/en/v2/Git-Tools-Submodules

@pvalena
Copy link
Contributor Author

pvalena commented Apr 22, 2020

I ran into this same issue. The content folder is a git submodule. It should be downloaded because --recursive is called in the Dockerfile.

Yes, that should work, as described in DEVELOPMENT.md f.e.. I didn't get around to fix the Dockerfile yet, feel free to submit PRs.

@Camilotk
Copy link
Contributor

Camilotk commented May 30, 2021

Getting this error every time i try to run the project after clone content.

I already made changes in content and it's working for add OCaml language in /tech and I'm trying add the static files to the website.

I already:

  • Try run on docker
  • run ./setup.sh and jekyll
  • run with jekyll serve --force_polling -H 0.0.0.0 -l -I -w
  • build
  • clone as separate projects
  • clone using --recursive
  • clone using --recurse-submodules
  • clone and move/copy content folder
  • clone and them use git submodule update --init --recursive

all them result in this error:

Configuration file: /home/ccazevedo/Programas/website/_config.yml
            Source: /home/ccazevedo/Programas/website
       Destination: /home/ccazevedo/Programas/website/_site
 Incremental build: disabled. Enable with --incremental
      Generating... 
       Git authors: Generating authors...
  Liquid Exception: Could not find document 'start/sw/gui-app/about.md' in tag 'link'. Make sure the document exists and the path is correct. in content/start/sw/web-app/about.md
                    ------------------------------------------------
      Jekyll 4.2.0   Please append `--trace` to the `build` command 
                     for any additional information or backtrace. 
                    ------------------------------------------------
/usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/tags/link.rb:32:in `render': Could not find document 'start/sw/gui-app/about.md' in tag 'link'. (ArgumentError)

Make sure the document exists and the path is correct.
	from /usr/share/gems/gems/liquid-4.0.3/lib/liquid/block_body.rb:103:in `render_node_to_output'
	from /usr/share/gems/gems/liquid-4.0.3/lib/liquid/block_body.rb:91:in `render'
	from /usr/share/gems/gems/liquid-4.0.3/lib/liquid/template.rb:208:in `block in render'
	from /usr/share/gems/gems/liquid-4.0.3/lib/liquid/template.rb:242:in `with_profiling'
	from /usr/share/gems/gems/liquid-4.0.3/lib/liquid/template.rb:207:in `render'
	from /usr/share/gems/gems/liquid-4.0.3/lib/liquid/template.rb:220:in `render!'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/liquid_renderer/file.rb:39:in `block (3 levels) in render!'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/liquid_renderer/file.rb:59:in `measure_counts'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/liquid_renderer/file.rb:38:in `block (2 levels) in render!'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/liquid_renderer/file.rb:63:in `measure_bytes'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/liquid_renderer/file.rb:37:in `block in render!'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/liquid_renderer/file.rb:70:in `measure_time'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/liquid_renderer/file.rb:36:in `render!'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/renderer.rb:131:in `render_liquid'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/renderer.rb:80:in `render_document'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/renderer.rb:63:in `run'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/site.rb:547:in `render_regenerated'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/site.rb:539:in `block in render_pages'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/site.rb:538:in `each'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/site.rb:538:in `render_pages'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/site.rb:211:in `render'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/site.rb:80:in `process'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/command.rb:28:in `process_site'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/commands/build.rb:65:in `build'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/commands/build.rb:36:in `process'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/command.rb:91:in `block in process_with_graceful_fail'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/command.rb:91:in `each'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/command.rb:91:in `process_with_graceful_fail'
	from /usr/share/gems/gems/jekyll-4.2.0/lib/jekyll/commands/build.rb:18:in `block (2 levels) in init_with_program'
	from /usr/share/gems/gems/mercenary-0.4.0/lib/mercenary/command.rb:221:in `block in execute'
	from /usr/share/gems/gems/mercenary-0.4.0/lib/mercenary/command.rb:221:in `each'
	from /usr/share/gems/gems/mercenary-0.4.0/lib/mercenary/command.rb:221:in `execute'
	from /usr/share/gems/gems/mercenary-0.4.0/lib/mercenary/program.rb:44:in `go'
	from /usr/share/gems/gems/mercenary-0.4.0/lib/mercenary.rb:21:in `program'
	from /usr/share/gems/gems/jekyll-4.2.0/exe/jekyll:15:in `<top (required)>'
	from /usr/bin/jekyll:23:in `load'

seems as this file is on the path where it says that it can't find it.

Don't know if I'm doing something wrong, any help here?

@pvalena
Copy link
Contributor Author

pvalena commented May 30, 2021

Hello, yes I had the same issue. Not sure what causes it.

Try applying this commit to content: developer-portal/content@dc8a4a3

I've had to revert it subsequently, as it did break the deployment (I think in quay.io)... Now I've pushed it once more and hopefully it'll work for you. Let's try solving the issue in quay.io instead.

Note that there's a container ready to use here: https://quay.io/repository/developer-portal/devel
(You don't need to build the container yourself to be able to check the changes on the site.)

Let me check if the container builds (either with the commit, or without) and get back to you.

EDIT: it works with the change I've now pushed.


As a sidenote, I have recently refreshed the DEVELOPMENT.md, as well as the Dockerfile and it is fixed (I forgot to close this issue).

Generally, there are several ways to build the site: in a container, in a VM, or on your host system- you can choose just one of those (e.g. there's no need to install jekyll, if you want to use or build container).

@Camilotk
Copy link
Contributor

Thanks it just worked for me!
The bug still persists when update with the revert commit right? Any help needed finding it?

@pvalena
Copy link
Contributor Author

pvalena commented May 31, 2021

Yes, but this breaks container builds for me, locally. The simplest solution would be to switch to another %{links} notation which does not suffer these reference issues.


Additionaly, a new has occured in Quay.io:

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    current directory: /usr/share/gems/gems/ffi-1.15.1/ext/ffi_c
/usr/bin/ruby -I /usr/share/rubygems -r ./siteconf20210531-231-tqt729.rb
extconf.rb
checking for ffi.h... no
checking for ffi.h in
/usr/local/include,/usr/include/ffi,/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/ffi,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/ffi...
no
checking for whether -Wl,--exclude-libs,ALL is accepted as LDFLAGS... yes
checking for whether -pthread is accepted as LDFLAGS... yes
creating extconf.h
creating Makefile

current directory: /usr/share/gems/gems/ffi-1.15.1/ext/ffi_c
make DESTDIR\= clean
rm -f
rm -f ffi_c.so  *.o  *.bak mkmf.log .*.time

current directory: /usr/share/gems/gems/ffi-1.15.1/ext/ffi_c
make DESTDIR\=
Configuring libffi
make: *** [libffi.mk:8:
"/usr/share/gems/gems/ffi-1.15.1/ext/ffi_c/libffi-x86_64-linux"/.libs/libffi_convenience.a]
Error 1

make failed, exit code 2

Gem files will remain installed in /usr/share/gems/gems/ffi-1.15.1 for
inspection.
Results logged to /usr/lib64/gems/ruby/ffi-1.15.1/gem_make.out

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

In Gemfile:
  jekyll-git-authors was resolved to 1.0.0, which depends on
    jekyll was resolved to 4.2.0, which depends on
      jekyll-sass-converter was resolved to 2.1.0, which depends on
        sassc was resolved to 2.4.0, which depends on
          ffi

https://quay.io/repository/developer-portal/devel/build/01418da5-442f-478a-9dac-5952ad9fc404
I think this can be mitigate with ffi gem update in Fedora (which I'm working on).

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

No branches or pull requests

3 participants