diff --git a/.github/workflows/docker-push-ghcr-use-host-ovs.yml b/.github/workflows/docker-push-ghcr-use-host-ovs.yml new file mode 100644 index 0000000..d3ce65d --- /dev/null +++ b/.github/workflows/docker-push-ghcr-use-host-ovs.yml @@ -0,0 +1,44 @@ +--- +name: docker-push-ghcr-use-host-ovs + +on: + push: + branches: [main] + workflow_run: + types: + - completed + workflows: + - 'automerge' +jobs: + docker: + runs-on: ubuntu-latest + steps: + - name: "Checkout" + uses: actions/checkout@v2 + + - name: "Set up Docker Buildx" + uses: docker/setup-buildx-action@v1 + + - name: "Login to GitHub Container Registry" + uses: docker/login-action@v1 + with: + registry: ghcr.io + username: ${{ github.repository_owner }} + password: ${{ secrets.GITHUB_TOKEN }} + + - name: Docker meta + id: metaci + uses: docker/metadata-action@v3 + with: + images: ghcr.io/${{ github.repository_owner }}/ci/${{ github.event.repository.name }}-use-host-ovs + tags: | + type=ref,event=pr + type=sha,prefix= + + - name: "Build and push for Dockerfile.use-host-ovs" + uses: docker/build-push-action@v2 + with: + file: Dockerfile.use-host-ovs + context: . + push: true + tags: ${{ steps.metaci.outputs.tags }} diff --git a/.github/workflows/docker-push-ghcr.yml b/.github/workflows/docker-push-ghcr.yml index cf01c4c..f58f792 100644 --- a/.github/workflows/docker-push-ghcr.yml +++ b/.github/workflows/docker-push-ghcr.yml @@ -42,11 +42,3 @@ jobs: context: . push: true tags: ${{ steps.metaci.outputs.tags }} - - - name: "Build and push for Dockerfile.use-host-ovs" - uses: docker/build-push-action@v2 - with: - file: Dockerfile.use-host-ovs - context: . - push: true - tags: ${{ steps.metaci.outputs.tags }} diff --git a/Dockerfile b/Dockerfile index 448d9b6..7adbc30 100644 --- a/Dockerfile +++ b/Dockerfile @@ -29,11 +29,9 @@ RUN /usr/bin/ovsdb-tool create /etc/openvswitch/conf.db RUN mkdir -pv /var/run/openvswitch/ # Add configuration files -ADD build/run_supervisord.sh /bin/run_supervisord.sh ADD build/supervisord.conf /etc/supervisord.conf ADD build/configure-ovs.sh /usr/share/openvswitch/ RUN chmod 755 /usr/share/openvswitch/configure-ovs.sh -RUN chmod +x /bin/run_supervisord.sh -# When container starts, run_supervisord.sh is executed -ENTRYPOINT ["/bin/run_supervisord.sh"] +# When container starts, run supervisord process +ENTRYPOINT ["/usr/bin/supervisord"] diff --git a/build/run_supervisord.sh b/build/run_supervisord.sh deleted file mode 100644 index 934c511..0000000 --- a/build/run_supervisord.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/sh - -modprobe openvswitch && /usr/bin/supervisord