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 Cleaning #60

Merged
merged 29 commits into from
May 23, 2024
Merged

Dockerfile Cleaning #60

merged 29 commits into from
May 23, 2024

Conversation

AlexAxthelm
Copy link
Contributor

@AlexAxthelm AlexAxthelm commented May 21, 2024

Cleaning up the Dockerfile!

The biggest structural change here is in the block that writes Rprofile.site. That now uses the builtin TARGETPLATFORM build arg (more info) to determine if we should be pulling Binaries (for Ubuntu Jammy) or building packages from source (everything else).

The other notable change is cleaning up the LABEL instructions, which in conjunction with RMI-PACTA/actions#85 provides up to date labels, including revision and version.

Smaller Changes:

  • Don't use root as user
  • hardcoding the image tag for the base image, rather than having be a build arg
  • fully qualifying the base image (docker.io/rocker/r-ver, rather than rocker/r-ver)
  • Moving the DEBIAN_FRONTEND from build args to inline envvar
  • Adding more R options to control behavior of pak and pkgload
  • copying package source code to /workflow.pacta instead of system root dir.

Closes #55
Closes #46

Copy link

github-actions bot commented May 21, 2024

Docker build status

commit_time git_sha image
2024-05-23T09:23:18Z 5514c02 ghcr.io/rmi-pacta/workflow.pacta:pr-60

@AlexAxthelm AlexAxthelm requested a review from cjyetman May 22, 2024 16:33
@AlexAxthelm AlexAxthelm marked this pull request as ready for review May 22, 2024 16:33
@AlexAxthelm AlexAxthelm marked this pull request as draft May 22, 2024 17:33
@cjyetman
Copy link
Member

FYI... the audit file is the first thing written, so I suspect something with the output paths is not right with 2022Q4 GENERAL and 2023Q4 GENERAL builds (errors in the latest CI/CD)

https://github.com/RMI-PACTA/workflow.transition.monitor/blob/033729aefe26a134d15acdd1cf3a506b917ac5de/web_tool_script_1.R#L126-L134

https://github.com/RMI-PACTA/workflow.pacta/actions/runs/9205271961/job/25320684835?pr=60#step:7:104

DEBUG [2024-05-23 09:12:00] Exporting audit information.
Error in file(file, ifelse(append, "a", "w")) :
cannot open the connection
Calls: ... -> export_audit_graph_json -> write -> cat -> file
In addition: Warning message:
In file(file, ifelse(append, "a", "w")) :
cannot open file '/home/workflow-pacta/output_dir/coveragegraphlegend.json': Permission denied
Execution halted
Error: Process completed with exit code 1.

@AlexAxthelm AlexAxthelm marked this pull request as ready for review May 23, 2024 09:50
@AlexAxthelm
Copy link
Contributor Author

@cjyetman I think cleaning up some of the bind mounts is probably the next thing on the list for this one, as part of specifying the default/inherited configs.

@AlexAxthelm AlexAxthelm requested a review from jdhoffa May 23, 2024 10:35
Dockerfile Show resolved Hide resolved
Dockerfile Show resolved Hide resolved
@AlexAxthelm AlexAxthelm merged commit c3376be into main May 23, 2024
22 checks passed
@AlexAxthelm AlexAxthelm deleted the refactor/55-restructure-dockerfile branch May 23, 2024 17:56
cjyetman pushed a commit to RMI-PACTA/workflow.cj.pacta that referenced this pull request Jul 12, 2024
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.

Restructure Dockerfile Clean up container LABELs (and annotations)
2 participants