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

Support docker SHELL setting for runCmds #1157

Merged
merged 5 commits into from
Apr 5, 2019
Merged

Conversation

MeiSign
Copy link
Contributor

@MeiSign MeiSign commented Jan 24, 2019

Fixes #1156

Solves issue fabric8io#1156

Signed-off-by: Stefan Meiwald <st.meiwald@gmail.com>
@codecov
Copy link

codecov bot commented Jan 24, 2019

Codecov Report

Merging #1157 into master will increase coverage by 0.09%.
The diff coverage is 90%.

@@             Coverage Diff              @@
##             master    #1157      +/-   ##
============================================
+ Coverage     52.31%   52.41%   +0.09%     
- Complexity     1473     1479       +6     
============================================
  Files           150      150              
  Lines          7854     7874      +20     
  Branches       1168     1172       +4     
============================================
+ Hits           4109     4127      +18     
  Misses         3343     3343              
- Partials        402      404       +2
Impacted Files Coverage Δ Complexity Δ
...config/handler/property/PropertyConfigHandler.java 74.44% <100%> (+0.11%) 117 <0> (+1) ⬆️
...8/maven/docker/config/BuildImageConfiguration.java 82.73% <100%> (+0.52%) 61 <1> (+1) ⬆️
...bric8/maven/docker/assembly/DockerFileKeyword.java 100% <100%> (ø) 5 <0> (ø) ⬇️
...aven/docker/config/handler/property/ConfigKey.java 100% <100%> (ø) 10 <0> (ø) ⬇️
...bric8/maven/docker/assembly/DockerFileBuilder.java 89.95% <83.33%> (-0.39%) 81 <4> (+4)

2 similar comments
@codecov
Copy link

codecov bot commented Jan 24, 2019

Codecov Report

Merging #1157 into master will increase coverage by 0.09%.
The diff coverage is 90%.

@@             Coverage Diff              @@
##             master    #1157      +/-   ##
============================================
+ Coverage     52.31%   52.41%   +0.09%     
- Complexity     1473     1479       +6     
============================================
  Files           150      150              
  Lines          7854     7874      +20     
  Branches       1168     1172       +4     
============================================
+ Hits           4109     4127      +18     
  Misses         3343     3343              
- Partials        402      404       +2
Impacted Files Coverage Δ Complexity Δ
...config/handler/property/PropertyConfigHandler.java 74.44% <100%> (+0.11%) 117 <0> (+1) ⬆️
...8/maven/docker/config/BuildImageConfiguration.java 82.73% <100%> (+0.52%) 61 <1> (+1) ⬆️
...bric8/maven/docker/assembly/DockerFileKeyword.java 100% <100%> (ø) 5 <0> (ø) ⬇️
...aven/docker/config/handler/property/ConfigKey.java 100% <100%> (ø) 10 <0> (ø) ⬇️
...bric8/maven/docker/assembly/DockerFileBuilder.java 89.95% <83.33%> (-0.39%) 81 <4> (+4)

@codecov
Copy link

codecov bot commented Jan 24, 2019

Codecov Report

Merging #1157 into master will increase coverage by 0.09%.
The diff coverage is 90%.

@@             Coverage Diff              @@
##             master    #1157      +/-   ##
============================================
+ Coverage     52.31%   52.41%   +0.09%     
- Complexity     1473     1479       +6     
============================================
  Files           150      150              
  Lines          7854     7874      +20     
  Branches       1168     1172       +4     
============================================
+ Hits           4109     4127      +18     
  Misses         3343     3343              
- Partials        402      404       +2
Impacted Files Coverage Δ Complexity Δ
...config/handler/property/PropertyConfigHandler.java 74.44% <100%> (+0.11%) 117 <0> (+1) ⬆️
...8/maven/docker/config/BuildImageConfiguration.java 82.73% <100%> (+0.52%) 61 <1> (+1) ⬆️
...bric8/maven/docker/assembly/DockerFileKeyword.java 100% <100%> (ø) 5 <0> (ø) ⬇️
...aven/docker/config/handler/property/ConfigKey.java 100% <100%> (ø) 10 <0> (ø) ⬇️
...bric8/maven/docker/assembly/DockerFileBuilder.java 89.95% <83.33%> (-0.39%) 81 <4> (+4)

@codecov
Copy link

codecov bot commented Jan 24, 2019

Codecov Report

Merging #1157 into master will increase coverage by 0.1%.
The diff coverage is 100%.

@@             Coverage Diff             @@
##             master    #1157     +/-   ##
===========================================
+ Coverage     52.31%   52.41%   +0.1%     
- Complexity     1473     1479      +6     
===========================================
  Files           150      150             
  Lines          7855     7870     +15     
  Branches       1169     1170      +1     
===========================================
+ Hits           4109     4125     +16     
  Misses         3343     3343             
+ Partials        403      402      -1
Impacted Files Coverage Δ Complexity Δ
...config/handler/property/PropertyConfigHandler.java 74.44% <100%> (+0.11%) 117 <0> (+1) ⬆️
...8/maven/docker/config/BuildImageConfiguration.java 82.63% <100%> (+0.42%) 61 <1> (+1) ⬆️
...bric8/maven/docker/assembly/DockerFileKeyword.java 100% <100%> (ø) 5 <0> (ø) ⬇️
...bric8/maven/docker/assembly/DockerFileBuilder.java 90.74% <100%> (+0.4%) 81 <4> (+4) ⬆️
...aven/docker/config/handler/property/ConfigKey.java 100% <100%> (ø) 10 <0> (ø) ⬇️
...ven/docker/access/hc/DockerAccessWithHcClient.java 14.28% <0%> (+0.04%) 13% <0%> (ø) ⬇️

@rhuss
Copy link
Collaborator

rhuss commented Jan 25, 2019

Thanks ! Looks good to me, except that I would use <shell> as top-level element and <arg> (as we use it for an entrypoint, too) as configuration elements.

Could you update these please?

@MeiSign
Copy link
Contributor Author

MeiSign commented Jan 25, 2019

@rhuss I was thinking about using the args but args give the option to be outputted in exec syntax if I understood the code correctly. The shell command in a dockerfile doesn’t allow that unfortunately: “The SHELL instruction must be written in JSON form in a Dockerfile.”

I have used args now but added a second method in the DockerFilebuilder, that always uses json syntax.

MeiSign and others added 2 commits January 25, 2019 11:30
Output always in json format.

Signed-off-by: Stefan Meiwald <st.meiwald@gmail.com>
@MeiSign
Copy link
Contributor Author

MeiSign commented Feb 12, 2019

I don't mean to rush you but any opinions on my changes?

Copy link
Member

@rohanKanojia rohanKanojia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good 👍

@tcompart
Copy link

with which release is this change included or when will it be merged into master?

Copy link
Collaborator

@rhuss rhuss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, thanks !

@rhuss
Copy link
Collaborator

rhuss commented Apr 5, 2019

@tcompart I plan to make a release over the weekend. Sorry for the delay.

@rhuss rhuss merged commit ae90000 into fabric8io:master Apr 5, 2019
@tcompart
Copy link

tcompart commented Apr 5, 2019

thank @rhuss

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

Successfully merging this pull request may close these issues.

4 participants