diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 80e75fe..69bd787 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -7,7 +7,7 @@ on: jobs: lint: name: Lint Docker Files - runs-on: ubuntu-20.04 + runs-on: self-hosted strategy: fail-fast: false matrix: diff --git a/.github/workflows/mariadb.yml b/.github/workflows/mariadb.yml index 3028a0f..314bc93 100644 --- a/.github/workflows/mariadb.yml +++ b/.github/workflows/mariadb.yml @@ -7,14 +7,14 @@ on: workflow_run: workflows: - Lint Docker Files - branches: [master] + branches: [ 'master', 'feature/**' ] types: - completed jobs: mariadb-build: name: "MariaDB with Healthchecks" - runs-on: ubuntu-20.04 + runs-on: self-hosted needs: [ lint ] steps: - uses: actions/checkout@v1 diff --git a/.github/workflows/marshall.yml b/.github/workflows/marshall.yml index a5cec4a..5476468 100644 --- a/.github/workflows/marshall.yml +++ b/.github/workflows/marshall.yml @@ -7,7 +7,7 @@ on: workflow_run: workflows: - Lint Docker Files - branches: [master] + branches: [ 'master', 'feature/**' ] types: - completed @@ -15,7 +15,7 @@ jobs: build: name: "Build Marshall" - runs-on: ubuntu-20.04 + runs-on: self-hosted steps: - uses: actions/checkout@v1 - uses: docker/setup-qemu-action@v1 diff --git a/.github/workflows/octoprint.yml b/.github/workflows/octoprint.yml index 3a24367..c5ec99c 100644 --- a/.github/workflows/octoprint.yml +++ b/.github/workflows/octoprint.yml @@ -7,14 +7,14 @@ on: workflow_run: workflows: - Lint Docker Files - branches: [master] + branches: [ 'master', 'feature/**' ] types: - completed jobs: octoprint-build: name: "Bake Octoprint" - runs-on: ubuntu-20.04 + runs-on: self-hosted steps: - uses: actions/checkout@v1 - uses: docker/setup-qemu-action@v1 @@ -35,7 +35,7 @@ jobs: tags: matthewbaggett/octoprint:latest octoprint-mjpg-build: name: "Bake Octoprint for yuvu cameras" - runs-on: ubuntu-20.04 + runs-on: self-hosted steps: - uses: actions/checkout@v1 - uses: docker/setup-qemu-action@v1 diff --git a/.github/workflows/php-core.yml b/.github/workflows/php-core.yml index a20733e..d623047 100644 --- a/.github/workflows/php-core.yml +++ b/.github/workflows/php-core.yml @@ -8,7 +8,7 @@ on: workflow_run: workflows: - Build Marshall - branches: [master] + branches: [ 'master', 'feature/**' ] types: - completed @@ -16,7 +16,7 @@ jobs: php-build-core: name: "Build PHP Core" - runs-on: ubuntu-20.04 + runs-on: self-hosted strategy: fail-fast: false matrix: @@ -59,13 +59,6 @@ jobs: with: username: ${{ secrets.DOCKER_HUB_USERNAME }} password: ${{ secrets.DOCKER_HUB_PASSWORD }} - - name: Cache Docker layers - uses: actions/cache@v2 - with: - path: /tmp/.buildx-cache - key: ${{ runner.os }}-buildx-${{ github.sha }} - restore-keys: | - ${{ runner.os }}-buildx- - uses: docker/build-push-action@v2 name: Build & Push with: @@ -79,5 +72,4 @@ jobs: benzine/php:core-${{ matrix.version }} build-args: | ${{ steps.build_args.outputs.result }} - cache-from: type=local,src=/tmp/.buildx-cache - cache-to: type=local,dest=/tmp/.buildx-cache + diff --git a/.github/workflows/php-flavours.yml b/.github/workflows/php-flavours.yml index 9929af5..9972a22 100644 --- a/.github/workflows/php-flavours.yml +++ b/.github/workflows/php-flavours.yml @@ -10,14 +10,14 @@ on: workflow_run: workflows: - Build PHP Core - branches: [master] + branches: [ 'master', 'feature/**' ] types: - completed jobs: php-build-flavours: name: "Build PHP Flavours" - runs-on: ubuntu-20.04 + runs-on: self-hosted strategy: fail-fast: false matrix: @@ -57,13 +57,6 @@ jobs: with: username: ${{ secrets.DOCKER_HUB_USERNAME }} password: ${{ secrets.DOCKER_HUB_PASSWORD }} - - name: Cache Docker layers - uses: actions/cache@v2 - with: - path: /tmp/.buildx-cache - key: ${{ runner.os }}-buildx-${{ github.sha }} - restore-keys: | - ${{ runner.os }}-buildx- - uses: docker/build-push-action@v2 name: Build & Push with: @@ -77,5 +70,3 @@ jobs: benzine/php:${{ matrix.variant }}-${{ matrix.version }} build-args: | ${{ steps.build_args.outputs.result }} - cache-from: type=local,src=/tmp/.buildx-cache - cache-to: type=local,dest=/tmp/.buildx-cache diff --git a/.github/workflows/php-vanity-tags.yml b/.github/workflows/php-vanity-tags.yml index 2cf97fb..7c4cc0b 100644 --- a/.github/workflows/php-vanity-tags.yml +++ b/.github/workflows/php-vanity-tags.yml @@ -4,14 +4,14 @@ on: workflow_run: workflows: - Build PHP Flavours - branches: [master] + branches: [ 'master', 'feature/**' ] types: - completed jobs: php-vanity-tags: name: Vanity Tags - runs-on: ubuntu-20.04 + runs-on: self-hosted env: latest-stable-version: "7.4" strategy: diff --git a/.github/workflows/redis.yml b/.github/workflows/redis.yml index 27eeba1..7adb26e 100644 --- a/.github/workflows/redis.yml +++ b/.github/workflows/redis.yml @@ -7,14 +7,14 @@ on: workflow_run: workflows: - Lint Docker Files - branches: [master] + branches: [ 'master', 'feature/**' ] types: - completed jobs: redis-build: name: "Redis with Healthchecks" - runs-on: ubuntu-20.04 + runs-on: self-hosted steps: - uses: actions/checkout@v1 - uses: docker/setup-qemu-action@v1 diff --git a/.github/workflows/wordpress.yml b/.github/workflows/wordpress.yml index 776ea65..caed79c 100644 --- a/.github/workflows/wordpress.yml +++ b/.github/workflows/wordpress.yml @@ -7,14 +7,14 @@ on: workflow_run: workflows: - Build PHP Vanity Tags - branches: [master] + branches: [ 'master', 'feature/**' ] types: - completed jobs: wordpress-build: name: "Bake Wordpress Container" - runs-on: ubuntu-20.04 + runs-on: self-hosted steps: - uses: actions/checkout@v1 - uses: docker/setup-qemu-action@v1 diff --git a/php/Dockerfile.Flavours b/php/Dockerfile.Flavours index 2e0f1ae..aec30bd 100644 --- a/php/Dockerfile.Flavours +++ b/php/Dockerfile.Flavours @@ -10,7 +10,7 @@ RUN composer global require -q psy/psysh:@stable && \ /usr/local/bin/repl -v && \ composer clear-cache -COPY php+cli/psysh-config.php /root/.config/psysh/config.php +COPY cli/psysh-config.php /root/.config/psysh/config.php ARG PHP_CORE_VERSION FROM ${PHP_CORE_VERSION} AS php-nginx @@ -20,7 +20,8 @@ ARG PHP_VERSION ARG PHP_MEMORY_LIMIT=128M ARG PHP_DATA_MAX_SIZE=1024M ENV PHPFPM_MAX_CHILDREN=25 -COPY php+nginx /conf +COPY nginx /conf +COPY self-signed-certificates /certs RUN apt-get -qq update && \ # Install pre-dependencies to use apt-key. @@ -76,12 +77,12 @@ RUN apt-get -qq update && \ mv /conf/NginxDefault /etc/nginx/sites-enabled/default && \ mv /conf/NginxSSL /etc/nginx/sites-enabled/default-ssl && \ # Generate self-signed certificates - mkdir /certs && \ - openssl req -x509 -nodes -days 36500 -newkey rsa:2048 \ - -subj "/C=US/ST=Florida/L=Miami/O=Example Group/CN=example.org" \ - -keyout /certs/example.key \ - -out /certs/example.crt \ - && \ + #mkdir /certs && \ + #openssl req -x509 -nodes -days 36500 -newkey rsa:2048 \ + # -subj "/C=US/ST=Florida/L=Miami/O=Example Group/CN=example.org" \ + # -keyout /certs/example.key \ + # -out /certs/example.crt \ + #&& \ # Create runit service directories mkdir -p /etc/service/nginx \ /etc/service/php-fpm \ @@ -154,7 +155,7 @@ EXPOSE 80 HEALTHCHECK --interval=30s --timeout=3s \ CMD curl -f http://localhost/ || exit 1 -COPY php+apache /conf +COPY apache /conf RUN rm -fr /var/www/html && \ ln -s /app /var/www/html && \ mv /conf/ApacheConfig.conf /etc/apache2/sites-enabled/000-default.conf && \ diff --git a/php/self-signed-certificates/example.crt b/php/self-signed-certificates/example.crt new file mode 100644 index 0000000..58e206b --- /dev/null +++ b/php/self-signed-certificates/example.crt @@ -0,0 +1,22 @@ +-----BEGIN CERTIFICATE----- +MIIDnTCCAoWgAwIBAgIUJYUUmBQ2/ERZ7xinAJzVhiFWViYwDQYJKoZIhvcNAQEL +BQAwXTELMAkGA1UEBhMCVVMxEDAOBgNVBAgMB0Zsb3JpZGExDjAMBgNVBAcMBU1p +YW1pMRYwFAYDVQQKDA1FeGFtcGxlIEdyb3VwMRQwEgYDVQQDDAtleGFtcGxlLm9y +ZzAgFw0yMTA1MzAxNzU4MzlaGA8yMTIxMDUwNjE3NTgzOVowXTELMAkGA1UEBhMC +VVMxEDAOBgNVBAgMB0Zsb3JpZGExDjAMBgNVBAcMBU1pYW1pMRYwFAYDVQQKDA1F +eGFtcGxlIEdyb3VwMRQwEgYDVQQDDAtleGFtcGxlLm9yZzCCASIwDQYJKoZIhvcN +AQEBBQADggEPADCCAQoCggEBANJa9OcoCW+mej8qDMCCTGnqMAuUqBIj1wZLgOdT +4DHriq1vKi1JLsDZkYekrCq/sfWo97kDXsdK6YN4+mua5EN4cTG3mSpal+RgLTc2 +HMKHFfgzPzIN/n5AEqzdVZb5j0P3LoUNH687AlplW0BB+K64Gw//2KPx0Q8Fkhq2 +I97V8SRpqds78PJHzhfuZNs/AUFpFXnYHJyO2Q63Btq2aoTMQyoLDRBBxin70II2 +6Cjh3k6EhMY+HuYS1AjfI8cDQw289asJBLa6zPoD0VGaGNfCSrOzxrUqfhIoOkuY +W7rOIsK6rSSu1neSKQIiOLVjQxifxrQIIKTQhRiSplgD9LUCAwEAAaNTMFEwHQYD +VR0OBBYEFADK74w4AGeETK72k/htsnol9ye0MB8GA1UdIwQYMBaAFADK74w4AGeE +TK72k/htsnol9ye0MA8GA1UdEwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQADggEB +AKElv0xx95lD2leXEOfD6DKakrzuE8lONmcrkfjehTOd7jbqblnj8u1DCWytwB8P +gEr5FXve0iy7avGoNkU33MufbbQokAMoTs/IA+rwMfv0unupT1aYN8TTEXJJ100j +MXBsq/PvNkBNwkBcXjYHHsVjdM3bptbaw9A4V9opfMjQXAY5wuk3rBBm8On2rJKy +Qksh/uLoe8wbZ5dvLv9oc9sRpIilaSy8TcbrHkDIaWA5WCdVFfcayDGYdjhCYLGW +tj/48g0THvJv6JvVYwFJqTM690YUSlxaOHQE2ZneLytocVyAdEL2MMldRezvtI1z +1OXOia2G7koNYtS7cD8G1IM= +-----END CERTIFICATE----- diff --git a/php/self-signed-certificates/example.key b/php/self-signed-certificates/example.key new file mode 100644 index 0000000..3c63e83 --- /dev/null +++ b/php/self-signed-certificates/example.key @@ -0,0 +1,28 @@ +-----BEGIN PRIVATE KEY----- +MIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQDSWvTnKAlvpno/ +KgzAgkxp6jALlKgSI9cGS4DnU+Ax64qtbyotSS7A2ZGHpKwqv7H1qPe5A17HSumD +ePprmuRDeHExt5kqWpfkYC03NhzChxX4Mz8yDf5+QBKs3VWW+Y9D9y6FDR+vOwJa +ZVtAQfiuuBsP/9ij8dEPBZIatiPe1fEkaanbO/DyR84X7mTbPwFBaRV52BycjtkO +twbatmqEzEMqCw0QQcYp+9CCNugo4d5OhITGPh7mEtQI3yPHA0MNvPWrCQS2usz6 +A9FRmhjXwkqzs8a1Kn4SKDpLmFu6ziLCuq0krtZ3kikCIji1Y0MYn8a0CCCk0IUY +kqZYA/S1AgMBAAECggEARqfQjPgwuzTi6OZ55AugGQ9VVf53uagaKH4h7RGKQ5pH +OVwWgaGMN7CcpkAUqEM9RjOcCaPtKOmrp8Jx8sTTGSqScs2lf8lwLYB0j4/4dwqi +wXyNJIX4znU9EJ1Di3OFwKF9Gam/077xWmWjEeFW43DpfiVEokSuIOqRGbHGOKlt +2ygHJu+rmPapEPyYqSWQnAkYX0DW/KCAGiyIAqph/SgrCDTdsxbNOa2OwDygPC54 +7xW0yCduvgFLh9bxedF8iifzRkPw710cxyqVsYwHiwugDgxL4NiK1DlWbpBimab5 +ocye9+ElymMZ8DTjpA85cXny/TtoqJfqTs1YGYgrvQKBgQDwHnAcY0BjQ4o+ZneG +oqBJeQ8KCMRU4pEIa5QOOeUr46gtiPIfcFh/BJUHQ61qk7gcJj5BV2GXNS7+m+sU +RC3Usblm9twwxZn7mfoOk4z9NEfBI2MXmbB8ARjAQBCost+3KQAoSIL1AyDKiAlY +2JfMt+73+kwUsg7b9g0pYIfn/wKBgQDgRJPlSIxJs2mbjzUwVBAeslct2W0dehrh +V0sXPxEhJHWX6P343vLqRHRsKgqhbU/vy+3JrIS9ftwGKcmb+Y9EJgYrR+D3ZYzs +idSOsunSspJgbCG5mHE1VQhr8IpHeCkuSt22aFErLfsjzXWZIewK2tqZN1QUjdc5 +EJHOD4UDSwKBgFYRYvgZ72NlOzFAw0kkE7YiSWy8Vbtjdr8A6JHs2KNRt9+Sfc8d +Eut8dfqjnI5eIpkccCY1rwpnCtBCjRG3moHprl4k0Co/OgGAYKxG4TuFOM8W4xb7 +hNH+BqQqko4Vh7D8Zk0KKL6v/1n5RvhssoSzzVlfg1PLux3G5VLWggB7AoGAAP/N +OORN27Y07kCBGCoHuFtLECU72znEDOT6rKvXQ7KJ45diKk2z/182tZSqX3XBOWxL +Lu7Z2I5MJKri/xLplIAm3uJ/GhsVuagTjl81s36gMFXLAKyxNG+gjfqQYykh5dbn +jfyBABRAXjR4JaqFBrda6fvZIA5RuytbuvNOwGkCgYAUs82tDGLiqyMPd2jgYS3k +aL62f0TLKHjmTCmRca7IqXbqcMbAj+LgAHI2HfCfjc4KWd68ZGRLcpDlehMcis1f +PQi3HW+2b9dAZX6+HAIGiVem//ckYXgUza4MMosh0hXquGs1yJ/VNWC+HPIHrj6X +9tvvvHnGKav329q/Z/8K/A== +-----END PRIVATE KEY-----