Skip to content

Commit

Permalink
Fix hadolint issues (#6)
Browse files Browse the repository at this point in the history
* Fix hadoling issues

Signed-off-by: Arrobo, Gabriel <[email protected]>

* Update GHA accordingly

Signed-off-by: Arrobo, Gabriel <[email protected]>

---------

Signed-off-by: Arrobo, Gabriel <[email protected]>
  • Loading branch information
gab-arrobo authored Oct 25, 2024
1 parent b749b48 commit 775952f
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 12 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,11 @@ jobs:

- name: Dockerfile linter
uses: hadolint/[email protected]
# For now, ignoring:
# DL3008 warning: Pin versions in apt get install (e.g., apt-get install <package>=<version>)
with:
dockerfile: Dockerfile
ignore: DL3008

license-check:
runs-on: ubuntu-latest
Expand Down
27 changes: 15 additions & 12 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,22 @@
#
# SPDX-License-Identifier: Apache-2.0

FROM busybox:1.33.0 as static
RUN wget https://github.com/containernetworking/plugins/releases/download/v0.9.1/cni-plugins-linux-amd64-v0.9.1.tgz
RUN tar xvfz cni-plugins-linux-amd64-v0.9.1.tgz
RUN cp ./static /bin/static
RUN cp ./dhcp /bin/dhcp
RUN wget https://github.com/stedolan/jq/releases/download/jq-1.6/jq-linux64
RUN cp ./jq-linux64 /bin/jq
RUN chmod +x /bin/static /bin/jq
FROM golang:1.23.2-bookworm AS builder

FROM centos/systemd@sha256:09db0255d215ca33710cc42e1a91b9002637eeef71322ca641947e65b7d53b58 as aether-cni
RUN apt-get update && \
apt-get -y install --no-install-recommends \
wget && \
wget -q https://github.com/containernetworking/plugins/releases/download/v0.9.1/cni-plugins-linux-amd64-v0.9.1.tgz \
&& tar xvfz cni-plugins-linux-amd64-v0.9.1.tgz \
&& cp ./static /bin/static \
&& cp ./dhcp /bin/dhcp

FROM ghcr.io/jqlang/jq:1.7.1 AS jq

FROM centos/systemd@sha256:09db0255d215ca33710cc42e1a91b9002637eeef71322ca641947e65b7d53b58 AS aether-cni
WORKDIR /tmp/cni/bin
COPY vfioveth .
COPY --from=nfvpe/sriov-cni:v2.5 /usr/bin/sriov .
COPY --from=static /bin/jq .
COPY --from=static /bin/static .
COPY --from=static /bin/dhcp .
COPY --from=builder /bin/static .
COPY --from=builder /bin/dhcp .
COPY --from=jq /jq .

0 comments on commit 775952f

Please sign in to comment.