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

abstract out docker cmd, use sudo #7

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

hongooi73
Copy link

This PR does a couple of things:

  • Collects all the various system calls to run docker into one function docker
  • docker then checks the OS type, and uses sudo to run docker if required.

Not (yet) implemented: using processx instead of system, sudo passwords

@hongooi73
Copy link
Author

I also haven't touched the tests, they may need to be modified.

@codecov-io
Copy link

Codecov Report

Merging #7 into master will decrease coverage by 0.66%.
The diff coverage is 92.3%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master       #7      +/-   ##
==========================================
- Coverage   97.41%   96.75%   -0.67%     
==========================================
  Files           6        7       +1     
  Lines         271      277       +6     
==========================================
+ Hits          264      268       +4     
- Misses          7        9       +2
Impacted Files Coverage Δ
R/docker_run.R 95.16% <100%> (ø) ⬆️
R/dockerfile_build.R 80.95% <100%> (ø) ⬆️
R/check_docker.R 100% <100%> (ø) ⬆️
R/docker_conn.R 100% <100%> (ø) ⬆️
R/docker.R 71.42% <71.42%> (ø)

@thebioengineer
Copy link
Owner

I like this solution and it removes the need to type "docker" at the beginning of each system call. Lets continue to think on how to resolve the sudo issue, look into processx, and adding tests.

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.

3 participants