Skip to content

Commit 9c833d7

Browse files
committed
Initial implementation of incremental build in self-contained ruby builder image
1 parent 188c855 commit 9c833d7

File tree

3 files changed

+13
-0
lines changed

3 files changed

+13
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/bash
2+
3+
tar -C / -xf -
+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/bash
2+
3+
tar -cf - /opt/ruby/bundle

centos-ruby-builder/bin/start

+7
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,13 @@ source ${HOME}/etc/helpers
1111
# If the /tmp/src is empty, then print usage and exit.
1212
(dir_is_empty /tmp/src) && print_usage_and_exit
1313

14+
# Detect presence of $stdin and restore the artifacts
15+
#
16+
if [ -p /dev/stdin ]; then
17+
echo "---> Restoring artifacts from STDIN"
18+
cat | /opt/ruby/bin/restore-artifacts
19+
fi
20+
1421
# Build the ruby application first
1522
#
1623
${HOME}/bin/prepare

0 commit comments

Comments
 (0)