Skip to content
This repository has been archived by the owner on Jul 8, 2020. It is now read-only.

Submit lighthouse_ci to Docker hub? #4

Open
kmturley opened this issue Jun 29, 2017 · 10 comments
Open

Submit lighthouse_ci to Docker hub? #4

kmturley opened this issue Jun 29, 2017 · 10 comments

Comments

@kmturley
Copy link

Great work, this tool will be extremely useful for CI builds!

I see you already have Docker source code here:
https://github.com/ebidel/lighthouse-ci/tree/master/builder

Can you submit an official Docker built image to Docker hub? There are a couple of benefits to this approach:

  1. This will save everyone the step of downloading and building themselves, and provide an official release which is testable.

  2. When using with CI tools, not only does it saves build times, but can be spun up as a service with one line of code, like this selenium example for gitlab and bitbucket pipelines:

.gitlab-ci.yml

test_functional:
  image: python
  stage: test
  services:
    - selenium/standalone-chrome
  script:
    - SELENIUM="http://selenium__standalone-chrome:4444/wd/hub" BASE_URL="https://$CI_BUILD_REF_SLUG-dot-$GAE_PROJECT.appspot.com" DRIVER="headless_chrome" python -m unittest discover -s qa

bitbucket-pipelines.yml

pipelines:
  default:
    - step:
        services:
          - selenium
        script:
          - SELENIUM="http://127.0.0.1:4444/wd/hub" BASE_URL="http://$BITBUCKET_BRANCH.$AWS_PROJECT.us-east-1.elasticbeanstalk.com" DRIVER="headless_chrome" python -m unittest discover -s qa

definitions:
  services:
    selenium:
      image: selenium/standalone-chrome
@ebidel
Copy link
Contributor

ebidel commented Jun 29, 2017

Docker noob here :) Do people not pre-build images and reference/use them from CI env? Or is it come to pull from the registry and build every time?

@kmturley
Copy link
Author

You can do it either way. But if you pre-build yourself you either need to commit the entire source-code somewhere in your file/folder structure, or need to push the built image to hosting somewhere.

By building an official image, you can save everyone the trouble and makes everything alot easier!

I haven't completed the full steps myself, but I believe you connect Docker Hub to your github, and it builds and hosts the images automatically:
https://docs.docker.com/docker-hub/builds/

@ebidel
Copy link
Contributor

ebidel commented Jun 29, 2017 via email

@kmturley
Copy link
Author

kmturley commented Aug 1, 2017

I went ahead and created an example build:
https://hub.docker.com/r/kmturley/lighthouse-ci/

My Docker image uses a fork of your repo, and doesn't update when you push new updates, so would recommend you setting this up! It was pretty easy (about 15 minutes)

@ebidel
Copy link
Contributor

ebidel commented Aug 1, 2017 via email

@igrigorik
Copy link

My Docker image uses a fork of your repo, and doesn't update when you push new updates, so would recommend you setting this up! It was pretty easy (about 15 minutes)

Would love to see this. Please! :-)

@pavelloz
Copy link

I'm also interested in that feature to avoid unnecessary building steps on CI.

@moberemk
Copy link

Could this be done? This issue has been open for quite a while, and now it might even be doable via Github Actions

@staabm
Copy link

staabm commented Aug 23, 2019

using this bot via github actions would have the benefit that we would not need to add the lighthouse bot as a external collaborator, I guess.
(external collaborators cost a seat as far as licensing on github side is a concern)

@bizmate
Copy link

bizmate commented Mar 31, 2020

An update on this would be nice. Building a local image is an extra effort that would be nice to avoid

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

No branches or pull requests

7 participants