Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 13 additions & 9 deletions client/client_state.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -268,13 +268,13 @@ void CLIENT_STATE::show_host_info() {
);
}
if (!wsl.docker_version.empty()) {
msg_printf(NULL, MSG_INFO, "- Docker version %s (%s)",
msg_printf(NULL, MSG_INFO, "- Podman version %s (%s)",
wsl.docker_version.c_str(),
docker_type_str(wsl.docker_type)
);
}
if (!wsl.docker_compose_version.empty()) {
msg_printf(NULL, MSG_INFO, "- Docker compose version %s (%s)",
msg_printf(NULL, MSG_INFO, "- Podman compose version %s (%s)",
wsl.docker_compose_version.c_str(),
docker_type_str(wsl.docker_compose_type)
);
Expand Down Expand Up @@ -327,13 +327,13 @@ void CLIENT_STATE::show_host_info() {

#ifndef _WIN64
if (strlen(host_info.docker_version)) {
msg_printf(NULL, MSG_INFO, "Docker: version %s (%s)",
msg_printf(NULL, MSG_INFO, "Podman: version %s (%s)",
Comment thread
cubic-dev-ai[bot] marked this conversation as resolved.
Outdated
host_info.docker_version,
docker_type_str(host_info.docker_type)
);
}
if (strlen(host_info.docker_compose_version)) {
msg_printf(NULL, MSG_INFO, "Docker compose: version %s (%s)",
msg_printf(NULL, MSG_INFO, "Podman compose: version %s (%s)",
host_info.docker_compose_version,
docker_type_str(host_info.docker_compose_type)
);
Expand Down Expand Up @@ -2510,14 +2510,18 @@ void show_docker_messages() {
return;
}

const char* url = "https://github.com/BOINC/boinc/wiki/Installing-Docker-on-Windows";
const char* url = "https://github.com/BOINC/boinc/wiki/Installing-Podman-on-Windows";
#elif defined(__APPLE__)
const char* url = "https://github.com/BOINC/boinc/wiki/Installing-Docker-on-Mac";
const char* url = "https://github.com/BOINC/boinc/wiki/Installing-Podman-on-Mac";
#else
const char* url = "https://github.com/BOINC/boinc/wiki/Installing-Docker-on-Linux";
const char* url = "https://github.com/BOINC/boinc/wiki/Installing-Podman-on-Linux";
#endif
if (gstate.host_info.have_docker()) {
if (!gstate.host_info.have_docker()) {
msg_printf_notice(0, true, url,
"Some projects require Podman; we recommend that you install it."
);
#ifdef _WIN32
} else {
int bdv = gstate.host_info.wsl_distros.boinc_distro_version();
if (bdv) {
if (bdv < gstate.latest_boinc_buda_runner_version) {
Expand All @@ -2528,7 +2532,7 @@ void show_docker_messages() {
}
} else {
msg_printf_notice(0, true, url,
"Docker is present but not using the BOINC WSL distro. Some project apps may not function properly. We recommend that you install the BOINC WSL distro."
"Podman is present but not using the BOINC WSL distro. Some project apps may not function properly. We recommend that you install the BOINC WSL distro."
);
}
#endif
Expand Down
2 changes: 1 addition & 1 deletion client/client_types.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -899,7 +899,7 @@ bool APP_VERSION::disallowed_by_config(PROJECT *p) {
}
if (cc_config.dont_use_docker && strstr(plan_class, "docker")) {
msg_printf(p, MSG_INFO,
"skipping Docker app: disabled in cc_config.xml"
"skipping Podman app: disabled in cc_config.xml"
);
return true;
}
Expand Down
4 changes: 2 additions & 2 deletions client/cpu_sched.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -173,10 +173,10 @@ struct PROC_RESOURCES {
static bool first = true;
if (first) {
msg_printf(NULL, MSG_USER_ALERT,
"Docker jobs are present but Podman/Docker not found; please install it."
"Podman jobs are present but Podman not found; please install it."
);
msg_printf(NULL, MSG_USER_ALERT,
"See https://github.com/BOINC/boinc/wiki/Installing-Docker"
"See https://github.com/BOINC/boinc/wiki/Installing-Podman"
);
first = false;
}
Expand Down
18 changes: 9 additions & 9 deletions client/cs_apps.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@ struct DOCKER_JOB_INFO {
}
};

// clean up a Docker installation
// clean up a Podman installation
// (Unix: the host; Win: a WSL distro)
//
void cleanup_docker(DOCKER_JOB_INFO &info, DOCKER_CONN &dc) {
Expand All @@ -409,7 +409,7 @@ void cleanup_docker(DOCKER_JOB_INFO &info, DOCKER_CONN &dc) {
//
retval = dc.command("ps --all", out, false);
if (retval) {
fprintf(stderr, "Docker command failed: ps --all\n");
fprintf(stderr, "Podman command failed: ps --all\n");
Comment thread
cubic-dev-ai[bot] marked this conversation as resolved.
Outdated
} else {
for (string line: out) {
retval = dc.parse_container_name(line, name);
Expand All @@ -419,11 +419,11 @@ void cleanup_docker(DOCKER_JOB_INFO &info, DOCKER_CONN &dc) {
sprintf(cmd, "rm -f %s", name.c_str());
retval = dc.command(cmd, out2, true);
if (retval) {
fprintf(stderr, "Docker command failed: %s\n", cmd);
fprintf(stderr, "Podman command failed: %s\n", cmd);
continue;
}
msg_printf(NULL, MSG_INFO,
"Removed unused Docker container: %s", name.c_str()
"Removed unused Podman container: %s", name.c_str()
);
}
}
Expand All @@ -432,7 +432,7 @@ void cleanup_docker(DOCKER_JOB_INFO &info, DOCKER_CONN &dc) {
//
retval = dc.command("images", out, false);
if (retval) {
fprintf(stderr, "Docker command failed: images\n");
fprintf(stderr, "Podman command failed: images\n");
} else {
for (string line: out) {
retval = dc.parse_image_name(line, name);
Expand All @@ -442,17 +442,17 @@ void cleanup_docker(DOCKER_JOB_INFO &info, DOCKER_CONN &dc) {
sprintf(cmd, "image rm %s", name.c_str());
retval = dc.command(cmd, out2, true);
if (retval) {
fprintf(stderr, "Docker command failed: %s\n", cmd);
fprintf(stderr, "Podman command failed: %s\n", cmd);
continue;
}
msg_printf(NULL, MSG_INFO,
"Removed unused Docker image: %s", name.c_str()
"Removed unused Podman image: %s", name.c_str()
);
}
}
}

// remove old BOINC images and containers from Docker installations
// remove old BOINC images and containers from Podman installations
//
void CLIENT_STATE::docker_cleanup() {
// make lists of the images and containers used by active jobs
Expand All @@ -468,7 +468,7 @@ void CLIENT_STATE::docker_cleanup() {
info.containers.push_back(s);
}

// go through local Docker installations and remove
// go through local Podman installations and remove
// BOINC images and containers not in the above lists
//
#ifdef _WIN32
Expand Down
2 changes: 1 addition & 1 deletion client/cs_scheduler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ int CLIENT_STATE::make_scheduler_request(PROJECT* p) {
set_n_usable_cpus();

#ifdef __APPLE__
// if Podman hasn't inited yet, don't include Docker info in sched req
// if Podman hasn't inited yet, don't include Podman info in sched req
char tmp[256];
safe_strcpy(tmp, host_info.docker_version);
if (host_info.docker_type == PODMAN && !host_info.podman_inited) {
Expand Down
2 changes: 1 addition & 1 deletion client/hostinfo_unix.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1309,7 +1309,7 @@ bool HOST_INFO::get_docker_version_aux(DOCKER_TYPE type){
#endif // __APPLE__

#ifdef __linux__
// if we're running as an unprivileged user, Docker/podman may not work.
// if we're running as an unprivileged user, Docker/Podman may not work.
// Check by running the Hello World image.
//
// Since we do this every time on startup: delete the created container
Expand Down
10 changes: 5 additions & 5 deletions client/hostinfo_wsl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ static bool got_both(WSL_DISTRO &wd) {
// Get list of WSL distros usable by BOINC
// For each of them:
// try to find the OS name and version
// see if Docker and docker compose are present, get versions
// see if Docker/Podman and compose are present, get versions
// Return nonzero on error
//
int get_wsl_information(WSL_DISTROS &distros) {
Expand Down Expand Up @@ -380,7 +380,7 @@ int get_wsl_information(WSL_DISTROS &distros) {
wd.libc_version = parse_ldd_libc(buf.c_str());
}

// see if Docker is installed in the distro
// see if Podman/Docker is installed in the distro
//
get_docker_version(rs, wd);
get_docker_compose_version(rs, wd);
Expand Down Expand Up @@ -467,19 +467,19 @@ static bool get_docker_version_aux(
ret = true;
if (version.empty()) {
msg_printf(0, MSG_INFO,
"Docker version parse failed: %s", reply.c_str()
"Podman version parse failed: %s", reply.c_str()
Comment thread
cubic-dev-ai[bot] marked this conversation as resolved.
Outdated
);
}
} else {
msg_printf(0, MSG_INFO, "Docker detection in %s:",
msg_printf(0, MSG_INFO, "Podman detection in %s:",
wd.distro_name.c_str()
);
msg_printf(0, MSG_INFO, "- cmd: %s", cmd.c_str());
msg_printf(0, MSG_INFO, "- output: %s", reply.c_str());
}
CloseHandle(rs.proc_handle);
} else {
msg_printf(0, MSG_INFO, "Docker detection in %s:",
msg_printf(0, MSG_INFO, "Podman detection in %s:",
wd.distro_name.c_str()
);
msg_printf(0, MSG_INFO, "- cmd failed: %s", cmd.c_str());
Expand Down
3 changes: 2 additions & 1 deletion client/log_flags.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ void CC_CONFIG::show() {
msg_printf(NULL, MSG_INFO, "Config: don't use VirtualBox");
}
if (dont_use_docker) {
msg_printf(NULL, MSG_INFO, "Config: don't use Docker");
msg_printf(NULL, MSG_INFO, "Config: don't use Podman/Docker");
}
if (dont_use_wsl) {
msg_printf(NULL, MSG_INFO, "Config: don't use Windows Subsystem for Linux");
Expand Down Expand Up @@ -386,6 +386,7 @@ int CC_CONFIG::parse_options_client(XML_PARSER& xp) {
continue;
}
if (xp.parse_bool("dont_use_docker", dont_use_docker)) continue;
if (xp.parse_bool("dont_use_podman", dont_use_docker)) continue;
if (xp.match_tag("exclude_gpu")) {
EXCLUDE_GPU eg;
retval = eg.parse(xp);
Expand Down
Loading