-
Notifications
You must be signed in to change notification settings - Fork 807
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
Issue with building within a container #771
Comments
@darewreck54 I think this is due to this PR that recently merged: #748. I think the containers/images package on your machine needs to be updated, it went from v4 to v5, but I'm not sure how that would happen in ubuntu. @lsm5 @rhatdan @vrothberg any ideas on how to make that happen? FWIW, I dropped the static build part of your Dockerfile (see below) and that worked for me.
|
When you say static part do you mean the build tags? In our use case, we want the build tags ... I’m guessing that is what causes the need for the v5 dependency
…Sent from my iPhone
On Nov 26, 2019, at 3:10 PM, Tom Sweeney <notifications@github.com> wrote:
@darewreck54<https://github.com/darewreck54> I think this is due to this PR that recently merged: #748<#748>. I think the containers/images package on your machine needs to be updated, it went from v4 to v5, but I'm not sure how that would happen in ubuntu.
@lsm5<https://github.com/lsm5> @rhatdan<https://github.com/rhatdan> @vrothberg<https://github.com/vrothberg> any ideas on how to make that happen?
FWIW, I dropped the static build part of your Dockerfile (see below) and that worked for me.
FROM golang
# Install Skopeo
RUN apt-get update && apt-get install -y \
git libgpgme-dev libassuan-dev libbtrfs-dev libdevmapper-dev \
&& apt-get clean
RUN git clone https://github.com/containers/skopeo $GOPATH/src/github.com/containers/skopeo \
&& cd $GOPATH/src/github.com/containers/skopeo && make binary-local \
&& cp $GOPATH/src/github.com/containers/skopeo/skopeo /usr/bin/skopeo
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#771?email_source=notifications&email_token=AD3MFTT4KPQ2U5BLRB46LZ3QVWUEZA5CNFSM4JR6BI22YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEFHXT3I#issuecomment-558856685>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AD3MFTUNDXC7YFZFSFCJ5QTQVWUEZANCNFSM4JR6BI2Q>.
|
Thanks for opening the issue, @darewreck54. We actually want to drop the static builds (see #755) but didn't do the cleanup work yet. Please use |
@vrothberg what’s the implication with dropping the static builds? https://github.com/containers/image Does this mean that i have to install
as a replacement for the build tags? I'm guessing covers it except for |
I'm going to reopen this issue given the discussion. |
The binary will be dynamically linked and will won't suffer from the restrictions of static binary (see #670 for background).
You're already installing |
when you say manually set build stags, do you refer to
This will result in the same error
How would the build tags be needed if the make file will dynamically handle it for you? |
Some are not dynamically set (e.g., containers_image_openpgp).
Curious, this error only occurs when "containers_image_ostree_stub" is specified twice in the build tags. It should work when removing the redundant tag from the Dockerfile. I can't tell you why go behaves this way; never seen it before. Does that fix your issue? |
@vrothberg How is "containers_image_ostree_stub" specified twice in the build tags? BUILDTAGS='containers_image_openpgp containers_image_ostree_stub containers_image_storage_stub' I'm seeing three different build tags? It's also strange because this worked before unless it suddenly became non dynamic? Also if I don't include those build tags, would the functionality be the same if it's already installed into the system? |
@darewreck54, thanks for double checking. You're absolutely correct! The build fails because |
Remove a direct reference on c/image/v5/storage which breaks the build when using the `containers_image_storage_stub`. The reference is only used to get the storage tranport string, which is now hard-coded; this is fine as the transport will not change for backwards compat. Fixes: containers#771 Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
Remove a direct reference on c/image/v5/storage which breaks the build when using the `containers_image_storage_stub`. The reference is only used to get the storage tranport string, which is now hard-coded; this is fine as the transport will not change for backwards compat. Fixes: containers#771 Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
Remove a direct reference on c/image/v5/storage which breaks the build when using the `containers_image_storage_stub`. The reference is only used to get the storage tranport string, which is now hard-coded; this is fine as the transport will not change for backwards compat. Fixes: containers#771 Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
Remove a direct reference on c/image/v5/storage which breaks the build when using the `containers_image_storage_stub`. The reference is only used to get the storage tranport string, which is now hard-coded; this is fine as the transport will not change for backwards compat. Fixes: #771 Signed-off-by: Valentin Rothberg <rothberg@redhat.com>
I'm trying to build the skopeo within a container with the following docker file.
Dockerfile
This use to work a couple months ago, but it doesn't work anymore. Did something change?
Error:
looks like it's complaining
Strange thou tat I don't have any issue building this locally on a mac, but issue with building it within the container.
Thanks
The text was updated successfully, but these errors were encountered: