# NOT RUN {
# A simple label that occupies one line:
label1 <- Label(key1 = "this", key2 = "that", otherKey = "content")
# A multiline label with one key/value pair per line
label2 <- Label(
"info.o2r.name" = "myProject_ImageName",
"org.label-schema.name" = "ImageName",
"yet.another_labelname" = "true",
multi_line = TRUE
)
#label with fixed namespace for all keys
label3 <- Label("name"="A name", "description" = "A description", label_ns = "my.label.ns.")
the_dockerfile <- dockerfile(clean_session())
addInstruction(the_dockerfile) <- list(label1, label2, label3)
cat(format(the_dockerfile),sep = "\n")
# }
Run the code above in your browser using DataLab