2019-09-11 09:45:53 +00:00
|
|
|
FROM docker.io/library/fedora:latest
|
*: big rewrite
_(this is a WIP)_
for the requirements to not be so bound to RPM only, breaking collection
of sources out into "plugins". Currently not much more sophisticated
than just iterating through bash functions that expect 3 argugments.
rootfs of the inspectee; output path for the sources collected; manifest
path.
The idea for the manifest is still loose, but how best to follow up the
plugin which collected source, to then have the rich metadata available
to attach to the individual "layers" that are produced for each source
component.
for the requirement of most contrained non-root container running this
script as non-root, we'll switch away from buildah for now. This ought
to just be skopeo copy, unpacking, inspecting, json, and skopeo copy. No
mounting, no namespacing, etc.
for the sake of writing unit tests (i.e. `bats`), break the script into
a way that it can be sourced and run the functions individually. Only
act like the whole script when run directly.
If `umoci` is available it will get used for some functions (like
unpacking), but it is not required and will be attempted with jq and
bash otherwise.
Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
2019-08-19 21:35:25 +00:00
|
|
|
|
2019-09-06 21:05:52 +00:00
|
|
|
RUN dnf install -y jq skopeo findutils file 'dnf-command(download)'
|
*: big rewrite
_(this is a WIP)_
for the requirements to not be so bound to RPM only, breaking collection
of sources out into "plugins". Currently not much more sophisticated
than just iterating through bash functions that expect 3 argugments.
rootfs of the inspectee; output path for the sources collected; manifest
path.
The idea for the manifest is still loose, but how best to follow up the
plugin which collected source, to then have the rich metadata available
to attach to the individual "layers" that are produced for each source
component.
for the requirement of most contrained non-root container running this
script as non-root, we'll switch away from buildah for now. This ought
to just be skopeo copy, unpacking, inspecting, json, and skopeo copy. No
mounting, no namespacing, etc.
for the sake of writing unit tests (i.e. `bats`), break the script into
a way that it can be sourced and run the functions individually. Only
act like the whole script when run directly.
If `umoci` is available it will get used for some functions (like
unpacking), but it is not required and will be attempted with jq and
bash otherwise.
Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
2019-08-19 21:35:25 +00:00
|
|
|
|
2019-09-09 18:32:13 +00:00
|
|
|
COPY ./BuildSourceImage.sh /usr/local/bin/BuildSourceImage.sh
|
*: big rewrite
_(this is a WIP)_
for the requirements to not be so bound to RPM only, breaking collection
of sources out into "plugins". Currently not much more sophisticated
than just iterating through bash functions that expect 3 argugments.
rootfs of the inspectee; output path for the sources collected; manifest
path.
The idea for the manifest is still loose, but how best to follow up the
plugin which collected source, to then have the rich metadata available
to attach to the individual "layers" that are produced for each source
component.
for the requirement of most contrained non-root container running this
script as non-root, we'll switch away from buildah for now. This ought
to just be skopeo copy, unpacking, inspecting, json, and skopeo copy. No
mounting, no namespacing, etc.
for the sake of writing unit tests (i.e. `bats`), break the script into
a way that it can be sourced and run the functions individually. Only
act like the whole script when run directly.
If `umoci` is available it will get used for some functions (like
unpacking), but it is not required and will be attempted with jq and
bash otherwise.
Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
2019-08-19 21:35:25 +00:00
|
|
|
|
|
|
|
RUN mkdir -p /output
|
2019-08-14 15:15:46 +00:00
|
|
|
ENV OUTPUT_DIR=/output
|
*: big rewrite
_(this is a WIP)_
for the requirements to not be so bound to RPM only, breaking collection
of sources out into "plugins". Currently not much more sophisticated
than just iterating through bash functions that expect 3 argugments.
rootfs of the inspectee; output path for the sources collected; manifest
path.
The idea for the manifest is still loose, but how best to follow up the
plugin which collected source, to then have the rich metadata available
to attach to the individual "layers" that are produced for each source
component.
for the requirement of most contrained non-root container running this
script as non-root, we'll switch away from buildah for now. This ought
to just be skopeo copy, unpacking, inspecting, json, and skopeo copy. No
mounting, no namespacing, etc.
for the sake of writing unit tests (i.e. `bats`), break the script into
a way that it can be sourced and run the functions individually. Only
act like the whole script when run directly.
If `umoci` is available it will get used for some functions (like
unpacking), but it is not required and will be attempted with jq and
bash otherwise.
Signed-off-by: Vincent Batts <vbatts@hashbangbash.com>
2019-08-19 21:35:25 +00:00
|
|
|
VOLUME /output
|
|
|
|
|
2019-09-06 12:38:31 +00:00
|
|
|
ENTRYPOINT ["/usr/local/bin/BuildSourceImage.sh"]
|