FROM fedora:33 
ARG TARGETPLATFORM

WORKDIR /var/submariner

RUN dnf -y install --nodocs --setopt=install_weak_deps=0 \
           https://kojipkgs.fedoraproject.org//packages/ovn/20.06.2/4.fc33/x86_64/ovn-20.06.2-4.fc33.x86_64.rpm && \
    dnf -y clean all

# install the networkpluginc-sync
COPY package/submariner-networkplugin-syncer.sh bin/${TARGETPLATFORM}/submariner-networkplugin-syncer /usr/local/bin/

ENTRYPOINT ["/usr/local/bin/submariner-networkplugin-syncer.sh"]

USER ${USER_UID}
