├── .gitignore ├── .ruby-version ├── .tool-versions ├── Gemfile ├── Jenkinsfile ├── LICENSE ├── README.md ├── Rakefile ├── appliances ├── README.md ├── aws │ └── Dockerfile ├── debugging │ ├── README.md │ ├── bionic │ │ └── Dockerfile │ ├── focal │ │ └── Dockerfile │ └── template │ │ └── Dockerfile ├── dynamo-local-admin │ ├── Dockerfile │ ├── README.md │ ├── nginx-proxy.conf │ └── supervisord.conf ├── dynamo │ ├── Dockerfile │ ├── README.md │ └── entrypoint.sh ├── elasticmq-integration │ ├── Dockerfile │ └── elasticmq.conf ├── elasticmq │ ├── Dockerfile │ └── elasticmq.conf ├── elmerglue │ ├── Dockerfile │ └── README.md ├── fake-s3 │ ├── Dockerfile │ ├── README.md │ └── entrypoint.sh ├── fake-sqs │ └── Dockerfile ├── gergich │ └── Dockerfile ├── gpg-signer │ ├── Dockerfile │ ├── README.md │ └── entrypoint.sh ├── kinesalite │ ├── Dockerfile │ └── README.md ├── kinesis2sqs │ ├── Dockerfile │ ├── Gemfile │ ├── Gemfile.lock │ ├── README.md │ └── entrypoint.rb ├── libreoffice │ ├── 24.8 │ │ └── Dockerfile │ ├── 6.2 │ │ └── Dockerfile │ ├── 6.3 │ │ └── Dockerfile │ └── template │ │ └── Dockerfile ├── mailcatcher │ ├── Dockerfile │ └── README.md ├── opensearch │ ├── 1.3.2 │ │ └── Dockerfile │ ├── README.md │ └── template │ │ └── Dockerfile ├── sonar-cli │ ├── Dockerfile │ └── README.md ├── tx │ ├── Dockerfile │ └── README.md └── zeppelin │ └── Dockerfile ├── auto-update.py ├── ci ├── Dockerfile ├── docker-manifest.sh └── get-cache-layers.sh ├── core ├── README.md ├── bionic-slim │ └── Dockerfile ├── bionic │ └── Dockerfile ├── focal │ └── Dockerfile ├── jammy │ └── Dockerfile ├── noble │ └── Dockerfile └── template │ └── Dockerfile ├── corretto ├── 17 │ └── Dockerfile ├── 20 │ └── Dockerfile ├── 21 │ └── Dockerfile ├── 22 │ └── Dockerfile ├── 24 │ └── Dockerfile └── template │ └── Dockerfile ├── golang ├── 1.21 │ └── Dockerfile ├── 1.22 │ └── Dockerfile ├── 1.23 │ └── Dockerfile ├── 1.24 │ └── Dockerfile ├── README.md └── template │ └── Dockerfile ├── java ├── 11 │ └── Dockerfile ├── 16 │ └── Dockerfile ├── 17 │ └── Dockerfile ├── 18 │ └── Dockerfile ├── 19 │ └── Dockerfile ├── 11-jre │ └── Dockerfile ├── 16-jre │ └── Dockerfile ├── 17-focal │ └── Dockerfile ├── 17-jre-focal │ └── Dockerfile ├── 17-jre │ └── Dockerfile ├── 18-jre │ └── Dockerfile ├── 19-jre │ └── Dockerfile ├── README.md └── template │ └── Dockerfile ├── k8s-ci ├── README.md ├── main │ ├── Dockerfile │ └── bin │ │ └── kustomize-lint └── template │ ├── Dockerfile │ └── bin │ └── kustomize-lint ├── k8s-toolbox ├── 1.25 │ └── Dockerfile ├── 1.26 │ └── Dockerfile └── template │ └── Dockerfile ├── lib ├── generation_message.rb └── template.rb ├── manifest.yml ├── node-passenger ├── 14 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 16 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 18 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 20 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 22 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── README.md └── template │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ └── env.conf.erb │ └── nginx.conf.erb ├── node-pm2-libvips ├── 20 │ └── Dockerfile ├── README.md └── template │ └── Dockerfile ├── node-pm2 ├── 14 │ ├── Dockerfile │ ├── conf.d │ │ └── proxy.conf.erb │ ├── default.config.json │ ├── entrypoint │ ├── nginx.conf.erb │ └── supervisord │ │ └── supervisord.conf ├── 16 │ ├── Dockerfile │ ├── conf.d │ │ └── proxy.conf.erb │ ├── default.config.json │ ├── entrypoint │ ├── nginx.conf.erb │ └── supervisord │ │ └── supervisord.conf ├── 18 │ ├── Dockerfile │ ├── conf.d │ │ └── proxy.conf.erb │ ├── default.config.json │ ├── entrypoint │ ├── nginx.conf.erb │ └── supervisord │ │ └── supervisord.conf ├── 20 │ ├── Dockerfile │ ├── conf.d │ │ └── proxy.conf.erb │ ├── default.config.json │ ├── entrypoint │ ├── nginx.conf.erb │ └── supervisord │ │ └── supervisord.conf ├── README.md └── template │ ├── Dockerfile │ ├── conf.d │ └── proxy.conf.erb │ ├── default.config.json │ ├── entrypoint │ ├── nginx.conf.erb │ └── supervisord │ └── supervisord.conf ├── node ├── 14 │ ├── Dockerfile │ ├── npm-private │ └── yarn-private ├── 16 │ ├── Dockerfile │ ├── npm-private │ └── yarn-private ├── 18 │ ├── Dockerfile │ ├── npm-private │ └── yarn-private ├── 20 │ ├── Dockerfile │ ├── npm-private │ └── yarn-private ├── 22 │ ├── Dockerfile │ ├── npm-private │ └── yarn-private ├── README.md └── template │ ├── Dockerfile │ ├── npm-private │ └── yarn-private ├── php-nginx ├── README.md └── template │ ├── Dockerfile │ ├── entrypoint.d │ ├── 10-configure-fpm.py │ ├── 20-configure-nginx.py │ ├── 30-configure-datadog.py │ └── nginx.conf │ └── supervisor │ └── supervisord.conf ├── php ├── 7.4 │ ├── Dockerfile │ └── entrypoint.sh ├── README.md └── template │ ├── Dockerfile │ └── entrypoint.sh ├── python ├── 3.10 │ ├── Dockerfile │ ├── pip-private │ └── pipenv-private ├── 3.7 │ ├── Dockerfile │ ├── pip-private │ └── pipenv-private ├── README.md └── template │ ├── Dockerfile │ ├── pip-private │ └── pipenv-private ├── rover ├── template │ └── Dockerfile └── v0.4.8 │ └── Dockerfile ├── ruby-passenger ├── 2.7 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 3.0 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 3.1-jammy │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 3.1 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 3.2-jammy │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 3.2 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 3.3-jammy │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 3.3 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 3.4-jammy │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── 3.4 │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ │ └── env.conf.erb │ └── nginx.conf.erb ├── README.md └── template │ ├── Dockerfile │ ├── entrypoint │ ├── main.d │ └── env.conf.erb │ └── nginx.conf.erb ├── ruby ├── 2.7-jammy │ └── Dockerfile ├── 2.7 │ └── Dockerfile ├── 3.0-jammy │ └── Dockerfile ├── 3.0 │ └── Dockerfile ├── 3.1-jammy │ └── Dockerfile ├── 3.1 │ └── Dockerfile ├── 3.2-jammy │ └── Dockerfile ├── 3.2 │ └── Dockerfile ├── 3.3-jammy │ └── Dockerfile ├── 3.3 │ └── Dockerfile ├── 3.4-jammy │ └── Dockerfile ├── 3.4 │ └── Dockerfile ├── README.md └── template │ └── Dockerfile ├── rvm └── Dockerfile ├── scala-sbt ├── 1.5 │ ├── Dockerfile │ └── sbt-private ├── README.md └── template │ ├── Dockerfile │ └── sbt-private ├── templates ├── node_install.Dockerfile └── yarn_install.Dockerfile ├── tini ├── README.md ├── template │ └── Dockerfile ├── v0.16.1 │ └── Dockerfile ├── v0.18.0 │ └── Dockerfile └── v0.19.0 │ └── Dockerfile └── yq ├── 4.44.1 └── Dockerfile └── template └── Dockerfile /.gitignore: -------------------------------------------------------------------------------- 1 | /.bundle/ 2 | /Gemfile.lock 3 | ci/dockerfiles_*.yml 4 | /.idea 5 | -------------------------------------------------------------------------------- /.ruby-version: -------------------------------------------------------------------------------- 1 | 3.1.0 2 | -------------------------------------------------------------------------------- /.tool-versions: -------------------------------------------------------------------------------- 1 | ruby 3.1.4 2 | -------------------------------------------------------------------------------- /Gemfile: -------------------------------------------------------------------------------- 1 | source 'https://rubygems.org' 2 | 3 | gem 'rake' 4 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2016 Instructure 2 | Permission is hereby granted, free of charge, to any person obtaining a copy of 3 | this software and associated documentation files (the "Software"), to deal in 4 | the Software without restriction, including without limitation the rights to use, 5 | copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the 6 | Software, and to permit persons to whom the Software is furnished to do so, 7 | subject to the following conditions: 8 | The above copyright notice and this permission notice shall be included in all 9 | copies or substantial portions of the Software. 10 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 11 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 12 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 13 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 14 | WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 15 | CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 16 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Open source Instructure base docker images 2 | 3 | # Updating an image 4 | 5 | The language base images along with their web server (passenger) counterparts 6 | are all generated using a template system. To make changes change the files in 7 | the respective `template` directory then run `rake` to propagate the changes to 8 | each version of the build directory. Parameters for building each templated 9 | directory are supplied by the manifest file found in the project directory. 10 | Each object supplied in the versions object corresponds to a version directory 11 | in the respective language. This object is merged with the defaults object along 12 | with version and generation_message keys are supplied to any template files 13 | specified in the manifest. 14 | -------------------------------------------------------------------------------- /appliances/README.md: -------------------------------------------------------------------------------- 1 | # Appliances 2 | 3 | These are docker images that are intended to be used as "appliances" the same 4 | way that you'd use the postgres or redis images. Typically they use ENDPOINT and 5 | define their own VOLUME if they store data on disk between runs. 6 | 7 | Many appliances are third party applications that other Instructure projects 8 | use, and we've created our own appliance for them here because there was no 9 | existing good option in the Docker Registry. 10 | -------------------------------------------------------------------------------- /appliances/aws/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM alpine:3.9 2 | 3 | RUN apk --verbose --upgrade --no-cache add \ 4 | python \ 5 | py-pip \ 6 | groff \ 7 | less \ 8 | mailcap \ 9 | && pip install --upgrade \ 10 | awscli==1.16.145 s3cmd==2.0.2 python-magic \ 11 | && apk --purge del py-pip 12 | 13 | VOLUME /root/.aws 14 | 15 | VOLUME /project 16 | WORKDIR /project 17 | 18 | -------------------------------------------------------------------------------- /appliances/debugging/README.md: -------------------------------------------------------------------------------- 1 | # Debugging 2 | 3 | A container with some useful debugging tools pre-installed meant to be attached 4 | to an already running container. 5 | 6 | ## Connecting to a running container 7 | 8 | ```console 9 | CONTAINER_NAME=cloudgate-running docker run --rm \ 10 | -it \ 11 | --net=container:${CONTAINER_NAME} \ 12 | --pid=container:${CONTAINER_NAME} \ 13 | --cap-add sys_admin \ 14 | --cap-add sys_ptrace \ 15 | instructure/debugging bash 16 | ``` 17 | -------------------------------------------------------------------------------- /appliances/debugging/bionic/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:bionic 2 | 3 | USER root 4 | 5 | RUN apt-get update && \ 6 | apt-get install -y \ 7 | curl \ 8 | gdb \ 9 | lsof \ 10 | net-tools \ 11 | pstack \ 12 | strace && \ 13 | apt-get clean 14 | 15 | CMD ["bash"] 16 | -------------------------------------------------------------------------------- /appliances/debugging/focal/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:focal 2 | 3 | USER root 4 | 5 | RUN apt-get update && \ 6 | apt-get install -y \ 7 | curl \ 8 | gdb \ 9 | lsof \ 10 | net-tools \ 11 | pstack \ 12 | strace && \ 13 | apt-get clean 14 | 15 | CMD ["bash"] 16 | -------------------------------------------------------------------------------- /appliances/debugging/template/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ubuntu:<%= version %> 2 | 3 | USER root 4 | 5 | RUN apt-get update && \ 6 | apt-get install -y \ 7 | curl \ 8 | gdb \ 9 | lsof \ 10 | net-tools \ 11 | pstack \ 12 | strace && \ 13 | apt-get clean 14 | 15 | CMD ["bash"] 16 | -------------------------------------------------------------------------------- /appliances/dynamo-local-admin/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=${TARGETPLATFORM} openjdk:11-jre-slim 2 | 3 | ENV DEBIAN_FRONTEND=noninteractive 4 | RUN apt-get update && apt-get install -y --no-install-recommends \ 5 | curl \ 6 | dirmngr \ 7 | gnupg2 \ 8 | nginx \ 9 | supervisor \ 10 | xz-utils \ 11 | && apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ 12 | 13 | RUN mkdir ~/.gnupg && echo "disable-ipv6" >> ~/.gnupg/dirmngr.conf 14 | 15 | # We need java and node in this image, so we'll start with java (cause it's 16 | # more hairy), and then dump in the node Dockerfile below. It'd be nice if there 17 | # was a more elegant way to compose at the image level, but I suspect the 18 | # response here would be "use two containers". 19 | 20 | ENV NODE_VERSION 12 21 | ENV NPM_CONFIG_LOGLEVEL error 22 | 23 | RUN curl -fsSL https://deb.nodesource.com/setup_lts.x | bash - && \ 24 | apt-get update && \ 25 | apt-get install -y --no-install-recommends nodejs && \ 26 | apt-get clean && \ 27 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ && \ 28 | npm install -g "npm@$NPM_VERSION" && \ 29 | npm cache clean --force 30 | 31 | RUN npm install --no-optional --global dynamodb-admin@4.0.0 \ 32 | && npm cache clean --force 33 | 34 | RUN mkdir -p /var/lib/dynamodb && cd /usr/lib && \ 35 | curl -L https://s3-us-west-2.amazonaws.com/dynamodb-local/dynamodb_local_latest.tar.gz | tar xz 36 | VOLUME /var/lib/dynamodb 37 | 38 | COPY nginx-proxy.conf /etc/nginx-proxy.conf 39 | COPY supervisord.conf /etc/supervisord.conf 40 | 41 | # Configure a sane default Java heap size (that can be overridden). 42 | ENV JAVA_OPTS "-Xmx256m" 43 | 44 | # Configuration for dynamo-admin to know where to hit dynamo. 45 | ENV DYNAMO_ENDPOINT http://localhost:8002/ 46 | 47 | # For dinghy users. 48 | ENV VIRTUAL_HOST dynamo.docker 49 | ENV VIRTUAL_PORT 8000 50 | 51 | # Main proxy on 8000, dynamo-admin on 8001, dynamodb on 8002 52 | EXPOSE 8000 8001 8002 53 | 54 | CMD ["/usr/bin/supervisord", "-c", "/etc/supervisord.conf"] 55 | -------------------------------------------------------------------------------- /appliances/dynamo-local-admin/README.md: -------------------------------------------------------------------------------- 1 | # DynamoDB Local Admin 2 | 3 | This project builds a Docker image with [DynamoDB Local][dbd] and 4 | [dynamodb-admin][dbd-admin] installed and hooked up. 5 | 6 | [dbd]: http://docs.aws.amazon.com/amazondynamodb/latest/developerguide/DynamoDBLocal.html 7 | [dbd-admin]: https://github.com/aaronshaf/dynamodb-admin 8 | 9 | ## Usage 10 | 11 | ``` 12 | docker pull instructure/dynamo-local-admin 13 | docker run -p 8000:8000 -it --rm instructure/dynamo-local-admin 14 | ``` 15 | 16 | Now open http://localhost:8000/ in your browser, and you'll see the admin UI. 17 | You can also hit port 8000 with Dynamo API requests: 18 | 19 | ``` 20 | AWS_ACCESS_KEY_ID=key AWS_SECRET_ACCESS_KEY=secret aws --region us-east-1 dynamodb --endpoint http://localhost:8000/ list-tables 21 | ``` 22 | 23 | A proxy is included which differentiates between Dynamo requests and web 24 | requests, and proxies to the appropriate server. 25 | 26 | ## Why? 27 | 28 | It's just very convenient if you do a lot of Dynamo development. 29 | 30 | ## Dinghy Users 31 | 32 | If you're using Dinghy and its automatic proxy, `VIRTUAL_HOST` and 33 | `VIRTUAL_PORT` are already set, so you don't have to specify any ports in the 34 | `docker run` and can just open http://dynamo.docker/ in your browser. 35 | -------------------------------------------------------------------------------- /appliances/dynamo-local-admin/nginx-proxy.conf: -------------------------------------------------------------------------------- 1 | daemon off; 2 | pid /tmp/nginx.pid; 3 | 4 | events { 5 | worker_connections 1024; 6 | } 7 | 8 | http { 9 | default_type application/octet-stream; 10 | sendfile on; 11 | 12 | access_log /dev/stdout; 13 | error_log stderr info; 14 | 15 | upstream dynamodb { 16 | server 127.0.0.1:8002; 17 | } 18 | 19 | upstream admin { 20 | server 127.0.0.1:8001; 21 | } 22 | 23 | map $http_x_amz_target $pool { 24 | default "admin"; 25 | '~*dynamo' "dynamodb"; 26 | } 27 | 28 | server { 29 | listen 8000; 30 | server_name dynamo.docker; 31 | location / { 32 | proxy_pass http://$pool; 33 | 34 | proxy_set_header X-Real-IP $remote_addr; 35 | proxy_redirect off; 36 | proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; 37 | proxy_set_header Host $http_host; 38 | proxy_redirect off; 39 | proxy_set_header X-Forwarded-Proto $scheme; 40 | proxy_set_header X-NginX-Proxy true; 41 | proxy_connect_timeout 60; 42 | proxy_send_timeout 60; 43 | proxy_read_timeout 60; 44 | send_timeout 60; 45 | } 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /appliances/dynamo-local-admin/supervisord.conf: -------------------------------------------------------------------------------- 1 | [supervisord] 2 | nodaemon=true 3 | stdout_logfile=/dev/stdout 4 | stderr_logfile=/dev/stderr 5 | stdout_logfile_maxbytes=0 6 | stderr_logfile_maxbytes=0 7 | 8 | [program:dynamodb] 9 | command=/usr/local/openjdk-11/bin/java -Djava.library.path=/usr/lib/DynamoDBLocal_lib 10 | -jar /usr/lib/DynamoDBLocal.jar 11 | -port 8002 12 | -sharedDb 13 | -dbPath /var/lib/dynamodb 14 | stdout_logfile=/dev/stdout 15 | stderr_logfile=/dev/stderr 16 | stdout_logfile_maxbytes=0 17 | stderr_logfile_maxbytes=0 18 | 19 | [program:dynamo-admin] 20 | command=dynamodb-admin 21 | stdout_logfile=/dev/stdout 22 | stderr_logfile=/dev/stderr 23 | stdout_logfile_maxbytes=0 24 | stderr_logfile_maxbytes=0 25 | 26 | [program:nginx] 27 | command=/usr/sbin/nginx -c /etc/nginx-proxy.conf 28 | stdout_logfile=/dev/stdout 29 | stderr_logfile=/dev/stderr 30 | stdout_logfile_maxbytes=0 31 | stderr_logfile_maxbytes=0 32 | -------------------------------------------------------------------------------- /appliances/dynamo/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM instructure/java:11-jre 2 | 3 | WORKDIR /home/docker 4 | ENV DATADIR /var/lib/dynamo 5 | 6 | USER root 7 | RUN mkdir $DATADIR && chown docker:docker $DATADIR 8 | USER docker 9 | 10 | RUN /usr/bin/curl -L http://dynamodb-local.s3-website-us-west-2.amazonaws.com/dynamodb_local_latest.tar.gz | /bin/tar xz 11 | 12 | EXPOSE 8000 13 | VOLUME $DATADIR 14 | 15 | COPY entrypoint.sh /home/docker/entrypoint.sh 16 | 17 | # Configure a sane default Java heap size (that can be overridden). 18 | ENV JAVA_OPTS "-Xmx256m" 19 | 20 | ENTRYPOINT ["/home/docker/entrypoint.sh", "-dbPath /var/lib/dynamo"] 21 | -------------------------------------------------------------------------------- /appliances/dynamo/README.md: -------------------------------------------------------------------------------- 1 | # DynamoDB 2 | 3 | --- 4 | 5 | WARNING: This appliance image is deprecated, and will be removed soon. Please 6 | replace all usage either with the official `amazon/dynamodb-local` image, or 7 | the `instructure/dynamo-local-admin` image. 8 | 9 | * https://hub.docker.com/r/amazon/dynamodb-local/ 10 | * https://hub.docker.com/r/instructure/dynamo-local-admin/ 11 | 12 | --- 13 | 14 | A docker container appliance wrapping [DynamoDB Local][dbd], for use testing and 15 | developing against Amazon's DynamoDB. 16 | 17 | To use it, run the container and connect to port 8000: 18 | 19 | ``` 20 | docker run -d --name mydynamo -p 8000:8000 instructure/dynamo 21 | AWS_ENDPOINT=http://localhost:8000 AWS_ACCESS_KEY_ID=x AWS_SECRET_ACCESS_KEY=x aws dynamo create-table ... 22 | ``` 23 | 24 | [dbd]: http://docs.aws.amazon.com/amazondynamodb/latest/developerguide/DynamoDBLocal.html 25 | -------------------------------------------------------------------------------- /appliances/dynamo/entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | exec /usr/bin/java -Djava.library.path=./DynamoDBLocal_lib -jar DynamoDBLocal.jar -sharedDb $@ 4 | -------------------------------------------------------------------------------- /appliances/elasticmq-integration/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM alpine 2 | 3 | RUN apk update \ 4 | && apk upgrade \ 5 | && apk add --update --no-cache openjdk11 curl \ 6 | && rm -rf /var/cache/apk/* 7 | 8 | RUN curl -sSLO https://s3-eu-west-1.amazonaws.com/softwaremill-public/elasticmq-server-0.14.7.jar 9 | 10 | EXPOSE 9324 11 | 12 | ADD /elasticmq.conf /elasticmq/elasticmq.conf 13 | 14 | CMD [ "java", "-Djava.net.preferIPv4Stack=true", "-Dconfig.file=/elasticmq/elasticmq.conf", "-jar", "elasticmq-server-0.14.7.jar" ] -------------------------------------------------------------------------------- /appliances/elasticmq-integration/elasticmq.conf: -------------------------------------------------------------------------------- 1 | include classpath("application.conf") 2 | 3 | node-address { 4 | protocol = http 5 | host = "*" 6 | port = 9324 7 | context-path = "" 8 | } 9 | 10 | rest-sqs { 11 | enabled = true 12 | bind-port = 9324 13 | bind-hostname = "0.0.0.0" 14 | sqs-limits = relaxed 15 | } 16 | 17 | queues { 18 | queue1 { 19 | defaultVisibilityTimeout = 10 seconds 20 | delay = 5 seconds 21 | receiveMessageWait = 0 seconds 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /appliances/elasticmq/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=${TARGETPLATFORM} openjdk:11-jre 2 | 3 | #RUN apk add --no-cache curl 4 | RUN curl -sSLO https://s3-eu-west-1.amazonaws.com/softwaremill-public/elasticmq-server-1.5.7.jar 5 | 6 | EXPOSE 9324 7 | 8 | ADD /elasticmq.conf /elasticmq/elasticmq.conf 9 | 10 | CMD [ "/usr/local/openjdk-11/bin/java", "-Djava.net.preferIPv4Stack=true", "-Dconfig.file=/elasticmq/elasticmq.conf", "-jar", "elasticmq-server-1.5.7.jar" ] 11 | -------------------------------------------------------------------------------- /appliances/elasticmq/elasticmq.conf: -------------------------------------------------------------------------------- 1 | include classpath("application.conf") 2 | 3 | node-address { 4 | protocol = http 5 | host = "*" 6 | port = 9324 7 | context-path = "" 8 | } 9 | 10 | rest-sqs { 11 | enabled = true 12 | bind-port = 9324 13 | bind-hostname = "0.0.0.0" 14 | sqs-limits = relaxed 15 | } 16 | 17 | queues { 18 | queue1 { 19 | defaultVisibilityTimeout = 10 seconds 20 | delay = 5 seconds 21 | receiveMessageWait = 0 seconds 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /appliances/elmerglue/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM node:10-alpine 2 | MAINTAINER Instructure 3 | 4 | RUN apk add --no-cache make gcc g++ python \ 5 | && npm install --global --production --unsafe-perm true elmerglue@0.0.5 \ 6 | && apk --purge del make gcc g++ python 7 | 8 | RUN mkdir /app 9 | VOLUME /app 10 | 11 | EXPOSE 5678 12 | 13 | CMD ["/usr/local/bin/elmerglue", "--path", "/app"] 14 | -------------------------------------------------------------------------------- /appliances/elmerglue/README.md: -------------------------------------------------------------------------------- 1 | # elmerglue 2 | 3 | A docker container appliance wrapping 4 | [ElmerGlue](https://github.com/kblibr/elmerglue). This is a clone of AWS 5 | Glue that runs locally, often used in development setups. 6 | 7 | To use it, just run the container and connect on port 5678: 8 | 9 | docker run -d --name myGlue -p 5678:5678 instructure/elmerglue 10 | AWS_ACCESS_KEY_ID=x AWS_SECRET_ACCESS_KEY=x aws --endpoint-url http://mydockerhost:5678/ 11 | -------------------------------------------------------------------------------- /appliances/fake-s3/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM instructure/ruby:2.5 2 | 3 | USER root 4 | 5 | RUN mkdir -p /fakes3/fakes3_data_root 6 | COPY entrypoint.sh /fakes3/ 7 | 8 | # setup for fakes3 9 | RUN chmod +x /fakes3/entrypoint.sh && \ 10 | chown -R docker:docker /fakes3 11 | 12 | USER docker 13 | 14 | # install fake-s3 - 0.2.5 is the last release licensed under MIT 15 | RUN gem install fakes3 -v 0.2.5 16 | 17 | 18 | # run fake-s3 19 | EXPOSE 4569 20 | ENTRYPOINT ["/fakes3/entrypoint.sh"] 21 | -------------------------------------------------------------------------------- /appliances/fake-s3/README.md: -------------------------------------------------------------------------------- 1 | # Fake S3 2 | 3 | --- 4 | 5 | WARNING: This appliance image is deprecated, and will be removed soon. Please 6 | replace all usage with `minio/minio`: https://hub.docker.com/r/minio/minio/ 7 | 8 | --- 9 | 10 | A docker image with Fake S3 pre-installed. 11 | 12 | * https://github.com/jubos/fake-s3 13 | -------------------------------------------------------------------------------- /appliances/fake-s3/entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | $GEM_HOME/bin/fakes3 -r /fakes3/fakes3_data_root -p 4569 4 | -------------------------------------------------------------------------------- /appliances/fake-sqs/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=${TARGETPLATFORM} ruby:2.5-alpine 2 | 3 | RUN gem install fake_sqs -v 0.4.3 4 | 5 | EXPOSE 3000 6 | 7 | ENTRYPOINT ["/usr/local/bundle/bin/fake_sqs"] 8 | CMD ["-p", "3000", "--no-daemonize"] 9 | -------------------------------------------------------------------------------- /appliances/gergich/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=${TARGETPLATFORM} ruby:2.7-alpine 2 | 3 | RUN apk add --no-cache \ 4 | build-base \ 5 | git \ 6 | sqlite \ 7 | sqlite-dev \ 8 | sqlite-libs \ 9 | && apk del --purge \ 10 | build-base \ 11 | sqlite-dev 12 | 13 | # sqlite3 1.6.9 is the last version that supports Ruby 2.7 14 | # multi_xml 0.6.0 is the last version that supports Ruby 2.7 15 | RUN gem install sqlite3:1.6.9 \ 16 | multi_xml:0.6.0 \ 17 | gergich:2.2.0 18 | 19 | WORKDIR /app 20 | 21 | ENTRYPOINT ["gergich"] 22 | -------------------------------------------------------------------------------- /appliances/gpg-signer/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM instructure/core:bionic-slim 2 | 3 | VOLUME /to-sign 4 | 5 | USER root 6 | COPY entrypoint.sh /entrypoint.sh 7 | 8 | ENTRYPOINT ["/entrypoint.sh"] 9 | -------------------------------------------------------------------------------- /appliances/gpg-signer/README.md: -------------------------------------------------------------------------------- 1 | # gpg-signer 2 | 3 | Signs arbitrary files in mounted volume with provided GPG key and passphrase, 4 | and stores the signature files in the same directory using the same uid:gid. 5 | 6 | ## Usage 7 | 8 | Place any files you want signed in a dedicated directory, and mount that 9 | directory as volume `/to-sign` in the container. Provide your GPG private key 10 | via the environment variable `GPG_PRIVATE_KEY`, and the passphrase for using 11 | the key as `GPG_PASSPHRASE`. These are both highly sensitive values, so be 12 | sure to use appropriate secret management. 13 | 14 | Example: 15 | 16 | $ docker run --rm -it -v $(pwd)/my-signable-files:/to-sign \ 17 | -e GPG_PRIVATE_KEY -e GPG_PASSPHRASE \ 18 | instructure/gpg-signer 19 | 20 | If there are no files provided, the script will exit immediately. Any errors 21 | importing the key or signing the provided files will immediately end the run. 22 | 23 | Generated signature files will be named `.asc`. 24 | -------------------------------------------------------------------------------- /appliances/gpg-signer/entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | die() { echo "ERROR: $@" >&2; exit 1; } 4 | 5 | for f in /to-sign/*; do 6 | if [[ $f == "/to-sign/*" ]]; then 7 | echo "INFO: No files were found to sign in /to-sign. Exiting." 8 | exit 0 9 | else 10 | break 11 | fi 12 | done 13 | 14 | if [[ -z $GPG_PRIVATE_KEY ]]; then 15 | die "You must specify your private key via GPG_PRIVATE_KEY" 16 | fi 17 | 18 | if [[ -z $GPG_PASSPHRASE ]]; then 19 | die "You must specify your passphrase via GPG_PASSPHRASE" 20 | fi 21 | 22 | echo Importing private key: 23 | # import private key 24 | echo "$GPG_PRIVATE_KEY" > ~/private-key.pem 25 | if ! gpg --import --batch --yes ~/private-key.pem; then 26 | die "Unable to import private key into GPG" 27 | fi 28 | 29 | echo 30 | echo Getting key fingerprint... 31 | fingerprint=$( gpg --list-keys --with-colons |awk -F: '$1=="fpr" {print $10}' |head -n 1 ) 32 | if [[ -z $fingerprint ]]; then 33 | die "Could not get fingerprint for imported key" 34 | fi 35 | 36 | for f in /to-sign/*; do 37 | if [[ -f $f ]]; then 38 | file_uid=$( stat -c %u "$f" ) 39 | file_gid=$( stat -c %g "$f" ) 40 | signed_file="${f}.asc" 41 | if ! gpg --batch --passphrase "$GPG_PASSPHRASE" --pinentry-mode loopback --local-user "$fingerprint" --output "$signed_file" --detach-sign "$f"; then 42 | die "Unable to sign file '$f'" 43 | fi 44 | chown "$file_uid:$file_gid" "$signed_file" 45 | echo Signed $f 46 | fi 47 | done 48 | -------------------------------------------------------------------------------- /appliances/kinesalite/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=${TARGETPLATFORM} instructure/node:14 2 | MAINTAINER Instructure 3 | 4 | ENV DATADIR /var/lib/kinesalite 5 | 6 | USER root 7 | RUN mkdir $DATADIR && chown docker:docker $DATADIR 8 | USER docker 9 | 10 | RUN npm install kinesalite@3.3.1 11 | 12 | EXPOSE 4567 13 | VOLUME $DATADIR 14 | 15 | ENTRYPOINT ["/tini", "--", "/usr/src/app/node_modules/kinesalite/cli.js", "--path", "/var/lib/kinesalite"] 16 | -------------------------------------------------------------------------------- /appliances/kinesalite/README.md: -------------------------------------------------------------------------------- 1 | # kinesalite 2 | 3 | A docker container appliance wrapping 4 | [Kinesalite](https://github.com/mhart/kinesalite). This is a clone of AWS 5 | Kinesis that runs locally, often used in development setups. 6 | 7 | To use it, just run the container and connect on port 4567: 8 | 9 | docker run -d --name mykinesis -p 4567:4567 instructure/kinesalite 10 | AWS_ACCESS_KEY_ID=x AWS_SECRET_ACCESS_KEY=x aws --endpoint-url http://mydockerhost:4567/ kinesis create-stream --stream-name=mystream --shard-count=1 11 | -------------------------------------------------------------------------------- /appliances/kinesis2sqs/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=${TARGETPLATFORM} ruby:2.7-alpine 2 | MAINTAINER Instructure 3 | 4 | COPY Gemfile Gemfile.lock ./ 5 | RUN bundle install --quiet --jobs 8 6 | 7 | COPY entrypoint.rb . 8 | 9 | CMD ["ruby", "./entrypoint.rb"] 10 | -------------------------------------------------------------------------------- /appliances/kinesis2sqs/Gemfile: -------------------------------------------------------------------------------- 1 | source 'https://rubygems.org' 2 | 3 | gem 'aws-sdk-kinesis', '~> 1.9' 4 | gem 'aws-sdk-sqs', '~> 1.10' 5 | -------------------------------------------------------------------------------- /appliances/kinesis2sqs/Gemfile.lock: -------------------------------------------------------------------------------- 1 | GEM 2 | remote: https://rubygems.org/ 3 | specs: 4 | aws-eventstream (1.0.1) 5 | aws-partitions (1.121.0) 6 | aws-sdk-core (3.42.0) 7 | aws-eventstream (~> 1.0) 8 | aws-partitions (~> 1.0) 9 | aws-sigv4 (~> 1.0) 10 | jmespath (~> 1.0) 11 | aws-sdk-kinesis (1.9.0) 12 | aws-sdk-core (~> 3, >= 3.39.0) 13 | aws-sigv4 (~> 1.0) 14 | aws-sdk-sqs (1.10.0) 15 | aws-sdk-core (~> 3, >= 3.39.0) 16 | aws-sigv4 (~> 1.0) 17 | aws-sigv4 (1.0.3) 18 | jmespath (1.4.0) 19 | 20 | PLATFORMS 21 | ruby 22 | 23 | DEPENDENCIES 24 | aws-sdk-kinesis (~> 1.9) 25 | aws-sdk-sqs (~> 1.10) 26 | 27 | BUNDLED WITH 28 | 2.1.4 29 | -------------------------------------------------------------------------------- /appliances/kinesis2sqs/README.md: -------------------------------------------------------------------------------- 1 | # Kinesis2Sqs 2 | 3 | A ruby based docker appliance image to pull messages from Kinesis and push them 4 | to SQS. We use this to simulate our Live Events messaging system in development. 5 | 6 | An entry in your docker-compose.yml file might look like this: 7 | 8 | ``` 9 | kinesis2sqs: 10 | image: instructure/kinesis2sqs 11 | environment: 12 | SLEEP_LENGTH: 5 13 | AWS_REGION: us-east-1 14 | AWS_ACCESS_KEY: x 15 | AWS_SECRET_ACCESS_KEY: x 16 | AWS_KINESIS_ENDPOINT: http://kinesis:4567 17 | AWS_KINESIS_STREAM_NAME: quiz-live-events 18 | AWS_SQS_ENDPOINT: http://elasticmq:9324 19 | AWS_SQS_QUEUE_NAME: queue1 20 | links: 21 | - kinesis 22 | - elasticmq 23 | 24 | kinesis: 25 | image: instructure/kinesalite 26 | ports: 27 | - "4567:4567" 28 | 29 | elasticmq: 30 | image: instructure/elasticmq 31 | ports: 32 | - "9324:9324" 33 | ``` 34 | -------------------------------------------------------------------------------- /appliances/libreoffice/24.8/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:appliances/libreoffice` 4 | 5 | 6 | FROM instructure/core:jammy 7 | 8 | USER root 9 | 10 | RUN apt-get clean \ 11 | && rm -rf /var/lib/apt/lists/* \ 12 | && apt-get update \ 13 | && apt-get install -y \ 14 | openjdk-11-jdk \ 15 | ghostscript \ 16 | libxinerama1 \ 17 | libdbus-glib-1-2 \ 18 | libcairo2 \ 19 | libcups2 \ 20 | libgl1-mesa-dri \ 21 | libgl1-mesa-glx \ 22 | libxslt1-dev \ 23 | libsm6 \ 24 | fonts-opensymbol \ 25 | hyphen-fr \ 26 | hyphen-de \ 27 | hyphen-en-us \ 28 | hyphen-it \ 29 | hyphen-ru \ 30 | fonts-dejavu \ 31 | fonts-dejavu-core \ 32 | fonts-dejavu-extra \ 33 | fonts-dustin \ 34 | fonts-f500 \ 35 | fonts-fanwood \ 36 | fonts-freefont-ttf \ 37 | fonts-liberation \ 38 | fonts-lmodern \ 39 | fonts-lyx \ 40 | fonts-sil-gentium \ 41 | fonts-texgyre \ 42 | fonts-tlwg-purisa \ 43 | curl \ 44 | --no-install-recommends \ 45 | && apt-get clean \ 46 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 47 | 48 | RUN mkdir /tmp/lo \ 49 | && cd /tmp/lo \ 50 | && curl -sSL https://downloadarchive.documentfoundation.org/libreoffice/old/24.8.5.2/deb/x86_64/LibreOffice_24.8.5.2_Linux_x86-64_deb.tar.gz | tar xz --strip-components=1 \ 51 | && cd DEBS \ 52 | && dpkg -i *.deb \ 53 | && rm -fr /tmp/lo 54 | 55 | # for compat with canvadocs converter, which hardcodes path to soffice 56 | RUN ln -s /opt/libreoffice24.8/program/soffice /usr/bin/soffice 57 | ENV PATH $PATH:/opt/libreoffice24.8/program 58 | 59 | USER docker 60 | -------------------------------------------------------------------------------- /appliances/libreoffice/6.2/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:appliances/libreoffice` 4 | 5 | 6 | FROM instructure/core:jammy 7 | 8 | USER root 9 | 10 | RUN apt-get clean \ 11 | && rm -rf /var/lib/apt/lists/* \ 12 | && apt-get update \ 13 | && apt-get install -y \ 14 | openjdk-11-jdk \ 15 | ghostscript \ 16 | libxinerama1 \ 17 | libdbus-glib-1-2 \ 18 | libcairo2 \ 19 | libcups2 \ 20 | libgl1-mesa-dri \ 21 | libgl1-mesa-glx \ 22 | libxslt1-dev \ 23 | libsm6 \ 24 | fonts-opensymbol \ 25 | hyphen-fr \ 26 | hyphen-de \ 27 | hyphen-en-us \ 28 | hyphen-it \ 29 | hyphen-ru \ 30 | fonts-dejavu \ 31 | fonts-dejavu-core \ 32 | fonts-dejavu-extra \ 33 | fonts-dustin \ 34 | fonts-f500 \ 35 | fonts-fanwood \ 36 | fonts-freefont-ttf \ 37 | fonts-liberation \ 38 | fonts-lmodern \ 39 | fonts-lyx \ 40 | fonts-sil-gentium \ 41 | fonts-texgyre \ 42 | fonts-tlwg-purisa \ 43 | curl \ 44 | --no-install-recommends \ 45 | && apt-get clean \ 46 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 47 | 48 | RUN mkdir /tmp/lo \ 49 | && cd /tmp/lo \ 50 | && curl -sSL https://downloadarchive.documentfoundation.org/libreoffice/old/6.2.7.1/deb/x86_64/LibreOffice_6.2.7.1_Linux_x86-64_deb.tar.gz | tar xz --strip-components=1 \ 51 | && cd DEBS \ 52 | && dpkg -i *.deb \ 53 | && rm -fr /tmp/lo 54 | 55 | # for compat with canvadocs converter, which hardcodes path to soffice 56 | RUN ln -s /opt/libreoffice6.2/program/soffice /usr/bin/soffice 57 | ENV PATH $PATH:/opt/libreoffice6.2/program 58 | 59 | USER docker 60 | -------------------------------------------------------------------------------- /appliances/libreoffice/6.3/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:appliances/libreoffice` 4 | 5 | 6 | FROM instructure/core:jammy 7 | 8 | USER root 9 | 10 | RUN apt-get clean \ 11 | && rm -rf /var/lib/apt/lists/* \ 12 | && apt-get update \ 13 | && apt-get install -y \ 14 | openjdk-11-jdk \ 15 | ghostscript \ 16 | libxinerama1 \ 17 | libdbus-glib-1-2 \ 18 | libcairo2 \ 19 | libcups2 \ 20 | libgl1-mesa-dri \ 21 | libgl1-mesa-glx \ 22 | libxslt1-dev \ 23 | libsm6 \ 24 | fonts-opensymbol \ 25 | hyphen-fr \ 26 | hyphen-de \ 27 | hyphen-en-us \ 28 | hyphen-it \ 29 | hyphen-ru \ 30 | fonts-dejavu \ 31 | fonts-dejavu-core \ 32 | fonts-dejavu-extra \ 33 | fonts-dustin \ 34 | fonts-f500 \ 35 | fonts-fanwood \ 36 | fonts-freefont-ttf \ 37 | fonts-liberation \ 38 | fonts-lmodern \ 39 | fonts-lyx \ 40 | fonts-sil-gentium \ 41 | fonts-texgyre \ 42 | fonts-tlwg-purisa \ 43 | curl \ 44 | --no-install-recommends \ 45 | && apt-get clean \ 46 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 47 | 48 | RUN mkdir /tmp/lo \ 49 | && cd /tmp/lo \ 50 | && curl -sSL https://downloadarchive.documentfoundation.org/libreoffice/old/6.3.1.2/deb/x86_64/LibreOffice_6.3.1.2_Linux_x86-64_deb.tar.gz | tar xz --strip-components=1 \ 51 | && cd DEBS \ 52 | && dpkg -i *.deb \ 53 | && rm -fr /tmp/lo 54 | 55 | # for compat with canvadocs converter, which hardcodes path to soffice 56 | RUN ln -s /opt/libreoffice6.3/program/soffice /usr/bin/soffice 57 | ENV PATH $PATH:/opt/libreoffice6.3/program 58 | 59 | USER docker 60 | -------------------------------------------------------------------------------- /appliances/libreoffice/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | 3 | FROM instructure/core:<%= ubuntu_version %> 4 | 5 | USER root 6 | 7 | RUN apt-get clean \ 8 | && rm -rf /var/lib/apt/lists/* \ 9 | && apt-get update \ 10 | && apt-get install -y \ 11 | openjdk-11-jdk \ 12 | ghostscript \ 13 | libxinerama1 \ 14 | libdbus-glib-1-2 \ 15 | libcairo2 \ 16 | libcups2 \ 17 | libgl1-mesa-dri \ 18 | libgl1-mesa-glx \ 19 | libxslt1-dev \ 20 | libsm6 \ 21 | fonts-opensymbol \ 22 | hyphen-fr \ 23 | hyphen-de \ 24 | hyphen-en-us \ 25 | hyphen-it \ 26 | hyphen-ru \ 27 | fonts-dejavu \ 28 | fonts-dejavu-core \ 29 | fonts-dejavu-extra \ 30 | fonts-dustin \ 31 | fonts-f500 \ 32 | fonts-fanwood \ 33 | fonts-freefont-ttf \ 34 | fonts-liberation \ 35 | fonts-lmodern \ 36 | fonts-lyx \ 37 | fonts-sil-gentium \ 38 | fonts-texgyre \ 39 | fonts-tlwg-purisa \ 40 | curl \ 41 | --no-install-recommends \ 42 | && apt-get clean \ 43 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 44 | 45 | RUN mkdir /tmp/lo \ 46 | && cd /tmp/lo \ 47 | && curl -sSL https://downloadarchive.documentfoundation.org/libreoffice/old/<%= full_version %>/deb/x86_64/LibreOffice_<%= full_version %>_Linux_x86-64_deb.tar.gz | tar xz --strip-components=1 \ 48 | && cd DEBS \ 49 | && dpkg -i *.deb \ 50 | && rm -fr /tmp/lo 51 | 52 | # for compat with canvadocs converter, which hardcodes path to soffice 53 | RUN ln -s /opt/libreoffice<%= version %>/program/soffice /usr/bin/soffice 54 | ENV PATH $PATH:/opt/libreoffice<%= version %>/program 55 | 56 | USER docker 57 | -------------------------------------------------------------------------------- /appliances/mailcatcher/Dockerfile: -------------------------------------------------------------------------------- 1 | ARG ROOT_PATH=instructure 2 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/ruby:2.7 3 | MAINTAINER Instructure 4 | 5 | USER root 6 | RUN apt-get update \ 7 | && apt-get install -y g++ 8 | 9 | USER docker 10 | RUN gem install mailcatcher -v 0.8.0 11 | 12 | EXPOSE 1025 8080 13 | 14 | ENTRYPOINT ["mailcatcher", "-f", "--ip=0.0.0.0", "--http-port=8080"] 15 | -------------------------------------------------------------------------------- /appliances/mailcatcher/README.md: -------------------------------------------------------------------------------- 1 | # MailCatcher 2 | 3 | A docker container appliance wrapping [MailCatcher](https://mailcatcher.me/). 4 | 5 | This runs a SMTP server (on port 1025) that accepts any mail you send it, and a 6 | web server (on port 8080) for browsing those emails in a webmail context. 7 | 8 | This is particularly useful for configuring a default development SMTP server 9 | in your application that works out of the box. 10 | 11 | An entry in your docker-compose.yml file might look like this: 12 | 13 | ```yaml 14 | mailcatcher: 15 | image: instructure/mailcatcher 16 | environment: 17 | VIRTUAL_HOST: mail.example.docker 18 | VIRTUAL_PORT: 8080 19 | ``` 20 | 21 | Next, configure your development SMTP server settings (no auth required): 22 | 23 | - address: mailcatcher 24 | - port: 1025 25 | 26 | In a Rails application, your `config/environments/development.rb` would be: 27 | 28 | ```ruby 29 | config.action_mailer.smtp_settings = { 30 | address: 'mailcatcher', port: 1025 31 | } 32 | ``` 33 | 34 | After spinning up the container, you can then open up your browser to: 35 | 36 | - http://mail.example.docker/ 37 | 38 | This inbox will automatically refresh with incoming mail. 39 | -------------------------------------------------------------------------------- /appliances/opensearch/README.md: -------------------------------------------------------------------------------- 1 | # OpenSearch 2 | 3 | Docker image for OpenSearch, including [plugins](#plugins). This is provided to help mirror the functionality of AWS hosted OpenSearch in a local development environment. 4 | 5 | ### Example docker-compose.yml 6 | 7 | ``` 8 | version: "3.8" 9 | 10 | services: 11 | opensearch: 12 | image: instructure/opensearch:1.3.2 13 | ports: 14 | - "9200:9200" 15 | - "5601:5601" 16 | environment: 17 | plugins.security.disabled: "true" 18 | discovery.type: single-node 19 | ES_JAVA_OPTS: -Xms512m -Xmx512m 20 | volumes: 21 | - os-data:/usr/share/opensearch/data 22 | 23 | volumes: 24 | os-data: {} 25 | ``` 26 | 27 | # Plugins 28 | 29 | | Plugin | Description | Source | 30 | | ----------- | ---------------------------------------------- | ------------------------------------------------------- | 31 | | vi-analyzer | Provides Vietnamese language analysis support. | https://github.com/duydo/opensearch-analysis-vietnamese | -------------------------------------------------------------------------------- /appliances/opensearch/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | ARG OPENSEARCH_VERSION=<%= opensearch_version %> 3 | 4 | FROM --platform=${TARGETPLATFORM} opensearchproject/opensearch:$OPENSEARCH_VERSION AS builder 5 | 6 | USER root 7 | 8 | RUN yum install -y gcc gcc-c++ make cmake pkg-config wget git 9 | 10 | ARG OPENSEARCH_VERSION 11 | ENV OPENSEARCH_VERSION=$OPENSEARCH_VERSION 12 | ENV JAVA_HOME=/usr/share/opensearch/jdk 13 | ENV PATH=$JAVA_HOME/bin:$PATH 14 | 15 | # Build coccoc-tokenizer (required by analysis-vietnamese) 16 | RUN echo "Building coccoc-tokenizer" 17 | WORKDIR /tmp 18 | RUN git clone https://github.com/duydo/coccoc-tokenizer.git 19 | RUN mkdir /tmp/coccoc-tokenizer/build 20 | WORKDIR /tmp/coccoc-tokenizer/build 21 | RUN cmake -DBUILD_JAVA=1 .. 22 | RUN make install 23 | 24 | # Build analysis-vietnamese 25 | RUN echo "Building analysis-vietnamese" 26 | WORKDIR /tmp 27 | RUN wget https://dlcdn.apache.org/maven/maven-3/3.8.8/binaries/apache-maven-3.8.8-bin.tar.gz \ 28 | && tar xvf apache-maven-3.8.8-bin.tar.gz 29 | ENV MVN_HOME=/tmp/apache-maven-3.8.8 30 | ENV PATH=$MVN_HOME/bin:$PATH 31 | 32 | WORKDIR /tmp 33 | RUN git clone https://github.com/duydo/opensearch-analysis-vietnamese.git 34 | WORKDIR /tmp/opensearch-analysis-vietnamese 35 | RUN sed -Ezi "s/(opensearch-analysis-vietnamese<\/artifactId>\n\s*).*(<\/version>)/\1${OPENSEARCH_VERSION}\2/m" pom.xml 36 | RUN mvn verify clean --fail-never 37 | RUN mvn --batch-mode -Dmaven.test.skip -e package 38 | 39 | FROM opensearchproject/opensearch:$OPENSEARCH_VERSION 40 | 41 | ARG OPENSEARCH_VERSION 42 | ARG COCCOC_INSTALL_PATH=/usr/local 43 | ENV COCCOC_DICT_PATH=$COCCOC_INSTALL_PATH/share/tokenizer/dicts 44 | 45 | RUN echo "Installing analysis-vietnamese plugin" 46 | COPY --from=builder $COCCOC_INSTALL_PATH/lib/libcoccoc_tokenizer_jni.so /usr/lib 47 | COPY --from=builder $COCCOC_DICT_PATH $COCCOC_DICT_PATH 48 | COPY --from=builder /tmp/opensearch-analysis-vietnamese/target/releases/opensearch-analysis-vietnamese-$OPENSEARCH_VERSION.zip / 49 | RUN echo "Y" | /usr/share/opensearch/bin/opensearch-plugin install --batch file:///opensearch-analysis-vietnamese-$OPENSEARCH_VERSION.zip 50 | -------------------------------------------------------------------------------- /appliances/sonar-cli/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM openjdk:11-jre-slim 2 | 3 | ENV DEBIAN_FRONTEND=noninteractive 4 | RUN apt-get update && apt-get install -y --no-install-recommends \ 5 | curl \ 6 | dirmngr \ 7 | gnupg2 \ 8 | nodejs \ 9 | unzip \ 10 | && apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ 11 | 12 | ENV SONARQUBE_SCANNER_VERSION "4.3.0.2102" 13 | 14 | RUN curl -sSO https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-$SONARQUBE_SCANNER_VERSION-linux.zip \ 15 | && curl -sSO https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-$SONARQUBE_SCANNER_VERSION-linux.zip.asc \ 16 | && gpg --keyserver hkp://keyserver.ubuntu.com --recv-keys CFCA4A29D26468DE \ 17 | && gpg --verify sonar-scanner-cli-$SONARQUBE_SCANNER_VERSION-linux.zip.asc \ 18 | && unzip sonar-scanner-cli-$SONARQUBE_SCANNER_VERSION-linux.zip \ 19 | && rm sonar-scanner-cli-$SONARQUBE_SCANNER_VERSION-linux.zip* \ 20 | && mv sonar-scanner-$SONARQUBE_SCANNER_VERSION-linux sonar-scanner \ 21 | && sed -i 's/use_embedded_jre=true/use_embedded_jre=false/g' /sonar-scanner/bin/sonar-scanner 22 | 23 | ENV PATH "/sonar-scanner/bin:$PATH" 24 | 25 | # SonarQube Scanner sometimes relies on matching absolute paths in coverage reports, 26 | # so we create common paths we've used in projects, but just default to /usr/src/app. 27 | RUN mkdir -p /app /src 28 | WORKDIR /usr/src/app 29 | 30 | ENTRYPOINT ["sonar-scanner"] 31 | -------------------------------------------------------------------------------- /appliances/sonar-cli/README.md: -------------------------------------------------------------------------------- 1 | # SonarQube Scanner CLI 2 | 3 | Docker image containing [SonarQube Scanner][scanner], allowing easy use from CI 4 | build systems. 5 | 6 | [scanner]: https://docs.sonarqube.org/display/SCAN/Analyzing+with+SonarQube+Scanner 7 | 8 | ## Usage 9 | 10 | Create your project in SonarQube, along with a token to configure with CI. 11 | 12 | Configure your `sonar-project.properties` in your project's root directory: 13 | 14 | ``` 15 | sonar.projectKey=my-project 16 | sonar.sources=app,config,db,lib 17 | sonar.ruby.coverage.reportPaths=coverage/.resultset.json 18 | ``` 19 | 20 | If you're using Jenkins pipelines, add your project token to your Jenkins 21 | credentials store, then load that token in your pipeline stage like so: 22 | 23 | ``` 24 | stage('SonarQube') { 25 | when { environment name: "GERRIT_EVENT_TYPE", value: "change-merged" } 26 | environment { SONAR_TOKEN = credentials('SONAR_TOKEN') } 27 | steps { 28 | sh ''' 29 | docker run --rm \ 30 | -v `pwd`:/usr/src/app \ 31 | -v coverage:/usr/src/app/coverage \ 32 | instructure/sonar-cli \ 33 | -Dsonar.host.url=https://sonarqube.core.inseng.net \ 34 | -Dsonar.login=$SONAR_TOKEN \ 35 | -Dsonar.projectBaseDir=/usr/src/app \ 36 | -Dsonar.working.directory=/tmp 37 | ''' 38 | } 39 | } 40 | ``` 41 | 42 | Note: Setting `sonar.working.directory` to `/tmp` prevents the scanner from 43 | writing `.scannerwork` intermediate files to your bind-mounted volume (which 44 | would result in `root`-owned files in your Jenkins working directory). This 45 | is also why it's necessary to configure `sonar.projectBaseDir`. 46 | -------------------------------------------------------------------------------- /appliances/tx/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM python:3.5-alpine 2 | 3 | ENV TRANSIFEX_CLIENT_VERSION 0.12.4 4 | RUN pip install "transifex-client==$TRANSIFEX_CLIENT_VERSION" 5 | 6 | RUN mkdir -p /app 7 | WORKDIR /app 8 | 9 | ENTRYPOINT ["tx"] 10 | -------------------------------------------------------------------------------- /appliances/tx/README.md: -------------------------------------------------------------------------------- 1 | # Transifex Client 2 | 3 | A docker container appliance with the [Transifex client][tx] installed. 4 | 5 | [tx]: https://docs.transifex.com/client/introduction 6 | 7 | This container wraps the client as the entrypoint. You typically want to run 8 | this container directly, rather than adding it to docker-compose. 9 | 10 | You should mount your local `~/.transifexrc` config file into the container so 11 | it can use your credentials. For example, if you have an application (with your 12 | `.tx/config` file) in the current directory, and you want to pull down new 13 | translations, you can run: 14 | 15 | ```sh 16 | docker run --rm -v "$HOME/.transifexrc:/app/.transifexrc" \ 17 | -v "`pwd`:/app" instructure/tx --debug pull --all 18 | ``` 19 | -------------------------------------------------------------------------------- /appliances/zeppelin/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM instructure/spark:2.1-hadoop2.7 2 | 3 | ENV ZEPPELIN_VERSION 0.7.0 4 | 5 | ENV ZEPPELIN_PORT 8080 6 | ENV ZEPPELIN_HOME /usr/zeppelin 7 | ENV ZEPPELIN_CONF_DIR $ZEPPELIN_HOME/conf 8 | ENV ZEPPELIN_NOTEBOOK_DIR $ZEPPELIN_HOME/notebook 9 | 10 | USER root 11 | 12 | WORKDIR /root 13 | RUN curl -sS http://apache.cs.utah.edu/zeppelin/zeppelin-${ZEPPELIN_VERSION}/zeppelin-${ZEPPELIN_VERSION}-bin-netinst.tgz | tar -xzf - && \ 14 | mv /root/zeppelin* $ZEPPELIN_HOME && \ 15 | mkdir -p $ZEPPELIN_HOME/logs \ 16 | $ZEPPELIN_HOME/run && \ 17 | chown -R docker:docker $ZEPPELIN_HOME && \ 18 | rm -rf /root/zeppelin* 19 | 20 | USER docker 21 | WORKDIR $ZEPPELIN_HOME 22 | CMD ["bin/zeppelin.sh"] 23 | -------------------------------------------------------------------------------- /auto-update.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | import subprocess 3 | from pathlib import Path 4 | 5 | import requests 6 | from ruamel.yaml import YAML 7 | 8 | 9 | def main(): 10 | update_golang() 11 | 12 | 13 | def update_golang(): 14 | new_golang_versions = requests.get("https://go.dev/dl/?mode=json").json() 15 | 16 | yaml = YAML() 17 | yaml.preserve_quotes = True 18 | yaml.sequence_dash_offset = 2 19 | 20 | manifest_file = Path(__file__).parent.joinpath('manifest.yml').absolute() 21 | with open(manifest_file) as f: 22 | manifest = yaml.load(f) 23 | 24 | for v in new_golang_versions: 25 | files = v['files'] 26 | candidates = [f for f in files if f['os'] 27 | == 'linux' and f['arch'] == 'amd64'] 28 | if len(candidates) != 1: 29 | msg = f"Expected 1 candidate, got {len(candidates)}: {candidates}" 30 | raise Exception(msg) 31 | 32 | go_file = candidates[0] 33 | 34 | full_version = v['version'][2:] 35 | minor_version = full_version.rsplit('.', 1)[0] 36 | 37 | manifest['golang']['versions'][minor_version] = { 38 | 'full_version': full_version, 39 | 'package_sha': go_file['sha256'] 40 | } 41 | 42 | with open(manifest_file, 'w') as f: 43 | yaml.dump(manifest, f) 44 | 45 | p = subprocess.Popen(['rake', 'generate:golang']) 46 | p.communicate() 47 | rc = p.returncode 48 | if rc != 0: 49 | msg = f"Failed to update golang: 'rake generate:golang' returned {rc}" 50 | raise Exception(msg) 51 | 52 | 53 | if __name__ == '__main__': 54 | main() 55 | -------------------------------------------------------------------------------- /ci/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM ruby:alpine 2 | 3 | RUN apk --no-cache add git \ 4 | && gem install bundler 5 | 6 | WORKDIR / 7 | 8 | COPY Gemfile* . 9 | 10 | RUN bundle install 11 | 12 | COPY . ./ 13 | -------------------------------------------------------------------------------- /ci/docker-manifest.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | EXIT_CODE=0 4 | MANIFEST_RESULT=$(docker manifest "$@" 2>&1) || EXIT_CODE=$? 5 | 6 | if [[ $MANIFEST_RESULT =~ (no such manifest) ]]; then 7 | EXIT_CODE=0 8 | elif [[ $MANIFEST_RESULT =~ (unsupported manifest format) ]]; then 9 | sleep 10 10 | 11 | EXIT_CODE=0 12 | MANIFEST_RESULT=$(docker manifest "$@" 2>&1) || EXIT_CODE=$? 13 | fi 14 | 15 | if [[ "$EXIT_CODE" = "0" ]]; then 16 | echo $MANIFEST_RESULT 17 | fi 18 | 19 | exit $EXIT_CODE 20 | -------------------------------------------------------------------------------- /ci/get-cache-layers.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | pushd $1 > /dev/null 4 | 5 | readarray -t MANIFEST_DIGESTS < <( cat index.json | jq -r '.manifests[].digest' ) 6 | OUTPUT=() 7 | 8 | for manifestDigest in "${MANIFEST_DIGESTS[@]}"; do 9 | manifestPath=${manifestDigest/:/\/} 10 | 11 | readarray -t manifestLayers < <( cat "blobs/${manifestPath}" | jq -r '.layers[] | .digest' | sort -) 12 | OUTPUT+=(${manifestLayers[@]}) 13 | done 14 | 15 | SORTED_OUTPUT=( $(sort <<< "${OUTPUT[@]}") ) 16 | 17 | for outputLine in "${SORTED_OUTPUT[@]}"; do 18 | echo "${outputLine}" 19 | done 20 | 21 | popd > /dev/null 22 | -------------------------------------------------------------------------------- /core/README.md: -------------------------------------------------------------------------------- 1 | # Introduction 2 | The official base image for Instructure official generic Docker setups. If 3 | You're looking for a tabula rasa look no further, but if you're interested 4 | in running a basic ruby app or a ruby web app we suggest you take a look 5 | at `instructure-ruby` and `instructure-ruby-passenger` respectively. 6 | -------------------------------------------------------------------------------- /core/bionic-slim/Dockerfile: -------------------------------------------------------------------------------- 1 | ARG ROOT_PATH=instructure 2 | FROM ${ROOT_PATH}/tini:v0.19.0 AS tini 3 | FROM ubuntu:bionic 4 | MAINTAINER Instructure 5 | 6 | ENV DEBIAN_FRONTEND=noninteractive 7 | RUN sed -i -e 's/http:\/\/archive\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.archive\.ubuntu\.com\//' /etc/apt/sources.list \ 8 | && sed -i -e 's/http:\/\/ports\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.ports\.ubuntu\.com\//' /etc/apt/sources.list 9 | RUN apt-get update \ 10 | && apt-get install -y --no-install-recommends \ 11 | apt-transport-https \ 12 | ca-certificates \ 13 | curl \ 14 | language-pack-en \ 15 | locales \ 16 | gnupg \ 17 | adduser \ 18 | && apt-get clean \ 19 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 20 | && addgroup --gid 9999 docker \ 21 | && adduser --uid 9999 --gid 9999 --disabled-password --gecos "Docker User" docker \ 22 | && usermod -L docker 23 | 24 | ## Ensure UTF-8 locale 25 | RUN locale-gen en_US.UTF-8 26 | ENV LANG en_US.UTF-8 27 | ENV LC_ALL en_US.UTF-8 28 | RUN dpkg-reconfigure locales 29 | 30 | # Install Tini for init use (reaps defunct processes and forwards signals) 31 | COPY --from=tini /tini /tini 32 | 33 | # Switch to the 'docker' user 34 | USER docker 35 | -------------------------------------------------------------------------------- /core/bionic/Dockerfile: -------------------------------------------------------------------------------- 1 | ARG ROOT_PATH=instructure 2 | FROM ${ROOT_PATH}/tini:v0.19.0 AS tini 3 | FROM ubuntu:bionic 4 | MAINTAINER Instructure 5 | 6 | ENV DEBIAN_FRONTEND=noninteractive 7 | RUN sed -i -e 's/http:\/\/archive\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.archive\.ubuntu\.com\//' /etc/apt/sources.list \ 8 | && sed -i -e 's/http:\/\/ports\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.ports\.ubuntu\.com\//' /etc/apt/sources.list 9 | RUN apt-get update \ 10 | && apt-get install -y --no-install-recommends \ 11 | apt-transport-https \ 12 | ca-certificates \ 13 | curl \ 14 | language-pack-en \ 15 | locales \ 16 | gnupg \ 17 | adduser \ 18 | && apt-get install -y --no-install-recommends \ 19 | build-essential \ 20 | git \ 21 | psmisc \ 22 | python \ 23 | software-properties-common \ 24 | tzdata \ 25 | # gnupg2 and dirmngr will attempt to use IPv6 if it's enabled in Docker, even 26 | # if the container doesn't have an IPv6 address (this is true on Docker Hub). 27 | && mkdir ~/.gnupg && echo "disable-ipv6" >> ~/.gnupg/dirmngr.conf \ 28 | && apt-get clean \ 29 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 30 | && addgroup --gid 9999 docker \ 31 | && adduser --uid 9999 --gid 9999 --disabled-password --gecos "Docker User" docker \ 32 | && usermod -L docker 33 | 34 | ## Ensure UTF-8 locale 35 | RUN locale-gen en_US.UTF-8 36 | ENV LANG en_US.UTF-8 37 | ENV LC_ALL en_US.UTF-8 38 | RUN dpkg-reconfigure locales 39 | 40 | # Install Tini for init use (reaps defunct processes and forwards signals) 41 | COPY --from=tini /tini /tini 42 | 43 | # Switch to the 'docker' user 44 | USER docker 45 | -------------------------------------------------------------------------------- /core/focal/Dockerfile: -------------------------------------------------------------------------------- 1 | ARG ROOT_PATH=instructure 2 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/tini:v0.19.0 AS tini 3 | FROM --platform=${TARGETPLATFORM} ubuntu:focal 4 | MAINTAINER Instructure 5 | 6 | ENV DEBIAN_FRONTEND=noninteractive 7 | RUN sed -i -e 's/http:\/\/archive\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.archive\.ubuntu\.com\//' /etc/apt/sources.list \ 8 | && sed -i -e 's/http:\/\/ports\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.ports\.ubuntu\.com\//' /etc/apt/sources.list 9 | RUN apt-get update \ 10 | && apt-get install -y --no-install-recommends \ 11 | apt-transport-https \ 12 | ca-certificates \ 13 | curl \ 14 | language-pack-en \ 15 | locales \ 16 | gnupg \ 17 | adduser \ 18 | && apt-get clean \ 19 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 20 | && addgroup --gid 9999 docker \ 21 | && adduser --uid 9999 --gid 9999 --disabled-password --gecos "Docker User" docker \ 22 | && usermod -L docker 23 | 24 | ## Ensure UTF-8 locale 25 | RUN locale-gen en_US.UTF-8 26 | ENV LANG en_US.UTF-8 27 | ENV LC_ALL en_US.UTF-8 28 | RUN dpkg-reconfigure locales 29 | 30 | # Install Tini for init use (reaps defunct processes and forwards signals) 31 | COPY --from=tini /tini /tini 32 | 33 | # Switch to the 'docker' user 34 | USER docker 35 | -------------------------------------------------------------------------------- /core/jammy/Dockerfile: -------------------------------------------------------------------------------- 1 | ARG ROOT_PATH=instructure 2 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/tini:v0.19.0 AS tini 3 | FROM --platform=${TARGETPLATFORM} ubuntu:jammy 4 | MAINTAINER Instructure 5 | 6 | ENV DEBIAN_FRONTEND=noninteractive 7 | RUN sed -i -e 's/http:\/\/archive\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.archive\.ubuntu\.com\//' /etc/apt/sources.list \ 8 | && sed -i -e 's/http:\/\/ports\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.ports\.ubuntu\.com\//' /etc/apt/sources.list 9 | RUN apt-get update \ 10 | && apt-get install -y --no-install-recommends \ 11 | apt-transport-https \ 12 | ca-certificates \ 13 | curl \ 14 | language-pack-en \ 15 | locales \ 16 | gnupg \ 17 | adduser \ 18 | && apt-get clean \ 19 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 20 | && addgroup --gid 9999 docker \ 21 | && adduser --uid 9999 --gid 9999 --disabled-password --gecos "Docker User" docker \ 22 | && usermod -L docker 23 | 24 | ## Ensure UTF-8 locale 25 | RUN locale-gen en_US.UTF-8 26 | ENV LANG en_US.UTF-8 27 | ENV LC_ALL en_US.UTF-8 28 | RUN dpkg-reconfigure locales 29 | 30 | # Install Tini for init use (reaps defunct processes and forwards signals) 31 | COPY --from=tini /tini /tini 32 | 33 | # Switch to the 'docker' user 34 | USER docker 35 | -------------------------------------------------------------------------------- /core/noble/Dockerfile: -------------------------------------------------------------------------------- 1 | ARG ROOT_PATH=instructure 2 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/tini:v0.19.0 AS tini 3 | FROM --platform=${TARGETPLATFORM} ubuntu:noble 4 | MAINTAINER Instructure 5 | 6 | ENV DEBIAN_FRONTEND=noninteractive 7 | RUN sed -i -e 's/http:\/\/archive\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.archive\.ubuntu\.com\//' /etc/apt/sources.list \ 8 | && sed -i -e 's/http:\/\/ports\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.ports\.ubuntu\.com\//' /etc/apt/sources.list 9 | RUN apt-get update \ 10 | && apt-get install -y --no-install-recommends \ 11 | apt-transport-https \ 12 | ca-certificates \ 13 | curl \ 14 | language-pack-en \ 15 | locales \ 16 | gnupg \ 17 | adduser \ 18 | && apt-get clean \ 19 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 20 | && addgroup --gid 9999 docker \ 21 | && adduser --uid 9999 --gid 9999 --disabled-password --gecos "Docker User" docker \ 22 | && usermod -L docker 23 | 24 | ## Ensure UTF-8 locale 25 | RUN locale-gen en_US.UTF-8 26 | ENV LANG en_US.UTF-8 27 | ENV LC_ALL en_US.UTF-8 28 | RUN dpkg-reconfigure locales 29 | 30 | # Install Tini for init use (reaps defunct processes and forwards signals) 31 | COPY --from=tini /tini /tini 32 | 33 | # Switch to the 'docker' user 34 | USER docker 35 | -------------------------------------------------------------------------------- /core/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= from_image('tini:v0.19.0') %> AS tini 2 | <%= from_image(base_image) %> 3 | MAINTAINER Instructure 4 | 5 | ENV DEBIAN_FRONTEND=noninteractive 6 | RUN sed -i -e 's/http:\/\/archive\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.archive\.ubuntu\.com\//' /etc/apt/sources.list \ 7 | && sed -i -e 's/http:\/\/ports\.ubuntu\.com\//http:\/\/us-east-1\.ec2\.ports\.ubuntu\.com\//' /etc/apt/sources.list 8 | RUN apt-get update \ 9 | && apt-get install -y --no-install-recommends \ 10 | apt-transport-https \ 11 | ca-certificates \ 12 | curl \ 13 | language-pack-en \ 14 | locales \ 15 | gnupg \ 16 | adduser \ 17 | <% if flavor == 'fat' -%> 18 | && apt-get install -y --no-install-recommends \ 19 | build-essential \ 20 | git \ 21 | psmisc \ 22 | python \ 23 | software-properties-common \ 24 | tzdata \ 25 | # gnupg2 and dirmngr will attempt to use IPv6 if it's enabled in Docker, even 26 | # if the container doesn't have an IPv6 address (this is true on Docker Hub). 27 | && mkdir ~/.gnupg && echo "disable-ipv6" >> ~/.gnupg/dirmngr.conf \ 28 | <% end -%> 29 | && apt-get clean \ 30 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 31 | && addgroup --gid 9999 docker \ 32 | && adduser --uid 9999 --gid 9999 --disabled-password --gecos "Docker User" docker \ 33 | && usermod -L docker 34 | 35 | ## Ensure UTF-8 locale 36 | RUN locale-gen en_US.UTF-8 37 | ENV LANG en_US.UTF-8 38 | ENV LC_ALL en_US.UTF-8 39 | RUN dpkg-reconfigure locales 40 | 41 | # Install Tini for init use (reaps defunct processes and forwards signals) 42 | COPY --from=tini /tini /tini 43 | 44 | # Switch to the 'docker' user 45 | USER docker 46 | -------------------------------------------------------------------------------- /corretto/17/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:corretto` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | RUN apt-get update && \ 12 | apt-get install -y software-properties-common && \ 13 | apt-get install wget && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 16 | RUN wget -O- https://apt.corretto.aws/corretto.key | apt-key add - && \ 17 | add-apt-repository 'deb https://apt.corretto.aws stable main' 18 | RUN apt-get update && \ 19 | apt-get install -y --no-install-recommends java-17-amazon-corretto-jdk && \ 20 | apt-get clean && \ 21 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 22 | 23 | USER docker 24 | -------------------------------------------------------------------------------- /corretto/20/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:corretto` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | RUN apt-get update && \ 12 | apt-get install -y software-properties-common && \ 13 | apt-get install wget && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 16 | RUN wget -O- https://apt.corretto.aws/corretto.key | apt-key add - && \ 17 | add-apt-repository 'deb https://apt.corretto.aws stable main' 18 | RUN apt-get update && \ 19 | apt-get install -y --no-install-recommends java-20-amazon-corretto-jdk && \ 20 | apt-get clean && \ 21 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 22 | 23 | USER docker 24 | -------------------------------------------------------------------------------- /corretto/21/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:corretto` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | RUN apt-get update && \ 12 | apt-get install -y software-properties-common && \ 13 | apt-get install wget && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 16 | RUN wget -O- https://apt.corretto.aws/corretto.key | apt-key add - && \ 17 | add-apt-repository 'deb https://apt.corretto.aws stable main' 18 | RUN apt-get update && \ 19 | apt-get install -y --no-install-recommends java-21-amazon-corretto-jdk && \ 20 | apt-get clean && \ 21 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 22 | 23 | USER docker 24 | -------------------------------------------------------------------------------- /corretto/22/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:corretto` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | RUN apt-get update && \ 12 | apt-get install -y software-properties-common && \ 13 | apt-get install wget && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 16 | RUN wget -O- https://apt.corretto.aws/corretto.key | apt-key add - && \ 17 | add-apt-repository 'deb https://apt.corretto.aws stable main' 18 | RUN apt-get update && \ 19 | apt-get install -y --no-install-recommends java-22-amazon-corretto-jdk && \ 20 | apt-get clean && \ 21 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 22 | 23 | USER docker 24 | -------------------------------------------------------------------------------- /corretto/24/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:corretto` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | RUN apt-get update && \ 12 | apt-get install -y software-properties-common && \ 13 | apt-get install wget && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 16 | RUN wget -O- https://apt.corretto.aws/corretto.key | apt-key add - && \ 17 | add-apt-repository 'deb https://apt.corretto.aws stable main' 18 | RUN apt-get update && \ 19 | apt-get install -y --no-install-recommends java-24-amazon-corretto-jdk && \ 20 | apt-get clean && \ 21 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 22 | 23 | USER docker 24 | -------------------------------------------------------------------------------- /corretto/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | <%= from_image(base_image) %> 3 | 4 | MAINTAINER Instructure 5 | 6 | USER root 7 | RUN apt-get update && \ 8 | apt-get install -y software-properties-common && \ 9 | apt-get install wget && \ 10 | apt-get clean && \ 11 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 12 | RUN wget -O- https://apt.corretto.aws/corretto.key | apt-key add - && \ 13 | add-apt-repository 'deb https://apt.corretto.aws stable main' 14 | RUN apt-get update && \ 15 | apt-get install -y --no-install-recommends java-<%= java_version %>-amazon-corretto-jdk && \ 16 | apt-get clean && \ 17 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 18 | 19 | USER docker 20 | -------------------------------------------------------------------------------- /golang/1.21/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:golang` 4 | 5 | FROM instructure/core:jammy 6 | MAINTAINER Instructure 7 | 8 | USER root 9 | 10 | ENV GOLANG_VERSION 1.21.13 11 | ENV GOLANG_DOWNLOAD_URL https://storage.googleapis.com/golang/go$GOLANG_VERSION.linux-amd64.tar.gz 12 | ENV GOLANG_DOWNLOAD_SHA256 502fc16d5910562461e6a6631fb6377de2322aad7304bf2bcd23500ba9dab4a7 13 | 14 | RUN curl -fsSL "$GOLANG_DOWNLOAD_URL" -o golang.tar.gz \ 15 | && echo "$GOLANG_DOWNLOAD_SHA256 golang.tar.gz" | sha256sum -c - \ 16 | && tar -C /usr/local -xzf golang.tar.gz \ 17 | && rm golang.tar.gz 18 | 19 | # For private gomodules that install via git, and to support Makefiles 20 | RUN apt-get update \ 21 | && apt-get install -y openssh-client git make \ 22 | && apt-get clean 23 | RUN ssh-keyscan -p 29418 -H gerrit.instructure.com 2>/dev/null >> /etc/ssh/ssh_known_hosts 24 | ENV GOPRIVATE gerrit.instructure.com,github.com/instructure 25 | 26 | ENV GOPATH /go 27 | ENV PATH $GOPATH/bin:/usr/local/go/bin:$PATH 28 | ENV SRCPATH $GOPATH/src 29 | RUN mkdir -p $SRCPATH && chown -R docker:docker $GOPATH 30 | WORKDIR $SRCPATH 31 | 32 | USER docker 33 | -------------------------------------------------------------------------------- /golang/1.22/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:golang` 4 | 5 | FROM instructure/core:jammy 6 | MAINTAINER Instructure 7 | 8 | USER root 9 | 10 | ENV GOLANG_VERSION 1.22.6 11 | ENV GOLANG_DOWNLOAD_URL https://storage.googleapis.com/golang/go$GOLANG_VERSION.linux-amd64.tar.gz 12 | ENV GOLANG_DOWNLOAD_SHA256 999805bed7d9039ec3da1a53bfbcafc13e367da52aa823cb60b68ba22d44c616 13 | 14 | RUN curl -fsSL "$GOLANG_DOWNLOAD_URL" -o golang.tar.gz \ 15 | && echo "$GOLANG_DOWNLOAD_SHA256 golang.tar.gz" | sha256sum -c - \ 16 | && tar -C /usr/local -xzf golang.tar.gz \ 17 | && rm golang.tar.gz 18 | 19 | # For private gomodules that install via git, and to support Makefiles 20 | RUN apt-get update \ 21 | && apt-get install -y openssh-client git make \ 22 | && apt-get clean 23 | RUN ssh-keyscan -p 29418 -H gerrit.instructure.com 2>/dev/null >> /etc/ssh/ssh_known_hosts 24 | ENV GOPRIVATE gerrit.instructure.com,github.com/instructure 25 | 26 | ENV GOPATH /go 27 | ENV PATH $GOPATH/bin:/usr/local/go/bin:$PATH 28 | ENV SRCPATH $GOPATH/src 29 | RUN mkdir -p $SRCPATH && chown -R docker:docker $GOPATH 30 | WORKDIR $SRCPATH 31 | 32 | USER docker 33 | -------------------------------------------------------------------------------- /golang/1.23/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:golang` 4 | 5 | FROM instructure/core:jammy 6 | MAINTAINER Instructure 7 | 8 | USER root 9 | 10 | ENV GOLANG_VERSION 1.23.9 11 | ENV GOLANG_DOWNLOAD_URL https://storage.googleapis.com/golang/go$GOLANG_VERSION.linux-amd64.tar.gz 12 | ENV GOLANG_DOWNLOAD_SHA256 de03e45d7a076c06baaa9618d42b3b6a0561125b87f6041c6397680a71e5bb26 13 | 14 | RUN curl -fsSL "$GOLANG_DOWNLOAD_URL" -o golang.tar.gz \ 15 | && echo "$GOLANG_DOWNLOAD_SHA256 golang.tar.gz" | sha256sum -c - \ 16 | && tar -C /usr/local -xzf golang.tar.gz \ 17 | && rm golang.tar.gz 18 | 19 | # For private gomodules that install via git, and to support Makefiles 20 | RUN apt-get update \ 21 | && apt-get install -y openssh-client git make \ 22 | && apt-get clean 23 | RUN ssh-keyscan -p 29418 -H gerrit.instructure.com 2>/dev/null >> /etc/ssh/ssh_known_hosts 24 | ENV GOPRIVATE gerrit.instructure.com,github.com/instructure 25 | 26 | ENV GOPATH /go 27 | ENV PATH $GOPATH/bin:/usr/local/go/bin:$PATH 28 | ENV SRCPATH $GOPATH/src 29 | RUN mkdir -p $SRCPATH && chown -R docker:docker $GOPATH 30 | WORKDIR $SRCPATH 31 | 32 | USER docker 33 | -------------------------------------------------------------------------------- /golang/1.24/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:golang` 4 | 5 | FROM instructure/core:jammy 6 | MAINTAINER Instructure 7 | 8 | USER root 9 | 10 | ENV GOLANG_VERSION 1.24.3 11 | ENV GOLANG_DOWNLOAD_URL https://storage.googleapis.com/golang/go$GOLANG_VERSION.linux-amd64.tar.gz 12 | ENV GOLANG_DOWNLOAD_SHA256 3333f6ea53afa971e9078895eaa4ac7204a8c6b5c68c10e6bc9a33e8e391bdd8 13 | 14 | RUN curl -fsSL "$GOLANG_DOWNLOAD_URL" -o golang.tar.gz \ 15 | && echo "$GOLANG_DOWNLOAD_SHA256 golang.tar.gz" | sha256sum -c - \ 16 | && tar -C /usr/local -xzf golang.tar.gz \ 17 | && rm golang.tar.gz 18 | 19 | # For private gomodules that install via git, and to support Makefiles 20 | RUN apt-get update \ 21 | && apt-get install -y openssh-client git make \ 22 | && apt-get clean 23 | RUN ssh-keyscan -p 29418 -H gerrit.instructure.com 2>/dev/null >> /etc/ssh/ssh_known_hosts 24 | ENV GOPRIVATE gerrit.instructure.com,github.com/instructure 25 | 26 | ENV GOPATH /go 27 | ENV PATH $GOPATH/bin:/usr/local/go/bin:$PATH 28 | ENV SRCPATH $GOPATH/src 29 | RUN mkdir -p $SRCPATH && chown -R docker:docker $GOPATH 30 | WORKDIR $SRCPATH 31 | 32 | USER docker 33 | -------------------------------------------------------------------------------- /golang/README.md: -------------------------------------------------------------------------------- 1 | # golang 2 | 3 | `GOPATH` is set to `/go`, and a `SRCPATH` env var is available, set to `/go/src`. 4 | 5 | Make sure to ADD your source into a dir under `SRCPATH` named after your app, or 6 | you'll run into problems finding dependencies. Specifically, don't use 7 | `/usr/local/src`. 8 | 9 | ## example 10 | 11 | ``` 12 | FROM instructure/golang:1.18 13 | 14 | RUN mkdir -p $SRCPATH/myapp 15 | WORKDIR $SRCPATH/myapp 16 | 17 | USER root 18 | COPY . . 19 | RUN chown -R docker:docker . 20 | USER docker 21 | RUN go install . 22 | 23 | CMD myapp 24 | ``` 25 | -------------------------------------------------------------------------------- /golang/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | FROM <%= base_image %> 3 | MAINTAINER Instructure 4 | 5 | USER root 6 | 7 | ENV GOLANG_VERSION <%= full_version %> 8 | ENV GOLANG_DOWNLOAD_URL https://storage.googleapis.com/golang/go$GOLANG_VERSION.linux-amd64.tar.gz 9 | ENV GOLANG_DOWNLOAD_SHA256 <%= package_sha %> 10 | 11 | RUN curl -fsSL "$GOLANG_DOWNLOAD_URL" -o golang.tar.gz \ 12 | && echo "$GOLANG_DOWNLOAD_SHA256 golang.tar.gz" | sha256sum -c - \ 13 | && tar -C /usr/local -xzf golang.tar.gz \ 14 | && rm golang.tar.gz 15 | 16 | <% has_private_gomods = Gem::Dependency.new('go', '>= 1.13') -%> 17 | <% if has_private_gomods.match?('go', full_version) -%> 18 | # For private gomodules that install via git, and to support Makefiles 19 | RUN apt-get update \ 20 | && apt-get install -y openssh-client git make \ 21 | && apt-get clean 22 | RUN ssh-keyscan -p 29418 -H gerrit.instructure.com 2>/dev/null >> /etc/ssh/ssh_known_hosts 23 | ENV GOPRIVATE gerrit.instructure.com,github.com/instructure 24 | <% end -%> 25 | 26 | ENV GOPATH /go 27 | ENV PATH $GOPATH/bin:/usr/local/go/bin:$PATH 28 | ENV SRCPATH $GOPATH/src 29 | RUN mkdir -p $SRCPATH && chown -R docker:docker $GOPATH 30 | WORKDIR $SRCPATH 31 | 32 | USER docker 33 | -------------------------------------------------------------------------------- /java/11-jre/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM ${ROOT_PATH}/core:bionic 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-11-jre && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/11/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM ${ROOT_PATH}/core:bionic 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-11-jdk && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/16-jre/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM ${ROOT_PATH}/core:focal 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-16-jre && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/16/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM ${ROOT_PATH}/core:focal 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-16-jdk && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/17-focal/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:focal 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-17-jdk && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/17-jre-focal/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:focal 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-17-jre && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/17-jre/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-17-jre && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/17/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-17-jdk && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/18-jre/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-18-jre && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/18/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-18-jdk && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/19-jre/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-19-jre && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/19/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:java` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | 8 | MAINTAINER Instructure 9 | 10 | USER root 11 | 12 | RUN apt-get update && \ 13 | apt-get install -y --no-install-recommends openjdk-19-jdk && \ 14 | apt-get clean && \ 15 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 16 | 17 | USER docker 18 | -------------------------------------------------------------------------------- /java/README.md: -------------------------------------------------------------------------------- 1 | # Java 2 | 3 | These are base docker images for building java applications. 4 | -------------------------------------------------------------------------------- /java/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | <%= from_image(base_image) %> 3 | 4 | MAINTAINER Instructure 5 | 6 | USER root 7 | 8 | RUN apt-get update && \ 9 | apt-get install -y --no-install-recommends openjdk-<%= java_version %>-<%= flavor %> && \ 10 | apt-get clean && \ 11 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ /var/cache/oracle* 12 | 13 | USER docker 14 | -------------------------------------------------------------------------------- /k8s-ci/README.md: -------------------------------------------------------------------------------- 1 | # Kubernetes CI tools 2 | 3 | Helper tools for common K8s CI tasks, to avoid rebuilding this image for each repo. 4 | -------------------------------------------------------------------------------- /k8s-ci/main/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=$BUILDPLATFORM public.ecr.aws/docker/library/alpine:3 AS helm-builder 2 | WORKDIR /tmp/helm 3 | ARG TARGETOS 4 | ARG TARGETARCH 5 | RUN wget https://get.helm.sh/helm-v3.14.0-$TARGETOS-$TARGETARCH.tar.gz -O helm.tar.gz \ 6 | && tar xvzf helm.tar.gz \ 7 | && mv $TARGETOS-$TARGETARCH/helm /helm \ 8 | && rm helm.tar.gz 9 | 10 | 11 | FROM --platform=$BUILDPLATFORM public.ecr.aws/docker/library/alpine:3 as kustomize-builder 12 | WORKDIR /tmp/kustomize 13 | ARG TARGETOS 14 | ARG TARGETARCH 15 | RUN wget https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize%2Fv5.3.0/kustomize_v5.3.0_${TARGETOS}_${TARGETARCH}.tar.gz -O kustomize.tar.gz \ 16 | && tar xvzf kustomize.tar.gz \ 17 | && mv kustomize /kustomize \ 18 | && rm kustomize.tar.gz 19 | 20 | 21 | # Currently only published under amd64, so we compile ourselves :/ 22 | FROM --platform=$BUILDPLATFORM public.ecr.aws/docker/library/golang:1.21 AS kube-linter-builder 23 | WORKDIR /src 24 | RUN git clone https://github.com/stackrox/kube-linter.git --branch v0.6.7 --depth 1 . \ 25 | && go mod download 26 | ARG TARGETARCH 27 | ARG TARGETOS 28 | RUN GOARCH=$TARGETARCH GOOS=$TARGETOS CGO_ENABLED=0 scripts/go-build.sh ./cmd/kube-linter \ 29 | && mv bin/$TARGETOS/kube-linter /kube-linter 30 | 31 | 32 | FROM --platform=$TARGETPLATFORM public.ecr.aws/docker/library/alpine:3 33 | 34 | RUN adduser -u9999 -g9999 -D -g "Docker User" docker \ 35 | && apk --no-cache add \ 36 | bash \ 37 | yamllint 38 | 39 | COPY bin/* /usr/bin/ 40 | COPY --from=kustomize-builder /kustomize /usr/bin/kustomize 41 | COPY --from=helm-builder /helm /usr/bin/helm 42 | COPY --from=kube-linter-builder /kube-linter /usr/bin/kube-linter 43 | 44 | WORKDIR /mnt 45 | 46 | USER docker 47 | -------------------------------------------------------------------------------- /k8s-ci/main/bin/kustomize-lint: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e 4 | set -o pipefail 5 | 6 | OVERLAY=${1:-.} 7 | 8 | die() { 9 | echo "$@" >&2 10 | exit 1 11 | } 12 | 13 | [[ -d "${OVERLAY}" ]] || die "'${OVERLAY}' is not a directory." 14 | 15 | set -x 16 | 17 | kustomize build "$1" | kube-linter lint - 18 | -------------------------------------------------------------------------------- /k8s-ci/template/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=$BUILDPLATFORM public.ecr.aws/docker/library/alpine:3 AS helm-builder 2 | WORKDIR /tmp/helm 3 | ARG TARGETOS 4 | ARG TARGETARCH 5 | RUN wget https://get.helm.sh/helm-<%= helm_version %>-$TARGETOS-$TARGETARCH.tar.gz -O helm.tar.gz \ 6 | && tar xvzf helm.tar.gz \ 7 | && mv $TARGETOS-$TARGETARCH/helm /helm \ 8 | && rm helm.tar.gz 9 | 10 | 11 | FROM --platform=$BUILDPLATFORM public.ecr.aws/docker/library/alpine:3 as kustomize-builder 12 | WORKDIR /tmp/kustomize 13 | ARG TARGETOS 14 | ARG TARGETARCH 15 | RUN wget https://github.com/kubernetes-sigs/kustomize/releases/download/kustomize%2F<%= kustomize_version %>/kustomize_<%= kustomize_version %>_${TARGETOS}_${TARGETARCH}.tar.gz -O kustomize.tar.gz \ 16 | && tar xvzf kustomize.tar.gz \ 17 | && mv kustomize /kustomize \ 18 | && rm kustomize.tar.gz 19 | 20 | 21 | # Currently only published under amd64, so we compile ourselves :/ 22 | FROM --platform=$BUILDPLATFORM public.ecr.aws/docker/library/golang:<%= kube_linter_go_version %> AS kube-linter-builder 23 | WORKDIR /src 24 | RUN git clone https://github.com/stackrox/kube-linter.git --branch <%= kube_linter_version %> --depth 1 . \ 25 | && go mod download 26 | ARG TARGETARCH 27 | ARG TARGETOS 28 | RUN GOARCH=$TARGETARCH GOOS=$TARGETOS CGO_ENABLED=0 scripts/go-build.sh ./cmd/kube-linter \ 29 | && mv bin/$TARGETOS/kube-linter /kube-linter 30 | 31 | 32 | FROM --platform=$TARGETPLATFORM public.ecr.aws/docker/library/alpine:3 33 | 34 | RUN adduser -u9999 -g9999 -D -g "Docker User" docker \ 35 | && apk --no-cache add \ 36 | bash \ 37 | yamllint 38 | 39 | COPY bin/* /usr/bin/ 40 | COPY --from=kustomize-builder /kustomize /usr/bin/kustomize 41 | COPY --from=helm-builder /helm /usr/bin/helm 42 | COPY --from=kube-linter-builder /kube-linter /usr/bin/kube-linter 43 | 44 | WORKDIR /mnt 45 | 46 | USER docker 47 | -------------------------------------------------------------------------------- /k8s-ci/template/bin/kustomize-lint: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -e 4 | set -o pipefail 5 | 6 | OVERLAY=${1:-.} 7 | 8 | die() { 9 | echo "$@" >&2 10 | exit 1 11 | } 12 | 13 | [[ -d "${OVERLAY}" ]] || die "'${OVERLAY}' is not a directory." 14 | 15 | set -x 16 | 17 | kustomize build "$1" | kube-linter lint - 18 | -------------------------------------------------------------------------------- /k8s-toolbox/1.25/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=$BUILDPLATFORM public.ecr.aws/docker/library/alpine:3.18 AS kubectl-builder 2 | 3 | ARG KUBECTL_VERSION=1.25.16 4 | ARG TARGETARCH 5 | ARG TARGETOS 6 | RUN wget "https://dl.k8s.io/release/v$KUBECTL_VERSION/bin/$TARGETOS/$TARGETARCH/kubectl" -O kubectl \ 7 | && expected="$(wget "https://dl.k8s.io/v$KUBECTL_VERSION/bin/$TARGETOS/$TARGETARCH/kubectl.sha256" -O -)" \ 8 | && echo "${expected} kubectl" | sha256sum -c \ 9 | && mv kubectl /kubectl 10 | 11 | FROM --platform=$TARGETPLATFORM public.ecr.aws/docker/library/alpine:3 12 | 13 | RUN apk --no-cache add \ 14 | aws-cli \ 15 | bash \ 16 | bind-tools \ 17 | coreutils \ 18 | curl \ 19 | date \ 20 | gawk \ 21 | grep \ 22 | jq \ 23 | less \ 24 | mandoc \ 25 | nmap \ 26 | nmap-ncat \ 27 | openssh-client \ 28 | openssl \ 29 | sed \ 30 | vim \ 31 | wget \ 32 | yq 33 | 34 | COPY --from=kubectl-builder /kubectl /bin/kubectl 35 | 36 | ENTRYPOINT ["/bin/bash"] 37 | -------------------------------------------------------------------------------- /k8s-toolbox/1.26/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=$BUILDPLATFORM public.ecr.aws/docker/library/alpine:3.18 AS kubectl-builder 2 | 3 | ARG KUBECTL_VERSION=1.26.13 4 | ARG TARGETARCH 5 | ARG TARGETOS 6 | RUN wget "https://dl.k8s.io/release/v$KUBECTL_VERSION/bin/$TARGETOS/$TARGETARCH/kubectl" -O kubectl \ 7 | && expected="$(wget "https://dl.k8s.io/v$KUBECTL_VERSION/bin/$TARGETOS/$TARGETARCH/kubectl.sha256" -O -)" \ 8 | && echo "${expected} kubectl" | sha256sum -c \ 9 | && mv kubectl /kubectl 10 | 11 | FROM --platform=$TARGETPLATFORM public.ecr.aws/docker/library/alpine:3 12 | 13 | RUN apk --no-cache add \ 14 | aws-cli \ 15 | bash \ 16 | bind-tools \ 17 | coreutils \ 18 | curl \ 19 | date \ 20 | gawk \ 21 | grep \ 22 | jq \ 23 | less \ 24 | mandoc \ 25 | nmap \ 26 | nmap-ncat \ 27 | openssh-client \ 28 | openssl \ 29 | sed \ 30 | vim \ 31 | wget \ 32 | yq 33 | 34 | COPY --from=kubectl-builder /kubectl /bin/kubectl 35 | 36 | ENTRYPOINT ["/bin/bash"] 37 | -------------------------------------------------------------------------------- /k8s-toolbox/template/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=$BUILDPLATFORM public.ecr.aws/docker/library/alpine:3.18 AS kubectl-builder 2 | 3 | ARG KUBECTL_VERSION=<%= kubectl_version %> 4 | ARG TARGETARCH 5 | ARG TARGETOS 6 | RUN wget "https://dl.k8s.io/release/v$KUBECTL_VERSION/bin/$TARGETOS/$TARGETARCH/kubectl" -O kubectl \ 7 | && expected="$(wget "https://dl.k8s.io/v$KUBECTL_VERSION/bin/$TARGETOS/$TARGETARCH/kubectl.sha256" -O -)" \ 8 | && echo "${expected} kubectl" | sha256sum -c \ 9 | && mv kubectl /kubectl 10 | 11 | FROM --platform=$TARGETPLATFORM <%= base_image %> 12 | 13 | RUN apk --no-cache add \ 14 | aws-cli \ 15 | bash \ 16 | bind-tools \ 17 | coreutils \ 18 | curl \ 19 | date \ 20 | gawk \ 21 | grep \ 22 | jq \ 23 | less \ 24 | mandoc \ 25 | nmap \ 26 | nmap-ncat \ 27 | openssh-client \ 28 | openssl \ 29 | sed \ 30 | vim \ 31 | wget \ 32 | yq 33 | 34 | COPY --from=kubectl-builder /kubectl /bin/kubectl 35 | 36 | ENTRYPOINT ["/bin/bash"] 37 | -------------------------------------------------------------------------------- /lib/generation_message.rb: -------------------------------------------------------------------------------- 1 | require 'erb' 2 | 3 | GENERATION_MESSAGE_TEMPLATE = <<-EOF 4 | # GENERATED FILE, DO NOT MODIFY! 5 | # To update this file please edit the relevant template and run the generation 6 | # task `<%= task_name.nil? ? 'rake generate:all' : \"rake \#{task_name}\" %>` 7 | EOF 8 | 9 | class GenerationMessage 10 | attr_reader :task_name 11 | def initialize(task_name = nil) 12 | @task_name = task_name 13 | end 14 | end 15 | 16 | ERB.new(GENERATION_MESSAGE_TEMPLATE).def_method(GenerationMessage, 'render') 17 | -------------------------------------------------------------------------------- /lib/template.rb: -------------------------------------------------------------------------------- 1 | require 'erb' 2 | require 'ostruct' 3 | 4 | class Template 5 | attr_reader :path, :erb 6 | 7 | def initialize(template_path) 8 | @path = template_path 9 | @erb = ERB.new(File.read(template_path), trim_mode: '-') 10 | end 11 | 12 | def filename 13 | File.basename(path) 14 | end 15 | 16 | def render(values) 17 | TemplateRenderer.new(self, TemplateMethods.new(values)) 18 | end 19 | 20 | def self.render_into_dockerfile(path, values) 21 | new(path).render(values).to_string 22 | end 23 | 24 | class TemplateMethods 25 | def initialize(values) 26 | @root_path_included = false 27 | @source = OpenStruct.new(values) 28 | end 29 | 30 | def method_missing(method, *args, &block) 31 | @source.send(method, *args, &block) 32 | end 33 | 34 | def from_image(base_image) 35 | image_name = base_image.is_a?(Hash) ? base_image['name'] : base_image 36 | image_source = base_image.is_a?(Hash) ? base_image['source'] : nil 37 | 38 | use_root_path = image_source != 'dockerhub' && !@root_path_included 39 | image_path = use_root_path ? "${ROOT_PATH}/#{image_name}" : image_name 40 | 41 | res = "" 42 | res << "ARG ROOT_PATH=instructure\n" if use_root_path 43 | res << if @source.multiarch 44 | "FROM --platform=${TARGETPLATFORM} #{image_path}" 45 | else 46 | "FROM #{image_path}" 47 | end 48 | 49 | @root_path_included ||= true 50 | res 51 | end 52 | end 53 | 54 | class TemplateRenderer 55 | def initialize(template, context) 56 | @template = template 57 | @context = context 58 | end 59 | 60 | def to(output_dir) 61 | output_path = File.join(output_dir, @template.filename) 62 | IO.write(output_path, to_string) 63 | end 64 | 65 | def to_string 66 | @template.erb.result(@context.instance_eval { binding }) 67 | end 68 | end 69 | end 70 | -------------------------------------------------------------------------------- /node-passenger/14/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/node:14 7 | MAINTAINER Instructure 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger focal main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | passenger \ 20 | sudo \ 21 | libnginx-mod-http-passenger \ 22 | && apt-get clean \ 23 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 24 | 25 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 26 | 27 | USER docker 28 | RUN passenger-config build-native-support 29 | 30 | # Nginx Configuration 31 | USER root 32 | 33 | COPY entrypoint /usr/src/entrypoint 34 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 35 | COPY main.d/* /usr/src/nginx/main.d/ 36 | RUN mkdir -p /usr/src/nginx/conf.d \ 37 | && mkdir -p /usr/src/nginx/location.d \ 38 | && mkdir -p /usr/src/nginx/main.d \ 39 | && mkdir -p /usr/src/nginx/server.d \ 40 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 41 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 42 | && chown docker:docker -R /usr/src/nginx 43 | 44 | USER docker 45 | 46 | EXPOSE 80 47 | CMD ["/tini", "--", "/usr/src/entrypoint"] 48 | -------------------------------------------------------------------------------- /node-passenger/14/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /node-passenger/14/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /node-passenger/16/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/node:16 7 | MAINTAINER Instructure 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger focal main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | passenger \ 20 | sudo \ 21 | libnginx-mod-http-passenger \ 22 | && apt-get clean \ 23 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 24 | 25 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 26 | 27 | USER docker 28 | RUN passenger-config build-native-support 29 | 30 | # Nginx Configuration 31 | USER root 32 | 33 | COPY entrypoint /usr/src/entrypoint 34 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 35 | COPY main.d/* /usr/src/nginx/main.d/ 36 | RUN mkdir -p /usr/src/nginx/conf.d \ 37 | && mkdir -p /usr/src/nginx/location.d \ 38 | && mkdir -p /usr/src/nginx/main.d \ 39 | && mkdir -p /usr/src/nginx/server.d \ 40 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 41 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 42 | && chown docker:docker -R /usr/src/nginx 43 | 44 | USER docker 45 | 46 | EXPOSE 80 47 | CMD ["/tini", "--", "/usr/src/entrypoint"] 48 | -------------------------------------------------------------------------------- /node-passenger/16/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /node-passenger/16/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /node-passenger/18/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/node:18 7 | MAINTAINER Instructure 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger jammy main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | passenger \ 20 | sudo \ 21 | libnginx-mod-http-passenger \ 22 | && apt-get clean \ 23 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 24 | 25 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 26 | 27 | USER docker 28 | RUN passenger-config build-native-support 29 | 30 | # Nginx Configuration 31 | USER root 32 | 33 | COPY entrypoint /usr/src/entrypoint 34 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 35 | COPY main.d/* /usr/src/nginx/main.d/ 36 | RUN mkdir -p /usr/src/nginx/conf.d \ 37 | && mkdir -p /usr/src/nginx/location.d \ 38 | && mkdir -p /usr/src/nginx/main.d \ 39 | && mkdir -p /usr/src/nginx/server.d \ 40 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 41 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 42 | && chown docker:docker -R /usr/src/nginx 43 | 44 | USER docker 45 | 46 | EXPOSE 80 47 | CMD ["/tini", "--", "/usr/src/entrypoint"] 48 | -------------------------------------------------------------------------------- /node-passenger/18/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /node-passenger/18/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /node-passenger/20/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/node:20 7 | MAINTAINER Instructure 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger jammy main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | passenger \ 20 | sudo \ 21 | libnginx-mod-http-passenger \ 22 | && apt-get clean \ 23 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 24 | 25 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 26 | 27 | USER docker 28 | RUN passenger-config build-native-support 29 | 30 | # Nginx Configuration 31 | USER root 32 | 33 | COPY entrypoint /usr/src/entrypoint 34 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 35 | COPY main.d/* /usr/src/nginx/main.d/ 36 | RUN mkdir -p /usr/src/nginx/conf.d \ 37 | && mkdir -p /usr/src/nginx/location.d \ 38 | && mkdir -p /usr/src/nginx/main.d \ 39 | && mkdir -p /usr/src/nginx/server.d \ 40 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 41 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 42 | && chown docker:docker -R /usr/src/nginx 43 | 44 | USER docker 45 | 46 | EXPOSE 80 47 | CMD ["/tini", "--", "/usr/src/entrypoint"] 48 | -------------------------------------------------------------------------------- /node-passenger/20/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /node-passenger/20/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /node-passenger/22/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/node:22 7 | MAINTAINER Instructure 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger jammy main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | passenger \ 20 | sudo \ 21 | libnginx-mod-http-passenger \ 22 | && apt-get clean \ 23 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 24 | 25 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 26 | 27 | USER docker 28 | RUN passenger-config build-native-support 29 | 30 | # Nginx Configuration 31 | USER root 32 | 33 | COPY entrypoint /usr/src/entrypoint 34 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 35 | COPY main.d/* /usr/src/nginx/main.d/ 36 | RUN mkdir -p /usr/src/nginx/conf.d \ 37 | && mkdir -p /usr/src/nginx/location.d \ 38 | && mkdir -p /usr/src/nginx/main.d \ 39 | && mkdir -p /usr/src/nginx/server.d \ 40 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 41 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 42 | && chown docker:docker -R /usr/src/nginx 43 | 44 | USER docker 45 | 46 | EXPOSE 80 47 | CMD ["/tini", "--", "/usr/src/entrypoint"] 48 | -------------------------------------------------------------------------------- /node-passenger/22/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /node-passenger/22/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /node-passenger/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | <%= from_image(base_image) %> 3 | MAINTAINER Instructure 4 | 5 | USER root 6 | 7 | # Install Nginx with Passenger from official repository 8 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 9 | && apt-get install -y apt-transport-https ca-certificates \ 10 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger <%= base_distro %> main > /etc/apt/sources.list.d/passenger.list 11 | 12 | RUN apt-get update \ 13 | && apt-get install -y --no-install-recommends \ 14 | nginx-extras \ 15 | passenger \ 16 | sudo \ 17 | libnginx-mod-http-passenger \ 18 | && apt-get clean \ 19 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 20 | 21 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 22 | 23 | USER docker 24 | RUN passenger-config build-native-support 25 | 26 | # Nginx Configuration 27 | USER root 28 | 29 | COPY entrypoint /usr/src/entrypoint 30 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 31 | COPY main.d/* /usr/src/nginx/main.d/ 32 | RUN mkdir -p /usr/src/nginx/conf.d \ 33 | && mkdir -p /usr/src/nginx/location.d \ 34 | && mkdir -p /usr/src/nginx/main.d \ 35 | && mkdir -p /usr/src/nginx/server.d \ 36 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 37 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 38 | && chown docker:docker -R /usr/src/nginx 39 | 40 | USER docker 41 | 42 | EXPOSE 80 43 | CMD ["/tini", "--", "/usr/src/entrypoint"] 44 | -------------------------------------------------------------------------------- /node-passenger/template/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /node-passenger/template/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /node-pm2-libvips/20/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node-pm2-libvips` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/node-pm2:20 7 | MAINTAINER Instructure 8 | 9 | USER root 10 | 11 | # Based on https://github.com/libvips/libvips/wiki/Build-for-Ubuntu 12 | 13 | RUN \ 14 | # Install build tools 15 | apt-get update && \ 16 | apt-get install -y \ 17 | build-essential \ 18 | pkg-config \ 19 | ninja-build \ 20 | python3-pip \ 21 | bc \ 22 | wget && \ 23 | pip3 install meson && \ 24 | 25 | # Install dependencies 26 | apt-get install -y \ 27 | libfftw3-dev \ 28 | libopenexr-dev \ 29 | libgsf-1-dev \ 30 | libglib2.0-dev \ 31 | liborc-dev \ 32 | libopenslide-dev \ 33 | libmatio-dev \ 34 | libwebp-dev \ 35 | libjpeg-turbo8-dev \ 36 | libexpat1-dev \ 37 | libexif-dev \ 38 | libtiff5-dev \ 39 | libcfitsio-dev \ 40 | libpoppler-glib-dev \ 41 | librsvg2-dev \ 42 | libpango1.0-dev \ 43 | libopenjp2-7-dev \ 44 | liblcms2-dev \ 45 | libimagequant-dev \ 46 | libheif-dev 47 | 48 | # Build libvips 49 | WORKDIR /tmp 50 | RUN \ 51 | curl -L -O https://github.com/libvips/libvips/releases/download/v8.16.0/vips-8.16.0.tar.xz && \ 52 | tar vxJf vips-8.16.0.tar.xz && \ 53 | cd vips-8.16.0 && \ 54 | meson setup build --libdir=lib --buildtype=release --reconfigure -Dheif=enabled -Dheif-module=enabled && \ 55 | cd build && \ 56 | meson compile && \ 57 | meson test && \ 58 | meson install && \ 59 | 60 | # Clean up 61 | # having yarn install sharp requires at least one of these 62 | #apt-get remove -y curl automake build-essential && \ 63 | apt-get autoremove -y && \ 64 | apt-get autoclean && \ 65 | apt-get clean && \ 66 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 67 | 68 | USER docker 69 | 70 | -------------------------------------------------------------------------------- /node-pm2-libvips/README.md: -------------------------------------------------------------------------------- 1 | # node-pm2-libvips 2 | 3 | The base node-pm2 image, but with `libvips` preinstalled for process management. 4 | -------------------------------------------------------------------------------- /node-pm2-libvips/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | <%= from_image(base_image) %> 3 | MAINTAINER Instructure 4 | 5 | USER root 6 | 7 | # Based on https://github.com/libvips/libvips/wiki/Build-for-Ubuntu 8 | 9 | RUN \ 10 | # Install build tools 11 | apt-get update && \ 12 | apt-get install -y \ 13 | build-essential \ 14 | pkg-config \ 15 | ninja-build \ 16 | python3-pip \ 17 | bc \ 18 | wget && \ 19 | pip3 install meson && \ 20 | 21 | # Install dependencies 22 | apt-get install -y \ 23 | libfftw3-dev \ 24 | libopenexr-dev \ 25 | libgsf-1-dev \ 26 | libglib2.0-dev \ 27 | liborc-dev \ 28 | libopenslide-dev \ 29 | libmatio-dev \ 30 | libwebp-dev \ 31 | libjpeg-turbo8-dev \ 32 | libexpat1-dev \ 33 | libexif-dev \ 34 | libtiff5-dev \ 35 | libcfitsio-dev \ 36 | libpoppler-glib-dev \ 37 | librsvg2-dev \ 38 | libpango1.0-dev \ 39 | libopenjp2-7-dev \ 40 | liblcms2-dev \ 41 | libimagequant-dev \ 42 | libheif-dev 43 | 44 | # Build libvips 45 | WORKDIR /tmp 46 | RUN \ 47 | curl -L -O https://github.com/libvips/libvips/releases/download/v<%= libvips_version %>/vips-<%= libvips_version %>.tar.xz && \ 48 | tar vxJf vips-<%= libvips_version %>.tar.xz && \ 49 | cd vips-<%= libvips_version %> && \ 50 | meson setup build --libdir=lib --buildtype=release --reconfigure -Dheif=enabled -Dheif-module=enabled && \ 51 | cd build && \ 52 | meson compile && \ 53 | meson test && \ 54 | meson install && \ 55 | 56 | # Clean up 57 | # having yarn install sharp requires at least one of these 58 | #apt-get remove -y curl automake build-essential && \ 59 | apt-get autoremove -y && \ 60 | apt-get autoclean && \ 61 | apt-get clean && \ 62 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 63 | 64 | USER docker 65 | 66 | -------------------------------------------------------------------------------- /node-pm2/14/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node-pm2` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/node:14 7 | MAINTAINER Instructure 8 | 9 | USER root 10 | 11 | # Install Nginx 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | # TODO can this be a non-passenger source? don't think we can take it out 15 | # because then we get nginx 1.10 instead of 1.14, and I'm not sure if 1.10 16 | # has the features we need 17 | && sh -c 'echo deb https://oss-binaries.phusionpassenger.com/apt/passenger focal main > /etc/apt/sources.list.d/passenger.list' \ 18 | && apt-get update \ 19 | && apt-get install -y --no-install-recommends \ 20 | nginx-extras libnginx-mod-http-headers-more-filter \ 21 | ruby \ 22 | sudo \ 23 | supervisor \ 24 | && apt-get clean \ 25 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 26 | 27 | RUN yarn global add pm2@5.3.0 28 | 29 | RUN mkdir -p /usr/src/supervisord/ \ 30 | && mkdir -p /usr/src/nginx/conf.d \ 31 | && mkdir -p /usr/src/nginx/location.d \ 32 | && mkdir -p /usr/src/nginx/main.d \ 33 | && mkdir -p /usr/src/nginx/server.d \ 34 | && mkdir -p /usr/src/app \ 35 | && mkdir -p /var/log/app \ 36 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 37 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 38 | && ln -sf /dev/stdout /var/log/app/output.log \ 39 | && ln -sf /dev/stderr /var/log/app/error.log 40 | 41 | COPY entrypoint /usr/src/entrypoint 42 | COPY supervisord/* /usr/src/supervisord/ 43 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 44 | COPY conf.d/* /usr/src/nginx/conf.d/ 45 | COPY default.config.json /usr/src/app/.pm2.config.default.json 46 | 47 | RUN chown docker:docker -R /usr/src/supervisord \ 48 | && chown docker:docker -R /usr/src/nginx \ 49 | && chown docker:docker -R /var/lib/nginx \ 50 | && chown docker:docker -R /var/log/app \ 51 | && chgrp docker /var/run \ 52 | && chmod g+w /var/run 53 | 54 | USER docker 55 | 56 | EXPOSE 80 57 | 58 | ENTRYPOINT ["/tini", "--"] 59 | 60 | CMD ["/usr/src/entrypoint"] 61 | -------------------------------------------------------------------------------- /node-pm2/14/conf.d/proxy.conf.erb: -------------------------------------------------------------------------------- 1 | proxy_redirect off; 2 | proxy_http_version 1.1; 3 | proxy_request_buffering off; 4 | proxy_buffering off; 5 | proxy_set_header Connection ""; 6 | proxy_connect_timeout <%= ENV.fetch('NGINX_PROXY_CONNECT_TIMEOUT', '90') %>; 7 | proxy_send_timeout <%= ENV.fetch('NGINX_PROXY_SEND_TIMEOUT', '300') %>; 8 | proxy_read_timeout <%= ENV.fetch('NGINX_PROXY_READ_TIMEOUT', '300') %>; 9 | -------------------------------------------------------------------------------- /node-pm2/14/default.config.json: -------------------------------------------------------------------------------- 1 | { 2 | apps: [{ 3 | name: 'app', 4 | script: './app.js', 5 | instances: 'max', 6 | exec_mode: 'cluster', 7 | out_file: "/dev/null", 8 | error_file: "/dev/null" 9 | }] 10 | } 11 | -------------------------------------------------------------------------------- /node-pm2/14/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | # allow specifying own .pm2.config.json to override the default. it must 5 | # however define an `app` application, and this entry point will only start 6 | # that one rather than all defined applications 7 | if [ ! -e "/usr/src/app/.pm2.config.json" ]; then 8 | cp /usr/src/app/.pm2.config.default.json /usr/src/app/.pm2.config.json 9 | echo "/usr/src/app/.pm2.config.json: default config generated." 10 | fi 11 | 12 | # generate nginx conf from ERB 13 | for file in /usr/src/nginx/{,**/}*.erb; do 14 | if [ -f "$file" ]; then 15 | # don't overwrite an existing destination file 16 | if [ ! -e "${file%.*}" ]; then 17 | erb -T- "$file" > "${file%.*}" 18 | echo "${file%.*}: generated." 19 | else 20 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 21 | fi 22 | fi 23 | done 24 | 25 | # start node web service under pm2 behind nginx 26 | exec supervisord -c /usr/src/supervisord/supervisord.conf 27 | -------------------------------------------------------------------------------- /node-pm2/14/supervisord/supervisord.conf: -------------------------------------------------------------------------------- 1 | [supervisord] 2 | nodaemon = true 3 | logfile = /var/log/app/supervisord.log 4 | logfile_maxbytes = 5MB 5 | logfile_backups = 5 6 | pidfile = /var/run/supervisord.pid 7 | 8 | [program:nginx] 9 | command=/usr/sbin/nginx -c /usr/src/nginx/nginx.conf 10 | stdout_logfile = /dev/stdout 11 | stderr_logfile = /dev/stderr 12 | stdout_logfile_maxbytes = 0 13 | stderr_logfile_maxbytes = 0 14 | 15 | [program:pm2] 16 | command = /usr/local/bin/pm2 start /usr/src/app/.pm2.config.json -s --no-daemon --only app 17 | stdout_logfile = /dev/stdout 18 | stderr_logfile = /dev/stderr 19 | stdout_logfile_maxbytes = 0 20 | stderr_logfile_maxbytes = 0 21 | -------------------------------------------------------------------------------- /node-pm2/16/conf.d/proxy.conf.erb: -------------------------------------------------------------------------------- 1 | proxy_redirect off; 2 | proxy_http_version 1.1; 3 | proxy_request_buffering off; 4 | proxy_buffering off; 5 | proxy_set_header Connection ""; 6 | proxy_connect_timeout <%= ENV.fetch('NGINX_PROXY_CONNECT_TIMEOUT', '90') %>; 7 | proxy_send_timeout <%= ENV.fetch('NGINX_PROXY_SEND_TIMEOUT', '300') %>; 8 | proxy_read_timeout <%= ENV.fetch('NGINX_PROXY_READ_TIMEOUT', '300') %>; 9 | -------------------------------------------------------------------------------- /node-pm2/16/default.config.json: -------------------------------------------------------------------------------- 1 | { 2 | apps: [{ 3 | name: 'app', 4 | script: './app.js', 5 | instances: 'max', 6 | exec_mode: 'cluster', 7 | out_file: "/dev/null", 8 | error_file: "/dev/null" 9 | }] 10 | } 11 | -------------------------------------------------------------------------------- /node-pm2/16/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | # allow specifying own .pm2.config.json to override the default. it must 5 | # however define an `app` application, and this entry point will only start 6 | # that one rather than all defined applications 7 | if [ ! -e "/usr/src/app/.pm2.config.json" ]; then 8 | cp /usr/src/app/.pm2.config.default.json /usr/src/app/.pm2.config.json 9 | echo "/usr/src/app/.pm2.config.json: default config generated." 10 | fi 11 | 12 | # generate nginx conf from ERB 13 | for file in /usr/src/nginx/{,**/}*.erb; do 14 | if [ -f "$file" ]; then 15 | # don't overwrite an existing destination file 16 | if [ ! -e "${file%.*}" ]; then 17 | erb -T- "$file" > "${file%.*}" 18 | echo "${file%.*}: generated." 19 | else 20 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 21 | fi 22 | fi 23 | done 24 | 25 | # start node web service under pm2 behind nginx 26 | exec supervisord -c /usr/src/supervisord/supervisord.conf 27 | -------------------------------------------------------------------------------- /node-pm2/16/supervisord/supervisord.conf: -------------------------------------------------------------------------------- 1 | [supervisord] 2 | nodaemon = true 3 | logfile = /var/log/app/supervisord.log 4 | logfile_maxbytes = 5MB 5 | logfile_backups = 5 6 | pidfile = /var/run/supervisord.pid 7 | 8 | [program:nginx] 9 | command=/usr/sbin/nginx -c /usr/src/nginx/nginx.conf 10 | stdout_logfile = /dev/stdout 11 | stderr_logfile = /dev/stderr 12 | stdout_logfile_maxbytes = 0 13 | stderr_logfile_maxbytes = 0 14 | 15 | [program:pm2] 16 | command = /usr/local/bin/pm2 start /usr/src/app/.pm2.config.json -s --no-daemon --only app 17 | stdout_logfile = /dev/stdout 18 | stderr_logfile = /dev/stderr 19 | stdout_logfile_maxbytes = 0 20 | stderr_logfile_maxbytes = 0 21 | -------------------------------------------------------------------------------- /node-pm2/18/conf.d/proxy.conf.erb: -------------------------------------------------------------------------------- 1 | proxy_redirect off; 2 | proxy_http_version 1.1; 3 | proxy_request_buffering off; 4 | proxy_buffering off; 5 | proxy_set_header Connection ""; 6 | proxy_connect_timeout <%= ENV.fetch('NGINX_PROXY_CONNECT_TIMEOUT', '90') %>; 7 | proxy_send_timeout <%= ENV.fetch('NGINX_PROXY_SEND_TIMEOUT', '300') %>; 8 | proxy_read_timeout <%= ENV.fetch('NGINX_PROXY_READ_TIMEOUT', '300') %>; 9 | -------------------------------------------------------------------------------- /node-pm2/18/default.config.json: -------------------------------------------------------------------------------- 1 | { 2 | apps: [{ 3 | name: 'app', 4 | script: './app.js', 5 | instances: 'max', 6 | exec_mode: 'cluster', 7 | out_file: "/dev/null", 8 | error_file: "/dev/null" 9 | }] 10 | } 11 | -------------------------------------------------------------------------------- /node-pm2/18/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | # allow specifying own .pm2.config.json to override the default. it must 5 | # however define an `app` application, and this entry point will only start 6 | # that one rather than all defined applications 7 | if [ ! -e "/usr/src/app/.pm2.config.json" ]; then 8 | cp /usr/src/app/.pm2.config.default.json /usr/src/app/.pm2.config.json 9 | echo "/usr/src/app/.pm2.config.json: default config generated." 10 | fi 11 | 12 | # generate nginx conf from ERB 13 | for file in /usr/src/nginx/{,**/}*.erb; do 14 | if [ -f "$file" ]; then 15 | # don't overwrite an existing destination file 16 | if [ ! -e "${file%.*}" ]; then 17 | erb -T- "$file" > "${file%.*}" 18 | echo "${file%.*}: generated." 19 | else 20 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 21 | fi 22 | fi 23 | done 24 | 25 | # start node web service under pm2 behind nginx 26 | exec supervisord -c /usr/src/supervisord/supervisord.conf 27 | -------------------------------------------------------------------------------- /node-pm2/18/supervisord/supervisord.conf: -------------------------------------------------------------------------------- 1 | [supervisord] 2 | nodaemon = true 3 | logfile = /var/log/app/supervisord.log 4 | logfile_maxbytes = 5MB 5 | logfile_backups = 5 6 | pidfile = /var/run/supervisord.pid 7 | 8 | [program:nginx] 9 | command=/usr/sbin/nginx -c /usr/src/nginx/nginx.conf 10 | stdout_logfile = /dev/stdout 11 | stderr_logfile = /dev/stderr 12 | stdout_logfile_maxbytes = 0 13 | stderr_logfile_maxbytes = 0 14 | 15 | [program:pm2] 16 | command = /usr/local/bin/pm2 start /usr/src/app/.pm2.config.json -s --no-daemon --only app 17 | stdout_logfile = /dev/stdout 18 | stderr_logfile = /dev/stderr 19 | stdout_logfile_maxbytes = 0 20 | stderr_logfile_maxbytes = 0 21 | -------------------------------------------------------------------------------- /node-pm2/20/conf.d/proxy.conf.erb: -------------------------------------------------------------------------------- 1 | proxy_redirect off; 2 | proxy_http_version 1.1; 3 | proxy_request_buffering off; 4 | proxy_buffering off; 5 | proxy_set_header Connection ""; 6 | proxy_connect_timeout <%= ENV.fetch('NGINX_PROXY_CONNECT_TIMEOUT', '90') %>; 7 | proxy_send_timeout <%= ENV.fetch('NGINX_PROXY_SEND_TIMEOUT', '300') %>; 8 | proxy_read_timeout <%= ENV.fetch('NGINX_PROXY_READ_TIMEOUT', '300') %>; 9 | -------------------------------------------------------------------------------- /node-pm2/20/default.config.json: -------------------------------------------------------------------------------- 1 | { 2 | apps: [{ 3 | name: 'app', 4 | script: './app.js', 5 | instances: 'max', 6 | exec_mode: 'cluster', 7 | out_file: "/dev/null", 8 | error_file: "/dev/null" 9 | }] 10 | } 11 | -------------------------------------------------------------------------------- /node-pm2/20/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | # allow specifying own .pm2.config.json to override the default. it must 5 | # however define an `app` application, and this entry point will only start 6 | # that one rather than all defined applications 7 | if [ ! -e "/usr/src/app/.pm2.config.json" ]; then 8 | cp /usr/src/app/.pm2.config.default.json /usr/src/app/.pm2.config.json 9 | echo "/usr/src/app/.pm2.config.json: default config generated." 10 | fi 11 | 12 | # generate nginx conf from ERB 13 | for file in /usr/src/nginx/{,**/}*.erb; do 14 | if [ -f "$file" ]; then 15 | # don't overwrite an existing destination file 16 | if [ ! -e "${file%.*}" ]; then 17 | erb -T- "$file" > "${file%.*}" 18 | echo "${file%.*}: generated." 19 | else 20 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 21 | fi 22 | fi 23 | done 24 | 25 | # start node web service under pm2 behind nginx 26 | exec supervisord -c /usr/src/supervisord/supervisord.conf 27 | -------------------------------------------------------------------------------- /node-pm2/20/supervisord/supervisord.conf: -------------------------------------------------------------------------------- 1 | [supervisord] 2 | nodaemon = true 3 | logfile = /var/log/app/supervisord.log 4 | logfile_maxbytes = 5MB 5 | logfile_backups = 5 6 | pidfile = /var/run/supervisord.pid 7 | 8 | [program:nginx] 9 | command=/usr/sbin/nginx -c /usr/src/nginx/nginx.conf 10 | stdout_logfile = /dev/stdout 11 | stderr_logfile = /dev/stderr 12 | stdout_logfile_maxbytes = 0 13 | stderr_logfile_maxbytes = 0 14 | 15 | [program:pm2] 16 | command = /usr/local/bin/pm2 start /usr/src/app/.pm2.config.json -s --no-daemon --only app 17 | stdout_logfile = /dev/stdout 18 | stderr_logfile = /dev/stderr 19 | stdout_logfile_maxbytes = 0 20 | stderr_logfile_maxbytes = 0 21 | -------------------------------------------------------------------------------- /node-pm2/README.md: -------------------------------------------------------------------------------- 1 | # node-pm2 2 | 3 | The base node image, but with `pm2` preinstalled for process management. 4 | 5 | ## Slim Images 6 | 7 | Node images from 14 on are built on a "slim" base image, which means that NPM 8 | packages that use native extensions will need to install more apt packages, 9 | such as `node-gyp`. If your app doesn't need any native extensions, you are 10 | ready to rock! -------------------------------------------------------------------------------- /node-pm2/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | <%= from_image(base_image) %> 3 | MAINTAINER Instructure 4 | 5 | USER root 6 | 7 | # Install Nginx 8 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 9 | && apt-get install -y apt-transport-https ca-certificates \ 10 | # TODO can this be a non-passenger source? don't think we can take it out 11 | # because then we get nginx 1.10 instead of 1.14, and I'm not sure if 1.10 12 | # has the features we need 13 | && sh -c 'echo deb https://oss-binaries.phusionpassenger.com/apt/passenger <%= base_distro %> main > /etc/apt/sources.list.d/passenger.list' \ 14 | && apt-get update \ 15 | && apt-get install -y --no-install-recommends \ 16 | nginx-extras <% unless base_distro == "xenial" %>libnginx-mod-http-headers-more-filter<% end %> \ 17 | ruby \ 18 | sudo \ 19 | supervisor \ 20 | && apt-get clean \ 21 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 22 | 23 | RUN yarn global add pm2@5.3.0 24 | 25 | RUN mkdir -p /usr/src/supervisord/ \ 26 | && mkdir -p /usr/src/nginx/conf.d \ 27 | && mkdir -p /usr/src/nginx/location.d \ 28 | && mkdir -p /usr/src/nginx/main.d \ 29 | && mkdir -p /usr/src/nginx/server.d \ 30 | && mkdir -p /usr/src/app \ 31 | && mkdir -p /var/log/app \ 32 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 33 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 34 | && ln -sf /dev/stdout /var/log/app/output.log \ 35 | && ln -sf /dev/stderr /var/log/app/error.log 36 | 37 | COPY entrypoint /usr/src/entrypoint 38 | COPY supervisord/* /usr/src/supervisord/ 39 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 40 | COPY conf.d/* /usr/src/nginx/conf.d/ 41 | COPY default.config.json /usr/src/app/.pm2.config.default.json 42 | 43 | RUN chown docker:docker -R /usr/src/supervisord \ 44 | && chown docker:docker -R /usr/src/nginx \ 45 | && chown docker:docker -R /var/lib/nginx \ 46 | && chown docker:docker -R /var/log/app \ 47 | && chgrp docker /var/run \ 48 | && chmod g+w /var/run 49 | 50 | USER docker 51 | 52 | EXPOSE 80 53 | 54 | ENTRYPOINT ["/tini", "--"] 55 | 56 | CMD ["/usr/src/entrypoint"] 57 | -------------------------------------------------------------------------------- /node-pm2/template/conf.d/proxy.conf.erb: -------------------------------------------------------------------------------- 1 | proxy_redirect off; 2 | proxy_http_version 1.1; 3 | proxy_request_buffering off; 4 | proxy_buffering off; 5 | proxy_set_header Connection ""; 6 | proxy_connect_timeout <%= ENV.fetch('NGINX_PROXY_CONNECT_TIMEOUT', '90') %>; 7 | proxy_send_timeout <%= ENV.fetch('NGINX_PROXY_SEND_TIMEOUT', '300') %>; 8 | proxy_read_timeout <%= ENV.fetch('NGINX_PROXY_READ_TIMEOUT', '300') %>; 9 | -------------------------------------------------------------------------------- /node-pm2/template/default.config.json: -------------------------------------------------------------------------------- 1 | { 2 | apps: [{ 3 | name: 'app', 4 | script: './app.js', 5 | instances: 'max', 6 | exec_mode: 'cluster', 7 | out_file: "/dev/null", 8 | error_file: "/dev/null" 9 | }] 10 | } 11 | -------------------------------------------------------------------------------- /node-pm2/template/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | # allow specifying own .pm2.config.json to override the default. it must 5 | # however define an `app` application, and this entry point will only start 6 | # that one rather than all defined applications 7 | if [ ! -e "/usr/src/app/.pm2.config.json" ]; then 8 | cp /usr/src/app/.pm2.config.default.json /usr/src/app/.pm2.config.json 9 | echo "/usr/src/app/.pm2.config.json: default config generated." 10 | fi 11 | 12 | # generate nginx conf from ERB 13 | for file in /usr/src/nginx/{,**/}*.erb; do 14 | if [ -f "$file" ]; then 15 | # don't overwrite an existing destination file 16 | if [ ! -e "${file%.*}" ]; then 17 | erb -T- "$file" > "${file%.*}" 18 | echo "${file%.*}: generated." 19 | else 20 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 21 | fi 22 | fi 23 | done 24 | 25 | # start node web service under pm2 behind nginx 26 | exec supervisord -c /usr/src/supervisord/supervisord.conf 27 | -------------------------------------------------------------------------------- /node-pm2/template/supervisord/supervisord.conf: -------------------------------------------------------------------------------- 1 | [supervisord] 2 | nodaemon = true 3 | logfile = /var/log/app/supervisord.log 4 | logfile_maxbytes = 5MB 5 | logfile_backups = 5 6 | pidfile = /var/run/supervisord.pid 7 | 8 | [program:nginx] 9 | command=/usr/sbin/nginx -c /usr/src/nginx/nginx.conf 10 | stdout_logfile = /dev/stdout 11 | stderr_logfile = /dev/stderr 12 | stdout_logfile_maxbytes = 0 13 | stderr_logfile_maxbytes = 0 14 | 15 | [program:pm2] 16 | command = /usr/local/bin/pm2 start /usr/src/app/.pm2.config.json -s --no-daemon --only app 17 | stdout_logfile = /dev/stdout 18 | stderr_logfile = /dev/stderr 19 | stdout_logfile_maxbytes = 0 20 | stderr_logfile_maxbytes = 0 21 | -------------------------------------------------------------------------------- /node/14/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:focal 7 | LABEL maintainer="Instructure" 8 | 9 | USER root 10 | 11 | ENV YARN_VERSION latest 12 | 13 | RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - \ 14 | && echo "" \ 15 | && echo "deb https://dl.yarnpkg.com/debian/ stable main" > /etc/apt/sources.list.d/yarn.list \ 16 | && apt-get update \ 17 | && apt-get install -y --no-install-recommends yarn \ 18 | && apt-get clean \ 19 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ 20 | 21 | COPY yarn-private /usr/local/bin 22 | 23 | ENV NODE_VERSION 14 24 | ENV NPM_VERSION 9.8.1 25 | 26 | RUN mkdir -p /usr/src/app && chown docker:docker /usr/src/app 27 | WORKDIR /usr/src/app 28 | 29 | RUN curl -fsSL https://deb.nodesource.com/gpgkey/nodesource.gpg.key | gpg --dearmor | apt-key add - && \ 30 | echo "deb https://deb.nodesource.com/node_14.x focal main" > /etc/apt/sources.list.d/nodesource.list && \ 31 | apt-get update && \ 32 | apt-get install -y --no-install-recommends nodejs && \ 33 | apt-get clean && \ 34 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ && \ 35 | npm install -g "npm@$NPM_VERSION" && \ 36 | rm -rf /root/.npm/_cacache && \ 37 | npm cache clean --force 38 | 39 | COPY npm-private /usr/local/bin 40 | 41 | 42 | USER docker 43 | -------------------------------------------------------------------------------- /node/14/npm-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | npm "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/14/yarn-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | yarn "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/16/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:focal 7 | LABEL maintainer="Instructure" 8 | 9 | USER root 10 | 11 | ENV YARN_VERSION latest 12 | 13 | RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - \ 14 | && echo "" \ 15 | && echo "deb https://dl.yarnpkg.com/debian/ stable main" > /etc/apt/sources.list.d/yarn.list \ 16 | && apt-get update \ 17 | && apt-get install -y --no-install-recommends yarn \ 18 | && apt-get clean \ 19 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ 20 | 21 | COPY yarn-private /usr/local/bin 22 | 23 | ENV NODE_VERSION 16 24 | ENV NPM_VERSION 9.8.1 25 | 26 | RUN mkdir -p /usr/src/app && chown docker:docker /usr/src/app 27 | WORKDIR /usr/src/app 28 | 29 | RUN apt-get update && \ 30 | apt-get install -y curl && \ 31 | mkdir -p /etc/apt/keyrings && \ 32 | curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg && \ 33 | echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_16.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list && \ 34 | apt-get update && \ 35 | apt-get install -y --no-install-recommends nodejs && \ 36 | apt-get clean && \ 37 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ && \ 38 | npm install -g "npm@$NPM_VERSION" && \ 39 | rm -rf /root/.npm/_cacache && \ 40 | npm cache clean --force 41 | 42 | COPY npm-private /usr/local/bin 43 | 44 | 45 | USER docker 46 | -------------------------------------------------------------------------------- /node/16/npm-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | npm "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/16/yarn-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | yarn "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/18/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | LABEL maintainer="Instructure" 8 | 9 | USER root 10 | 11 | ENV YARN_VERSION latest 12 | 13 | RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - \ 14 | && echo "" \ 15 | && echo "deb https://dl.yarnpkg.com/debian/ stable main" > /etc/apt/sources.list.d/yarn.list \ 16 | && apt-get update \ 17 | && apt-get install -y --no-install-recommends yarn \ 18 | && apt-get clean \ 19 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ 20 | 21 | COPY yarn-private /usr/local/bin 22 | 23 | ENV NODE_VERSION 18 24 | ENV NPM_VERSION 10.9.2 25 | 26 | RUN mkdir -p /usr/src/app && chown docker:docker /usr/src/app 27 | WORKDIR /usr/src/app 28 | 29 | RUN apt-get update && \ 30 | apt-get install -y curl && \ 31 | mkdir -p /etc/apt/keyrings && \ 32 | curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg && \ 33 | echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_18.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list && \ 34 | apt-get update && \ 35 | apt-get install -y --no-install-recommends nodejs && \ 36 | apt-get clean && \ 37 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ && \ 38 | npm install -g "npm@$NPM_VERSION" && \ 39 | rm -rf /root/.npm/_cacache && \ 40 | npm cache clean --force 41 | 42 | COPY npm-private /usr/local/bin 43 | 44 | 45 | USER docker 46 | -------------------------------------------------------------------------------- /node/18/npm-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | npm "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/18/yarn-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | yarn "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/20/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | LABEL maintainer="Instructure" 8 | 9 | USER root 10 | 11 | ENV YARN_VERSION latest 12 | 13 | RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - \ 14 | && echo "" \ 15 | && echo "deb https://dl.yarnpkg.com/debian/ stable main" > /etc/apt/sources.list.d/yarn.list \ 16 | && apt-get update \ 17 | && apt-get install -y --no-install-recommends yarn \ 18 | && apt-get clean \ 19 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ 20 | 21 | COPY yarn-private /usr/local/bin 22 | 23 | ENV NODE_VERSION 20 24 | ENV NPM_VERSION latest 25 | 26 | RUN mkdir -p /usr/src/app && chown docker:docker /usr/src/app 27 | WORKDIR /usr/src/app 28 | 29 | RUN apt-get update && \ 30 | apt-get install -y curl && \ 31 | mkdir -p /etc/apt/keyrings && \ 32 | curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg && \ 33 | echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_20.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list && \ 34 | apt-get update && \ 35 | apt-get install -y --no-install-recommends nodejs && \ 36 | apt-get clean && \ 37 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ && \ 38 | npm install -g "npm@$NPM_VERSION" && \ 39 | rm -rf /root/.npm/_cacache && \ 40 | npm cache clean --force 41 | 42 | COPY npm-private /usr/local/bin 43 | 44 | 45 | USER docker 46 | -------------------------------------------------------------------------------- /node/20/npm-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | npm "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/20/yarn-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | yarn "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/22/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:node` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | LABEL maintainer="Instructure" 8 | 9 | USER root 10 | 11 | ENV YARN_VERSION latest 12 | 13 | RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - \ 14 | && echo "" \ 15 | && echo "deb https://dl.yarnpkg.com/debian/ stable main" > /etc/apt/sources.list.d/yarn.list \ 16 | && apt-get update \ 17 | && apt-get install -y --no-install-recommends yarn \ 18 | && apt-get clean \ 19 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ 20 | 21 | COPY yarn-private /usr/local/bin 22 | 23 | ENV NODE_VERSION 22 24 | ENV NPM_VERSION latest 25 | 26 | RUN mkdir -p /usr/src/app && chown docker:docker /usr/src/app 27 | WORKDIR /usr/src/app 28 | 29 | RUN apt-get update && \ 30 | apt-get install -y curl && \ 31 | mkdir -p /etc/apt/keyrings && \ 32 | curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg && \ 33 | echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_22.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list && \ 34 | apt-get update && \ 35 | apt-get install -y --no-install-recommends nodejs && \ 36 | apt-get clean && \ 37 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ && \ 38 | npm install -g "npm@$NPM_VERSION" && \ 39 | rm -rf /root/.npm/_cacache && \ 40 | npm cache clean --force 41 | 42 | COPY npm-private /usr/local/bin 43 | 44 | 45 | USER docker 46 | -------------------------------------------------------------------------------- /node/22/npm-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | npm "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/22/yarn-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | yarn "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | <%= from_image(base_image) %> 3 | LABEL maintainer="Instructure" 4 | 5 | USER root 6 | 7 | <% if yarn_version -%> 8 | <%= Template.render_into_dockerfile("templates/yarn_install.Dockerfile", yarn_version: yarn_version) -%> 9 | <% end -%> 10 | 11 | <%= Template.render_into_dockerfile("templates/node_install.Dockerfile", node_version: node_version, npm_version: npm_version, base_distro: base_distro) %> 12 | 13 | USER docker 14 | -------------------------------------------------------------------------------- /node/template/npm-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | npm "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /node/template/yarn-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | npm config set "@${NPM_PRIVATE_SCOPE}:registry"="https:${NPM_PRIVATE_REGISTRY}" 4 | npm config set "${NPM_PRIVATE_REGISTRY}:username"="${NPM_PRIVATE_USERNAME}" 5 | npm config set "${NPM_PRIVATE_REGISTRY}:_password"="${NPM_PRIVATE_PASSWORD}" 6 | npm config set "${NPM_PRIVATE_REGISTRY}:email"="${NPM_PRIVATE_EMAIL}" 7 | 8 | yarn "$@" 9 | EXIT_CODE=$? 10 | 11 | npm config delete "@${NPM_PRIVATE_SCOPE}:registry" 12 | npm config delete "${NPM_PRIVATE_REGISTRY}:username" 13 | npm config delete "${NPM_PRIVATE_REGISTRY}:_password" 14 | npm config delete "${NPM_PRIVATE_REGISTRY}:email" 15 | 16 | exit $EXIT_CODE 17 | -------------------------------------------------------------------------------- /php-nginx/template/entrypoint.d/20-configure-nginx.py: -------------------------------------------------------------------------------- 1 | #! /usr/bin/env python 2 | 3 | import os 4 | import sys 5 | from jinja2 import Environment, FileSystemLoader 6 | 7 | scriptDir = os.path.abspath(os.path.dirname(sys.argv[0])) 8 | 9 | args = dict() 10 | args['appDomain'] = os.environ.get('APP_DOMAIN', 'app.invalid') 11 | 12 | args['cgEnvironment'] = os.environ.get('CG_ENVIRONMENT', 'local') 13 | 14 | httpPort = os.environ.get('CG_HTTP_PORT', '8080') 15 | httpsPort = os.environ.get('CG_HTTPS_PORT', '8443') 16 | 17 | args['appPort'] = httpsPort or httpPort 18 | args['redirectPort'] = httpPort if httpPort != httpsPort else None 19 | 20 | args['nginxWorkerCount'] = os.environ.get('NGINX_WORKER_COUNT', 'auto') 21 | args['nginxWorkerConnections'] = os.environ.get('NGINX_WORKER_CONNECTIONS', '1024') 22 | args['nginxMaxUploadSize'] = os.environ.get('NGINX_MAX_UPLOAD_SIZE', '10m') 23 | 24 | args['hstsEnabled'] = os.environ.get('HSTS_ENABLED', 'true').lower() not in ['false', 'f', '0'] 25 | args['hstsMaxAge'] = os.environ.get('HSTS_MAX_AGE', '10368000') 26 | 27 | hstsOptions = os.environ.get('HSTS_OPTIONS', '') 28 | args['hstsOptions'] = hstsOptions if not hstsOptions else '; ' + hstsOptions 29 | 30 | templateEnv = Environment( 31 | loader=FileSystemLoader(searchpath=scriptDir), 32 | ) 33 | 34 | template = templateEnv.get_template('nginx.conf') 35 | 36 | with open('/usr/src/nginx/nginx.conf', 'w+') as outputFile: 37 | outputFile.write(template.render(**args)) 38 | -------------------------------------------------------------------------------- /php-nginx/template/supervisor/supervisord.conf: -------------------------------------------------------------------------------- 1 | [supervisord] 2 | logfile = /dev/stdout 3 | logfile_maxbytes = 0 4 | nodaemon = true 5 | pidfile = /tmp/supervisord.pid 6 | 7 | [program:php-fpm] 8 | command = /usr/sbin/php-fpm --fpm-config /usr/src/php/fpm/default.conf 9 | ; lower priority numbers get started first and shutdown last 10 | priority = 100 11 | stdout_logfile=/dev/stdout 12 | stdout_logfile_maxbytes=0 13 | stderr_logfile=/dev/stderr 14 | stderr_logfile_maxbytes=0 15 | 16 | [program:nginx] 17 | command = /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 18 | ; lower priority numbers get started first and shutdown last 19 | priority = 200 20 | stdout_logfile=/dev/stdout 21 | stdout_logfile_maxbytes=0 22 | stderr_logfile=/dev/stderr 23 | stderr_logfile_maxbytes=0 24 | -------------------------------------------------------------------------------- /php/7.4/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:php` 4 | FROM instructure/core:focal 5 | LABEL maintainer=Instructure 6 | 7 | ENV PHP_VERSION=7.4 8 | 9 | USER root 10 | COPY entrypoint.sh /entrypoint.sh 11 | 12 | RUN /bin/bash -c 'source /etc/lsb-release \ 13 | && echo "deb http://ppa.launchpad.net/ondrej/php/ubuntu $DISTRIB_CODENAME main" > /etc/apt/sources.list.d/php.list \ 14 | && echo "deb-src http://ppa.launchpad.net/ondrej/php/ubuntu $DISTRIB_CODENAME main" >> /etc/apt/sources.list.d/php.list' \ 15 | && curl "https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x4f4ea0aae5267a6c" | apt-key add - \ 16 | && apt-get update \ 17 | && apt-get install --yes --no-install-recommends \ 18 | php${PHP_VERSION} \ 19 | php${PHP_VERSION}-cli \ 20 | python3-jinja2 \ 21 | # clean up apt's mess 22 | && apt-get clean \ 23 | && rm -rf /var/lib/apt/lists/* 24 | 25 | # Update some defaults to be a bit more sane 26 | RUN ln -s /etc/php/${PHP_VERSION} /etc/php/current \ 27 | && update-alternatives --install /usr/bin/python python /usr/bin/python3 10 \ 28 | && mkdir -p /usr/src/app /var/run/php /entrypoint.d/ \ 29 | && chown docker:docker /usr/src/app \ 30 | && chown docker:docker /var/run/php \ 31 | && chown -R docker:docker /entrypoint.d 32 | 33 | WORKDIR /usr/src/app 34 | 35 | USER docker 36 | 37 | ENTRYPOINT ["/entrypoint.sh"] 38 | -------------------------------------------------------------------------------- /php/7.4/entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | DIR=/entrypoint.d 4 | 5 | if [[ -d "$DIR" ]]; then 6 | /bin/run-parts --verbose --regex '\.(sh|py|php)$' "$DIR" 7 | fi 8 | 9 | exec "$@" 10 | -------------------------------------------------------------------------------- /php/README.md: -------------------------------------------------------------------------------- 1 | # instructure/php 2 | 3 | Universial(ish) base images for PHP apps without a web server. 4 | 5 | ## Entrypoint 6 | There is an entrypoint script specified, this script will execute any shell, PHP, or python (version 3) scripts placed in 7 | `/entrypoint.d` with their executable bit(s) set in lexical order according the the locale in the container (defaults to 8 | `en_US.UTF-8`). This is useful for initializing configuration files as a bridge from file based configuration to 9 | environment variables exclusively. 10 | 11 | *Note*: These scripts are executed as the `docker` user and will be subject to that user's access to the filesystem. 12 | -------------------------------------------------------------------------------- /php/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message -%> 2 | FROM <%= base_image %> 3 | LABEL maintainer=Instructure 4 | 5 | ENV PHP_VERSION=<%= version.sub(/-.+\z/, '') %> 6 | 7 | USER root 8 | COPY entrypoint.sh /entrypoint.sh 9 | 10 | RUN /bin/bash -c 'source /etc/lsb-release \ 11 | && echo "deb http://ppa.launchpad.net/ondrej/php/ubuntu $DISTRIB_CODENAME main" > /etc/apt/sources.list.d/php.list \ 12 | && echo "deb-src http://ppa.launchpad.net/ondrej/php/ubuntu $DISTRIB_CODENAME main" >> /etc/apt/sources.list.d/php.list' \ 13 | && curl "https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x4f4ea0aae5267a6c" | apt-key add - \ 14 | && apt-get update \ 15 | && apt-get install --yes --no-install-recommends \ 16 | php${PHP_VERSION} \ 17 | php${PHP_VERSION}-cli \ 18 | <% if version != '7.3-focal' -%> 19 | python3-jinja2 \ 20 | <% end -%> 21 | # clean up apt's mess 22 | && apt-get clean \ 23 | && rm -rf /var/lib/apt/lists/* 24 | 25 | # Update some defaults to be a bit more sane 26 | RUN ln -s /etc/php/${PHP_VERSION} /etc/php/current \ 27 | <% if version != '7.3-focal' -%> 28 | && update-alternatives --install /usr/bin/python python /usr/bin/python3 10 \ 29 | <% end -%> 30 | && mkdir -p /usr/src/app /var/run/php /entrypoint.d/ \ 31 | && chown docker:docker /usr/src/app \ 32 | && chown docker:docker /var/run/php \ 33 | && chown -R docker:docker /entrypoint.d 34 | 35 | WORKDIR /usr/src/app 36 | 37 | USER docker 38 | 39 | ENTRYPOINT ["/entrypoint.sh"] 40 | -------------------------------------------------------------------------------- /php/template/entrypoint.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | DIR=/entrypoint.d 4 | 5 | if [[ -d "$DIR" ]]; then 6 | /bin/run-parts --verbose --regex '\.(sh|py|php)$' "$DIR" 7 | fi 8 | 9 | exec "$@" 10 | -------------------------------------------------------------------------------- /python/3.10/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:python` 4 | 5 | FROM instructure/core:bionic 6 | MAINTAINER Instructure Engineering 7 | USER root 8 | 9 | ARG PYTHON_VERSION=3.10.4 10 | ARG PYTHON_MAJOR_MINOR_VERSION=3.10 11 | ARG PIP_VERSION=20.1 12 | ARG PGP_KEY_ID=A035C8C19219BA821ECEA86B64E628F8D684696D 13 | 14 | RUN apt-get update && apt-get install -y zlib1g-dev libncurses5-dev libffi-dev libsqlite3-dev\ 15 | libgdbm-dev libnss3-dev libssl-dev libreadline-dev 16 | 17 | RUN cd /tmp && \ 18 | curl -fsSLO https://www.python.org/ftp/python/${PYTHON_VERSION}/Python-${PYTHON_VERSION}.tar.xz && \ 19 | curl -fsSLO https://www.python.org/ftp/python/${PYTHON_VERSION}/Python-${PYTHON_VERSION}.tar.xz.asc && \ 20 | gpg --batch --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys ${PGP_KEY_ID} || \ 21 | gpg --batch --keyserver hkp://pgp.mit.edu:80 --recv-keys ${PGP_KEY_ID} && \ 22 | gpg --verify Python-${PYTHON_VERSION}.tar.xz.asc Python-${PYTHON_VERSION}.tar.xz && \ 23 | tar -xf Python-${PYTHON_VERSION}.tar.xz && \ 24 | rm Python-${PYTHON_VERSION}.tar.xz && \ 25 | cd Python-${PYTHON_VERSION} && \ 26 | ./configure --enable-optimizations && \ 27 | make altinstall 28 | 29 | RUN pip${PYTHON_MAJOR_MINOR_VERSION} install --upgrade pip==${PIP_VERSION} && pip install pipenv 30 | 31 | WORKDIR /usr/src/app/ 32 | 33 | RUN chown docker:docker . 34 | 35 | USER docker 36 | 37 | RUN pipenv --python ${PYTHON_MAJOR_MINOR_VERSION} 38 | 39 | COPY pip-private pipenv-private /usr/local/bin/ 40 | -------------------------------------------------------------------------------- /python/3.10/pip-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | USER_FILE=$HOME/.pypirc 3 | 4 | if [ -n "$PYPI_PRIVATE_REGISTRY" ] && [ -n "$PYPI_PRIVATE_USERNAME" ] && [ -n "$PYPI_PRIVATE_PASSWORD" ]; then 5 | echo -e "[distutils]\nindex-servers =\n\tjfrog\n[jfrog]\nrepository: https:$PYPI_PRIVATE_REGISTRY\nusername: $PYPI_PRIVATE_USERNAME\npassword: $PYPI_PRIVATE_PASSWORD" > $USER_FILE 6 | fi 7 | # Run the pipenv command with the credentials which have been added above. 8 | pip "$@" 9 | EXIT_CODE=$? 10 | 11 | [ -e "$USER_FILE" ] && rm $USER_FILE 12 | exit $EXIT_CODE 13 | -------------------------------------------------------------------------------- /python/3.10/pipenv-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | USER_FILE=$HOME/.pypirc 3 | 4 | if [ -n "$PYPI_PRIVATE_REGISTRY" ] && [ -n "$PYPI_PRIVATE_USERNAME" ] && [ -n "$PYPI_PRIVATE_PASSWORD" ]; then 5 | echo -e "[distutils]\nindex-servers =\n\tjfrog\n[jfrog]\nrepository: https:$PYPI_PRIVATE_REGISTRY\nusername: $PYPI_PRIVATE_USERNAME\npassword: $PYPI_PRIVATE_PASSWORD" > $USER_FILE 6 | fi 7 | # Run the pipenv command with the credentials which have been added above. 8 | pipenv "$@" 9 | EXIT_CODE=$? 10 | 11 | [ -e "$USER_FILE" ] && rm $USER_FILE 12 | exit $EXIT_CODE 13 | 14 | -------------------------------------------------------------------------------- /python/3.7/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:python` 4 | 5 | FROM instructure/core:bionic 6 | MAINTAINER Instructure Engineering 7 | USER root 8 | 9 | ARG PYTHON_VERSION=3.7.5 10 | ARG PYTHON_MAJOR_MINOR_VERSION=3.7 11 | ARG PIP_VERSION=20.1 12 | ARG PGP_KEY_ID=0D96DF4D4110E5C43FBFB17F2D347EA6AA65421D 13 | 14 | RUN apt-get update && apt-get install -y zlib1g-dev libncurses5-dev libffi-dev libsqlite3-dev\ 15 | libgdbm-dev libnss3-dev libssl-dev libreadline-dev 16 | 17 | RUN cd /tmp && \ 18 | curl -fsSLO https://www.python.org/ftp/python/${PYTHON_VERSION}/Python-${PYTHON_VERSION}.tar.xz && \ 19 | curl -fsSLO https://www.python.org/ftp/python/${PYTHON_VERSION}/Python-${PYTHON_VERSION}.tar.xz.asc && \ 20 | gpg --batch --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys ${PGP_KEY_ID} || \ 21 | gpg --batch --keyserver hkp://pgp.mit.edu:80 --recv-keys ${PGP_KEY_ID} && \ 22 | gpg --verify Python-${PYTHON_VERSION}.tar.xz.asc Python-${PYTHON_VERSION}.tar.xz && \ 23 | tar -xf Python-${PYTHON_VERSION}.tar.xz && \ 24 | rm Python-${PYTHON_VERSION}.tar.xz && \ 25 | cd Python-${PYTHON_VERSION} && \ 26 | ./configure --enable-optimizations && \ 27 | make altinstall 28 | 29 | RUN pip${PYTHON_MAJOR_MINOR_VERSION} install --upgrade pip==${PIP_VERSION} && pip install pipenv 30 | 31 | WORKDIR /usr/src/app/ 32 | 33 | RUN chown docker:docker . 34 | 35 | USER docker 36 | 37 | RUN pipenv --python ${PYTHON_MAJOR_MINOR_VERSION} 38 | 39 | COPY pip-private pipenv-private /usr/local/bin/ 40 | -------------------------------------------------------------------------------- /python/3.7/pip-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | USER_FILE=$HOME/.pypirc 3 | 4 | if [ -n "$PYPI_PRIVATE_REGISTRY" ] && [ -n "$PYPI_PRIVATE_USERNAME" ] && [ -n "$PYPI_PRIVATE_PASSWORD" ]; then 5 | echo -e "[distutils]\nindex-servers =\n\tjfrog\n[jfrog]\nrepository: https:$PYPI_PRIVATE_REGISTRY\nusername: $PYPI_PRIVATE_USERNAME\npassword: $PYPI_PRIVATE_PASSWORD" > $USER_FILE 6 | fi 7 | # Run the pipenv command with the credentials which have been added above. 8 | pip "$@" 9 | EXIT_CODE=$? 10 | 11 | [ -e "$USER_FILE" ] && rm $USER_FILE 12 | exit $EXIT_CODE 13 | -------------------------------------------------------------------------------- /python/3.7/pipenv-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | USER_FILE=$HOME/.pypirc 3 | 4 | if [ -n "$PYPI_PRIVATE_REGISTRY" ] && [ -n "$PYPI_PRIVATE_USERNAME" ] && [ -n "$PYPI_PRIVATE_PASSWORD" ]; then 5 | echo -e "[distutils]\nindex-servers =\n\tjfrog\n[jfrog]\nrepository: https:$PYPI_PRIVATE_REGISTRY\nusername: $PYPI_PRIVATE_USERNAME\npassword: $PYPI_PRIVATE_PASSWORD" > $USER_FILE 6 | fi 7 | # Run the pipenv command with the credentials which have been added above. 8 | pipenv "$@" 9 | EXIT_CODE=$? 10 | 11 | [ -e "$USER_FILE" ] && rm $USER_FILE 12 | exit $EXIT_CODE 13 | 14 | -------------------------------------------------------------------------------- /python/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | FROM <%= base_image %> 3 | MAINTAINER Instructure Engineering 4 | USER root 5 | 6 | ARG PYTHON_VERSION=<%= python_version %> 7 | ARG PYTHON_MAJOR_MINOR_VERSION=<%= python_build_version %> 8 | ARG PIP_VERSION=<%= pip_version %> 9 | ARG PGP_KEY_ID=<%= python_pgp_key_id %> 10 | 11 | RUN apt-get update && apt-get install -y zlib1g-dev libncurses5-dev libffi-dev libsqlite3-dev\ 12 | libgdbm-dev libnss3-dev libssl-dev libreadline-dev 13 | 14 | RUN cd /tmp && \ 15 | curl -fsSLO https://www.python.org/ftp/python/${PYTHON_VERSION}/Python-${PYTHON_VERSION}.tar.xz && \ 16 | curl -fsSLO https://www.python.org/ftp/python/${PYTHON_VERSION}/Python-${PYTHON_VERSION}.tar.xz.asc && \ 17 | gpg --batch --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys ${PGP_KEY_ID} || \ 18 | gpg --batch --keyserver hkp://pgp.mit.edu:80 --recv-keys ${PGP_KEY_ID} && \ 19 | gpg --verify Python-${PYTHON_VERSION}.tar.xz.asc Python-${PYTHON_VERSION}.tar.xz && \ 20 | tar -xf Python-${PYTHON_VERSION}.tar.xz && \ 21 | rm Python-${PYTHON_VERSION}.tar.xz && \ 22 | cd Python-${PYTHON_VERSION} && \ 23 | ./configure --enable-optimizations && \ 24 | make altinstall 25 | 26 | RUN pip${PYTHON_MAJOR_MINOR_VERSION} install --upgrade pip==${PIP_VERSION} && pip install pipenv 27 | 28 | WORKDIR /usr/src/app/ 29 | 30 | RUN chown docker:docker . 31 | 32 | USER docker 33 | 34 | RUN pipenv --python ${PYTHON_MAJOR_MINOR_VERSION} 35 | 36 | COPY pip-private pipenv-private /usr/local/bin/ 37 | -------------------------------------------------------------------------------- /python/template/pip-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | USER_FILE=$HOME/.pypirc 3 | 4 | if [ -n "$PYPI_PRIVATE_REGISTRY" ] && [ -n "$PYPI_PRIVATE_USERNAME" ] && [ -n "$PYPI_PRIVATE_PASSWORD" ]; then 5 | echo -e "[distutils]\nindex-servers =\n\tjfrog\n[jfrog]\nrepository: https:$PYPI_PRIVATE_REGISTRY\nusername: $PYPI_PRIVATE_USERNAME\npassword: $PYPI_PRIVATE_PASSWORD" > $USER_FILE 6 | fi 7 | # Run the pipenv command with the credentials which have been added above. 8 | pip "$@" 9 | EXIT_CODE=$? 10 | 11 | [ -e "$USER_FILE" ] && rm $USER_FILE 12 | exit $EXIT_CODE 13 | -------------------------------------------------------------------------------- /python/template/pipenv-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | USER_FILE=$HOME/.pypirc 3 | 4 | if [ -n "$PYPI_PRIVATE_REGISTRY" ] && [ -n "$PYPI_PRIVATE_USERNAME" ] && [ -n "$PYPI_PRIVATE_PASSWORD" ]; then 5 | echo -e "[distutils]\nindex-servers =\n\tjfrog\n[jfrog]\nrepository: https:$PYPI_PRIVATE_REGISTRY\nusername: $PYPI_PRIVATE_USERNAME\npassword: $PYPI_PRIVATE_PASSWORD" > $USER_FILE 6 | fi 7 | # Run the pipenv command with the credentials which have been added above. 8 | pipenv "$@" 9 | EXIT_CODE=$? 10 | 11 | [ -e "$USER_FILE" ] && rm $USER_FILE 12 | exit $EXIT_CODE 13 | 14 | -------------------------------------------------------------------------------- /rover/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= from_image(base_image) %> 2 | LABEL maintainer="Instructure" 3 | 4 | RUN mkdir -p /tmp/rover \ 5 | && apt-get update && apt-get install -y \ 6 | build-essential \ 7 | curl \ 8 | wget \ 9 | && wget -O - https://github.com/apollographql/rover/tarball/<%= version %> | tar xz -C /tmp/rover --strip-components=1 \ 10 | && cd /tmp/rover \ 11 | && cargo run --release -- install \ 12 | && rm -rf /var/lib/apt/lists/* \ 13 | && apt-get clean \ 14 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 15 | -------------------------------------------------------------------------------- /rover/v0.4.8/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=${TARGETPLATFORM} rust:1.60.0-slim-buster 2 | LABEL maintainer="Instructure" 3 | 4 | RUN mkdir -p /tmp/rover \ 5 | && apt-get update && apt-get install -y \ 6 | build-essential \ 7 | curl \ 8 | wget \ 9 | && wget -O - https://github.com/apollographql/rover/tarball/v0.4.8 | tar xz -C /tmp/rover --strip-components=1 \ 10 | && cd /tmp/rover \ 11 | && cargo run --release -- install \ 12 | && rm -rf /var/lib/apt/lists/* \ 13 | && apt-get clean \ 14 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 15 | -------------------------------------------------------------------------------- /ruby-passenger/2.7/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/ruby:2.7 7 | LABEL org.opencontainers.image.authors="Instructure" 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger focal main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | sudo \ 20 | passenger \ 21 | libnginx-mod-http-passenger \ 22 | # libnginx-mod-http-passenger in bionic destroys the alternatives in the base ruby image 23 | && update-alternatives --install /usr/bin/gem gem /usr/bin/gem$RUBY_MAJOR 181 \ 24 | && update-alternatives \ 25 | --install /usr/bin/ruby ruby /usr/bin/ruby${RUBY_MAJOR} 51 \ 26 | --slave /usr/bin/erb erb /usr/bin/erb${RUBY_MAJOR} \ 27 | --slave /usr/bin/irb irb /usr/bin/irb${RUBY_MAJOR} \ 28 | --slave /usr/bin/rdoc rdoc /usr/bin/rdoc${RUBY_MAJOR} \ 29 | --slave /usr/bin/ri ri /usr/bin/ri${RUBY_MAJOR} \ 30 | && apt-get clean \ 31 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 32 | 33 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 34 | 35 | USER docker 36 | RUN passenger-config build-native-support 37 | 38 | # Nginx Configuration 39 | USER root 40 | 41 | COPY entrypoint /usr/src/entrypoint 42 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 43 | COPY main.d/* /usr/src/nginx/main.d/ 44 | RUN mkdir -p /usr/src/nginx/conf.d \ 45 | && mkdir -p /usr/src/nginx/location.d \ 46 | && mkdir -p /usr/src/nginx/main.d \ 47 | && mkdir -p /usr/src/nginx/server.d \ 48 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 49 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 50 | && chown docker:docker -R /usr/src/nginx 51 | 52 | USER docker 53 | 54 | EXPOSE 80 55 | CMD ["/tini", "--", "/usr/src/entrypoint"] 56 | -------------------------------------------------------------------------------- /ruby-passenger/2.7/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/2.7/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby-passenger/3.0/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/ruby:3.0 7 | LABEL org.opencontainers.image.authors="Instructure" 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger focal main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | sudo \ 20 | passenger \ 21 | libnginx-mod-http-passenger \ 22 | # libnginx-mod-http-passenger in bionic destroys the alternatives in the base ruby image 23 | && update-alternatives --install /usr/bin/gem gem /usr/bin/gem$RUBY_MAJOR 181 \ 24 | && update-alternatives \ 25 | --install /usr/bin/ruby ruby /usr/bin/ruby${RUBY_MAJOR} 51 \ 26 | --slave /usr/bin/erb erb /usr/bin/erb${RUBY_MAJOR} \ 27 | --slave /usr/bin/irb irb /usr/bin/irb${RUBY_MAJOR} \ 28 | --slave /usr/bin/rdoc rdoc /usr/bin/rdoc${RUBY_MAJOR} \ 29 | --slave /usr/bin/ri ri /usr/bin/ri${RUBY_MAJOR} \ 30 | && apt-get clean \ 31 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 32 | 33 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 34 | 35 | USER docker 36 | RUN passenger-config build-native-support 37 | 38 | # Nginx Configuration 39 | USER root 40 | 41 | COPY entrypoint /usr/src/entrypoint 42 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 43 | COPY main.d/* /usr/src/nginx/main.d/ 44 | RUN mkdir -p /usr/src/nginx/conf.d \ 45 | && mkdir -p /usr/src/nginx/location.d \ 46 | && mkdir -p /usr/src/nginx/main.d \ 47 | && mkdir -p /usr/src/nginx/server.d \ 48 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 49 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 50 | && chown docker:docker -R /usr/src/nginx 51 | 52 | USER docker 53 | 54 | EXPOSE 80 55 | CMD ["/tini", "--", "/usr/src/entrypoint"] 56 | -------------------------------------------------------------------------------- /ruby-passenger/3.0/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/3.0/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby-passenger/3.1-jammy/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/3.1-jammy/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby-passenger/3.1/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/ruby:3.1 7 | LABEL org.opencontainers.image.authors="Instructure" 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger focal main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | sudo \ 20 | passenger \ 21 | libnginx-mod-http-passenger \ 22 | # libnginx-mod-http-passenger in bionic destroys the alternatives in the base ruby image 23 | && update-alternatives --install /usr/bin/gem gem /usr/bin/gem$RUBY_MAJOR 181 \ 24 | && update-alternatives \ 25 | --install /usr/bin/ruby ruby /usr/bin/ruby${RUBY_MAJOR} 51 \ 26 | --slave /usr/bin/erb erb /usr/bin/erb${RUBY_MAJOR} \ 27 | --slave /usr/bin/irb irb /usr/bin/irb${RUBY_MAJOR} \ 28 | --slave /usr/bin/rdoc rdoc /usr/bin/rdoc${RUBY_MAJOR} \ 29 | --slave /usr/bin/ri ri /usr/bin/ri${RUBY_MAJOR} \ 30 | && apt-get clean \ 31 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 32 | 33 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 34 | 35 | USER docker 36 | RUN passenger-config build-native-support 37 | 38 | # Nginx Configuration 39 | USER root 40 | 41 | COPY entrypoint /usr/src/entrypoint 42 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 43 | COPY main.d/* /usr/src/nginx/main.d/ 44 | RUN mkdir -p /usr/src/nginx/conf.d \ 45 | && mkdir -p /usr/src/nginx/location.d \ 46 | && mkdir -p /usr/src/nginx/main.d \ 47 | && mkdir -p /usr/src/nginx/server.d \ 48 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 49 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 50 | && chown docker:docker -R /usr/src/nginx 51 | 52 | USER docker 53 | 54 | EXPOSE 80 55 | CMD ["/tini", "--", "/usr/src/entrypoint"] 56 | -------------------------------------------------------------------------------- /ruby-passenger/3.1/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/3.1/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby-passenger/3.2-jammy/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/3.2-jammy/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby-passenger/3.2/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/ruby:3.2 7 | LABEL org.opencontainers.image.authors="Instructure" 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger focal main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | sudo \ 20 | passenger \ 21 | libnginx-mod-http-passenger \ 22 | # libnginx-mod-http-passenger in bionic destroys the alternatives in the base ruby image 23 | && update-alternatives --install /usr/bin/gem gem /usr/bin/gem$RUBY_MAJOR 181 \ 24 | && update-alternatives \ 25 | --install /usr/bin/ruby ruby /usr/bin/ruby${RUBY_MAJOR} 51 \ 26 | --slave /usr/bin/erb erb /usr/bin/erb${RUBY_MAJOR} \ 27 | --slave /usr/bin/irb irb /usr/bin/irb${RUBY_MAJOR} \ 28 | --slave /usr/bin/rdoc rdoc /usr/bin/rdoc${RUBY_MAJOR} \ 29 | --slave /usr/bin/ri ri /usr/bin/ri${RUBY_MAJOR} \ 30 | && apt-get clean \ 31 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 32 | 33 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 34 | 35 | USER docker 36 | RUN passenger-config build-native-support 37 | 38 | # Nginx Configuration 39 | USER root 40 | 41 | COPY entrypoint /usr/src/entrypoint 42 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 43 | COPY main.d/* /usr/src/nginx/main.d/ 44 | RUN mkdir -p /usr/src/nginx/conf.d \ 45 | && mkdir -p /usr/src/nginx/location.d \ 46 | && mkdir -p /usr/src/nginx/main.d \ 47 | && mkdir -p /usr/src/nginx/server.d \ 48 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 49 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 50 | && chown docker:docker -R /usr/src/nginx 51 | 52 | USER docker 53 | 54 | EXPOSE 80 55 | CMD ["/tini", "--", "/usr/src/entrypoint"] 56 | -------------------------------------------------------------------------------- /ruby-passenger/3.2/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/3.2/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby-passenger/3.3-jammy/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/3.3-jammy/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby-passenger/3.3/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/ruby:3.3 7 | LABEL org.opencontainers.image.authors="Instructure" 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger focal main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | sudo \ 20 | passenger \ 21 | libnginx-mod-http-passenger \ 22 | # libnginx-mod-http-passenger in bionic destroys the alternatives in the base ruby image 23 | && update-alternatives --install /usr/bin/gem gem /usr/bin/gem$RUBY_MAJOR 181 \ 24 | && update-alternatives \ 25 | --install /usr/bin/ruby ruby /usr/bin/ruby${RUBY_MAJOR} 51 \ 26 | --slave /usr/bin/erb erb /usr/bin/erb${RUBY_MAJOR} \ 27 | --slave /usr/bin/irb irb /usr/bin/irb${RUBY_MAJOR} \ 28 | --slave /usr/bin/rdoc rdoc /usr/bin/rdoc${RUBY_MAJOR} \ 29 | --slave /usr/bin/ri ri /usr/bin/ri${RUBY_MAJOR} \ 30 | && apt-get clean \ 31 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 32 | 33 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 34 | 35 | USER docker 36 | RUN passenger-config build-native-support 37 | 38 | # Nginx Configuration 39 | USER root 40 | 41 | COPY entrypoint /usr/src/entrypoint 42 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 43 | COPY main.d/* /usr/src/nginx/main.d/ 44 | RUN mkdir -p /usr/src/nginx/conf.d \ 45 | && mkdir -p /usr/src/nginx/location.d \ 46 | && mkdir -p /usr/src/nginx/main.d \ 47 | && mkdir -p /usr/src/nginx/server.d \ 48 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 49 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 50 | && chown docker:docker -R /usr/src/nginx 51 | 52 | USER docker 53 | 54 | EXPOSE 80 55 | CMD ["/tini", "--", "/usr/src/entrypoint"] 56 | -------------------------------------------------------------------------------- /ruby-passenger/3.3/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/3.3/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby-passenger/3.4-jammy/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/3.4-jammy/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby-passenger/3.4/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby-passenger` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/ruby:3.4 7 | LABEL org.opencontainers.image.authors="Instructure" 8 | 9 | USER root 10 | 11 | # Install Nginx with Passenger from official repository 12 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 13 | && apt-get install -y apt-transport-https ca-certificates \ 14 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger focal main > /etc/apt/sources.list.d/passenger.list 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | nginx-extras \ 19 | sudo \ 20 | passenger \ 21 | libnginx-mod-http-passenger \ 22 | # libnginx-mod-http-passenger in bionic destroys the alternatives in the base ruby image 23 | && update-alternatives --install /usr/bin/gem gem /usr/bin/gem$RUBY_MAJOR 181 \ 24 | && update-alternatives \ 25 | --install /usr/bin/ruby ruby /usr/bin/ruby${RUBY_MAJOR} 51 \ 26 | --slave /usr/bin/erb erb /usr/bin/erb${RUBY_MAJOR} \ 27 | --slave /usr/bin/irb irb /usr/bin/irb${RUBY_MAJOR} \ 28 | --slave /usr/bin/rdoc rdoc /usr/bin/rdoc${RUBY_MAJOR} \ 29 | --slave /usr/bin/ri ri /usr/bin/ri${RUBY_MAJOR} \ 30 | && apt-get clean \ 31 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 32 | 33 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 34 | 35 | USER docker 36 | RUN passenger-config build-native-support 37 | 38 | # Nginx Configuration 39 | USER root 40 | 41 | COPY entrypoint /usr/src/entrypoint 42 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 43 | COPY main.d/* /usr/src/nginx/main.d/ 44 | RUN mkdir -p /usr/src/nginx/conf.d \ 45 | && mkdir -p /usr/src/nginx/location.d \ 46 | && mkdir -p /usr/src/nginx/main.d \ 47 | && mkdir -p /usr/src/nginx/server.d \ 48 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 49 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 50 | && chown docker:docker -R /usr/src/nginx 51 | 52 | USER docker 53 | 54 | EXPOSE 80 55 | CMD ["/tini", "--", "/usr/src/entrypoint"] 56 | -------------------------------------------------------------------------------- /ruby-passenger/3.4/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/3.4/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby-passenger/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | <%= from_image(base_image) %> 3 | LABEL org.opencontainers.image.authors="Instructure" 4 | 5 | USER root 6 | 7 | # Install Nginx with Passenger from official repository 8 | RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 \ 9 | && apt-get install -y apt-transport-https ca-certificates \ 10 | && echo deb https://oss-binaries.phusionpassenger.com/apt/passenger <%= base_distro %> main > /etc/apt/sources.list.d/passenger.list 11 | 12 | RUN apt-get update \ 13 | && apt-get install -y --no-install-recommends \ 14 | nginx-extras \ 15 | sudo \ 16 | passenger<%= passenger_version ? "=#{passenger_version}" : "" %> \ 17 | libnginx-mod-http-passenger<%= passenger_version ? "=#{passenger_version}" : "" %> \ 18 | # libnginx-mod-http-passenger in bionic destroys the alternatives in the base ruby image 19 | && update-alternatives --install /usr/bin/gem gem /usr/bin/gem$RUBY_MAJOR 181 \ 20 | && update-alternatives \ 21 | --install /usr/bin/ruby ruby /usr/bin/ruby${RUBY_MAJOR} 51 \ 22 | --slave /usr/bin/erb erb /usr/bin/erb${RUBY_MAJOR} \ 23 | --slave /usr/bin/irb irb /usr/bin/irb${RUBY_MAJOR} \ 24 | --slave /usr/bin/rdoc rdoc /usr/bin/rdoc${RUBY_MAJOR} \ 25 | --slave /usr/bin/ri ri /usr/bin/ri${RUBY_MAJOR} \ 26 | && apt-get clean \ 27 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* 28 | 29 | RUN echo 'docker ALL=(ALL) NOPASSWD: SETENV: /usr/sbin/nginx' >> /etc/sudoers 30 | 31 | USER docker 32 | RUN passenger-config build-native-support 33 | 34 | # Nginx Configuration 35 | USER root 36 | 37 | COPY entrypoint /usr/src/entrypoint 38 | COPY nginx.conf.erb /usr/src/nginx/nginx.conf.erb 39 | COPY main.d/* /usr/src/nginx/main.d/ 40 | RUN mkdir -p /usr/src/nginx/conf.d \ 41 | && mkdir -p /usr/src/nginx/location.d \ 42 | && mkdir -p /usr/src/nginx/main.d \ 43 | && mkdir -p /usr/src/nginx/server.d \ 44 | && ln -sf /dev/stdout /var/log/nginx/access.log \ 45 | && ln -sf /dev/stderr /var/log/nginx/error.log \ 46 | && chown docker:docker -R /usr/src/nginx 47 | 48 | USER docker 49 | 50 | EXPOSE 80 51 | CMD ["/tini", "--", "/usr/src/entrypoint"] 52 | -------------------------------------------------------------------------------- /ruby-passenger/template/entrypoint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | for file in /usr/src/nginx/{,**/}*.erb; do 5 | if [ -f "$file" ]; then 6 | # don't overwrite an existing destination file 7 | if [ ! -e "${file%.*}" ]; then 8 | erb -T- "$file" > "${file%.*}" 9 | echo "${file%.*}: generated." 10 | else 11 | >&2 echo "${file%.*}: SKIPPED! refusing to overwrite existing file." 12 | fi 13 | fi 14 | done 15 | 16 | exec sudo -E /usr/sbin/nginx -c /usr/src/nginx/nginx.conf 17 | -------------------------------------------------------------------------------- /ruby-passenger/template/main.d/env.conf.erb: -------------------------------------------------------------------------------- 1 | <% ENV.each do |k, _| -%> 2 | env <%= k %>; 3 | <% end -%> 4 | -------------------------------------------------------------------------------- /ruby/3.0-jammy/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | MAINTAINER Instructure 8 | 9 | ENV RUBY_MAJOR 3.0 10 | 11 | USER root 12 | RUN mkdir -p /usr/src/app 13 | RUN chown docker:docker /usr/src/app 14 | 15 | RUN apt-get update \ 16 | && apt-get install -y --no-install-recommends \ 17 | software-properties-common \ 18 | && apt-add-repository -y ppa:instructure/ruby \ 19 | && apt-get update \ 20 | && apt-get install -y \ 21 | ruby$RUBY_MAJOR \ 22 | ruby$RUBY_MAJOR-dev \ 23 | make \ 24 | imagemagick \ 25 | libbz2-dev \ 26 | libcurl4-openssl-dev \ 27 | libevent-dev \ 28 | libffi-dev \ 29 | libglib2.0-dev \ 30 | libjpeg-dev \ 31 | libmagickcore-dev \ 32 | libmagickwand-dev \ 33 | libmysqlclient-dev \ 34 | libncurses-dev \ 35 | libpq-dev \ 36 | libreadline-dev \ 37 | libsqlite3-dev \ 38 | libssl-dev \ 39 | libxml2-dev \ 40 | libxslt-dev \ 41 | libyaml-dev \ 42 | zlib1g-dev \ 43 | && apt-add-repository -y --remove ppa:instructure/ruby \ 44 | && apt-get clean \ 45 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 46 | # On newer rubygems-integration the deb-installed rubygems cannot be updated outside apt's processes 47 | # so only try to upgrade the bundler version 48 | && gem install --no-document -i /var/lib/gems/$RUBY_MAJOR.0 bundler -v 2.2.6 49 | 50 | ENV BUNDLE_APP_CONFIG /home/docker/.bundle 51 | 52 | USER docker 53 | RUN echo 'gem: --no-document' >> /home/docker/.gemrc \ 54 | && mkdir -p /home/docker/.gem/ruby/$RUBY_MAJOR.0/build_info \ 55 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/cache \ 56 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/doc \ 57 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/extensions \ 58 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/gems \ 59 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/specifications 60 | ENV GEM_HOME /home/docker/.gem/ruby/$RUBY_MAJOR.0 61 | ENV PATH $GEM_HOME/bin:$PATH 62 | WORKDIR /usr/src/app 63 | -------------------------------------------------------------------------------- /ruby/3.0/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:focal 7 | MAINTAINER Instructure 8 | 9 | ENV RUBY_MAJOR 3.0 10 | 11 | USER root 12 | RUN mkdir -p /usr/src/app 13 | RUN chown docker:docker /usr/src/app 14 | 15 | RUN apt-get update \ 16 | && apt-get install -y --no-install-recommends \ 17 | software-properties-common \ 18 | && apt-add-repository -y ppa:instructure/ruby \ 19 | && apt-get update \ 20 | && apt-get install -y \ 21 | ruby$RUBY_MAJOR \ 22 | ruby$RUBY_MAJOR-dev \ 23 | make \ 24 | imagemagick \ 25 | libbz2-dev \ 26 | libcurl4-openssl-dev \ 27 | libevent-dev \ 28 | libffi-dev \ 29 | libglib2.0-dev \ 30 | libjpeg-dev \ 31 | libmagickcore-dev \ 32 | libmagickwand-dev \ 33 | libmysqlclient-dev \ 34 | libncurses-dev \ 35 | libpq-dev \ 36 | libreadline-dev \ 37 | libsqlite3-dev \ 38 | libssl-dev \ 39 | libxml2-dev \ 40 | libxslt-dev \ 41 | libyaml-dev \ 42 | zlib1g-dev \ 43 | && apt-add-repository -y --remove ppa:instructure/ruby \ 44 | && apt-get clean \ 45 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 46 | # On newer rubygems-integration the deb-installed rubygems cannot be updated outside apt's processes 47 | # so only try to upgrade the bundler version 48 | && gem install --no-document -i /var/lib/gems/$RUBY_MAJOR.0 bundler -v 2.2.6 49 | 50 | ENV BUNDLE_APP_CONFIG /home/docker/.bundle 51 | 52 | USER docker 53 | RUN echo 'gem: --no-document' >> /home/docker/.gemrc \ 54 | && mkdir -p /home/docker/.gem/ruby/$RUBY_MAJOR.0/build_info \ 55 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/cache \ 56 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/doc \ 57 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/extensions \ 58 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/gems \ 59 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/specifications 60 | ENV GEM_HOME /home/docker/.gem/ruby/$RUBY_MAJOR.0 61 | ENV PATH $GEM_HOME/bin:$PATH 62 | WORKDIR /usr/src/app 63 | -------------------------------------------------------------------------------- /ruby/3.1-jammy/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | MAINTAINER Instructure 8 | 9 | ENV RUBY_MAJOR 3.1 10 | 11 | USER root 12 | RUN mkdir -p /usr/src/app 13 | RUN chown docker:docker /usr/src/app 14 | 15 | RUN apt-get update \ 16 | && apt-get install -y --no-install-recommends \ 17 | software-properties-common \ 18 | && apt-add-repository -y ppa:instructure/ruby \ 19 | && apt-get update \ 20 | && apt-get install -y \ 21 | ruby$RUBY_MAJOR \ 22 | ruby$RUBY_MAJOR-dev \ 23 | make \ 24 | imagemagick \ 25 | libbz2-dev \ 26 | libcurl4-openssl-dev \ 27 | libevent-dev \ 28 | libffi-dev \ 29 | libglib2.0-dev \ 30 | libjpeg-dev \ 31 | libmagickcore-dev \ 32 | libmagickwand-dev \ 33 | libmysqlclient-dev \ 34 | libncurses-dev \ 35 | libpq-dev \ 36 | libreadline-dev \ 37 | libsqlite3-dev \ 38 | libssl-dev \ 39 | libxml2-dev \ 40 | libxslt-dev \ 41 | libyaml-dev \ 42 | zlib1g-dev \ 43 | && apt-add-repository -y --remove ppa:instructure/ruby \ 44 | && apt-get clean \ 45 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 46 | # On newer rubygems-integration the deb-installed rubygems cannot be updated outside apt's processes 47 | # so only try to upgrade the bundler version 48 | && gem install --no-document -i /var/lib/gems/$RUBY_MAJOR.0 bundler -v 2.2.6 49 | 50 | ENV BUNDLE_APP_CONFIG /home/docker/.bundle 51 | 52 | USER docker 53 | RUN echo 'gem: --no-document' >> /home/docker/.gemrc \ 54 | && mkdir -p /home/docker/.gem/ruby/$RUBY_MAJOR.0/build_info \ 55 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/cache \ 56 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/doc \ 57 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/extensions \ 58 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/gems \ 59 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/specifications 60 | ENV GEM_HOME /home/docker/.gem/ruby/$RUBY_MAJOR.0 61 | ENV PATH $GEM_HOME/bin:$PATH 62 | WORKDIR /usr/src/app 63 | -------------------------------------------------------------------------------- /ruby/3.1/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:focal 7 | MAINTAINER Instructure 8 | 9 | ENV RUBY_MAJOR 3.1 10 | 11 | USER root 12 | RUN mkdir -p /usr/src/app 13 | RUN chown docker:docker /usr/src/app 14 | 15 | RUN apt-get update \ 16 | && apt-get install -y --no-install-recommends \ 17 | software-properties-common \ 18 | && apt-add-repository -y ppa:instructure/ruby \ 19 | && apt-get update \ 20 | && apt-get install -y \ 21 | ruby$RUBY_MAJOR \ 22 | ruby$RUBY_MAJOR-dev \ 23 | make \ 24 | imagemagick \ 25 | libbz2-dev \ 26 | libcurl4-openssl-dev \ 27 | libevent-dev \ 28 | libffi-dev \ 29 | libglib2.0-dev \ 30 | libjpeg-dev \ 31 | libmagickcore-dev \ 32 | libmagickwand-dev \ 33 | libmysqlclient-dev \ 34 | libncurses-dev \ 35 | libpq-dev \ 36 | libreadline-dev \ 37 | libsqlite3-dev \ 38 | libssl-dev \ 39 | libxml2-dev \ 40 | libxslt-dev \ 41 | libyaml-dev \ 42 | zlib1g-dev \ 43 | && apt-add-repository -y --remove ppa:instructure/ruby \ 44 | && apt-get clean \ 45 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 46 | # On newer rubygems-integration the deb-installed rubygems cannot be updated outside apt's processes 47 | # so only try to upgrade the bundler version 48 | && gem install --no-document -i /var/lib/gems/$RUBY_MAJOR.0 bundler -v 2.2.6 49 | 50 | ENV BUNDLE_APP_CONFIG /home/docker/.bundle 51 | 52 | USER docker 53 | RUN echo 'gem: --no-document' >> /home/docker/.gemrc \ 54 | && mkdir -p /home/docker/.gem/ruby/$RUBY_MAJOR.0/build_info \ 55 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/cache \ 56 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/doc \ 57 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/extensions \ 58 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/gems \ 59 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/specifications 60 | ENV GEM_HOME /home/docker/.gem/ruby/$RUBY_MAJOR.0 61 | ENV PATH $GEM_HOME/bin:$PATH 62 | WORKDIR /usr/src/app 63 | -------------------------------------------------------------------------------- /ruby/3.2-jammy/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | MAINTAINER Instructure 8 | 9 | ENV RUBY_MAJOR 3.2 10 | 11 | USER root 12 | RUN mkdir -p /usr/src/app 13 | RUN chown docker:docker /usr/src/app 14 | 15 | RUN apt-get update \ 16 | && apt-get install -y --no-install-recommends \ 17 | software-properties-common \ 18 | && apt-add-repository -y ppa:instructure/ruby \ 19 | && apt-get update \ 20 | && apt-get install -y \ 21 | ruby$RUBY_MAJOR \ 22 | ruby$RUBY_MAJOR-dev \ 23 | make \ 24 | imagemagick \ 25 | libbz2-dev \ 26 | libcurl4-openssl-dev \ 27 | libevent-dev \ 28 | libffi-dev \ 29 | libglib2.0-dev \ 30 | libjpeg-dev \ 31 | libmagickcore-dev \ 32 | libmagickwand-dev \ 33 | libmysqlclient-dev \ 34 | libncurses-dev \ 35 | libpq-dev \ 36 | libreadline-dev \ 37 | libsqlite3-dev \ 38 | libssl-dev \ 39 | libxml2-dev \ 40 | libxslt-dev \ 41 | libyaml-dev \ 42 | zlib1g-dev \ 43 | && apt-add-repository -y --remove ppa:instructure/ruby \ 44 | && apt-get clean \ 45 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 46 | # On newer rubygems-integration the deb-installed rubygems cannot be updated outside apt's processes 47 | # so only try to upgrade the bundler version 48 | && gem install --no-document -i /var/lib/gems/$RUBY_MAJOR.0 bundler -v 2.2.6 49 | 50 | ENV BUNDLE_APP_CONFIG /home/docker/.bundle 51 | 52 | USER docker 53 | RUN echo 'gem: --no-document' >> /home/docker/.gemrc \ 54 | && mkdir -p /home/docker/.gem/ruby/$RUBY_MAJOR.0/build_info \ 55 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/cache \ 56 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/doc \ 57 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/extensions \ 58 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/gems \ 59 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/specifications 60 | ENV GEM_HOME /home/docker/.gem/ruby/$RUBY_MAJOR.0 61 | ENV PATH $GEM_HOME/bin:$PATH 62 | WORKDIR /usr/src/app 63 | -------------------------------------------------------------------------------- /ruby/3.2/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:focal 7 | MAINTAINER Instructure 8 | 9 | ENV RUBY_MAJOR 3.2 10 | 11 | USER root 12 | RUN mkdir -p /usr/src/app 13 | RUN chown docker:docker /usr/src/app 14 | 15 | RUN apt-get update \ 16 | && apt-get install -y --no-install-recommends \ 17 | software-properties-common \ 18 | && apt-add-repository -y ppa:instructure/ruby \ 19 | && apt-get update \ 20 | && apt-get install -y \ 21 | ruby$RUBY_MAJOR \ 22 | ruby$RUBY_MAJOR-dev \ 23 | make \ 24 | imagemagick \ 25 | libbz2-dev \ 26 | libcurl4-openssl-dev \ 27 | libevent-dev \ 28 | libffi-dev \ 29 | libglib2.0-dev \ 30 | libjpeg-dev \ 31 | libmagickcore-dev \ 32 | libmagickwand-dev \ 33 | libmysqlclient-dev \ 34 | libncurses-dev \ 35 | libpq-dev \ 36 | libreadline-dev \ 37 | libsqlite3-dev \ 38 | libssl-dev \ 39 | libxml2-dev \ 40 | libxslt-dev \ 41 | libyaml-dev \ 42 | zlib1g-dev \ 43 | && apt-add-repository -y --remove ppa:instructure/ruby \ 44 | && apt-get clean \ 45 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 46 | # On newer rubygems-integration the deb-installed rubygems cannot be updated outside apt's processes 47 | # so only try to upgrade the bundler version 48 | && gem install --no-document -i /var/lib/gems/$RUBY_MAJOR.0 bundler -v 2.2.6 49 | 50 | ENV BUNDLE_APP_CONFIG /home/docker/.bundle 51 | 52 | USER docker 53 | RUN echo 'gem: --no-document' >> /home/docker/.gemrc \ 54 | && mkdir -p /home/docker/.gem/ruby/$RUBY_MAJOR.0/build_info \ 55 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/cache \ 56 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/doc \ 57 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/extensions \ 58 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/gems \ 59 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/specifications 60 | ENV GEM_HOME /home/docker/.gem/ruby/$RUBY_MAJOR.0 61 | ENV PATH $GEM_HOME/bin:$PATH 62 | WORKDIR /usr/src/app 63 | -------------------------------------------------------------------------------- /ruby/3.3-jammy/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | MAINTAINER Instructure 8 | ENV CACHE_BUST 2024-06-24 9 | 10 | ENV RUBY_MAJOR 3.3 11 | 12 | USER root 13 | RUN mkdir -p /usr/src/app 14 | RUN chown docker:docker /usr/src/app 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | software-properties-common \ 19 | && apt-add-repository -y ppa:instructure/ruby \ 20 | && apt-get update \ 21 | && apt-get install -y \ 22 | ruby$RUBY_MAJOR \ 23 | ruby$RUBY_MAJOR-dev \ 24 | make \ 25 | imagemagick \ 26 | libbz2-dev \ 27 | libcurl4-openssl-dev \ 28 | libevent-dev \ 29 | libffi-dev \ 30 | libglib2.0-dev \ 31 | libjpeg-dev \ 32 | libmagickcore-dev \ 33 | libmagickwand-dev \ 34 | libmysqlclient-dev \ 35 | libncurses-dev \ 36 | libpq-dev \ 37 | libreadline-dev \ 38 | libsqlite3-dev \ 39 | libssl-dev \ 40 | libxml2-dev \ 41 | libxslt-dev \ 42 | libyaml-dev \ 43 | zlib1g-dev \ 44 | && apt-add-repository -y --remove ppa:instructure/ruby \ 45 | && apt-get clean \ 46 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 47 | # On newer rubygems-integration the deb-installed rubygems cannot be updated outside apt's processes 48 | # so only try to upgrade the bundler version 49 | && gem install --no-document -i /var/lib/gems/$RUBY_MAJOR.0 bundler -v 2.5.3 50 | 51 | ENV BUNDLE_APP_CONFIG /home/docker/.bundle 52 | 53 | USER docker 54 | RUN echo 'gem: --no-document' >> /home/docker/.gemrc \ 55 | && mkdir -p /home/docker/.gem/ruby/$RUBY_MAJOR.0/build_info \ 56 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/cache \ 57 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/doc \ 58 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/extensions \ 59 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/gems \ 60 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/specifications 61 | ENV GEM_HOME /home/docker/.gem/ruby/$RUBY_MAJOR.0 62 | ENV PATH $GEM_HOME/bin:$PATH 63 | WORKDIR /usr/src/app 64 | -------------------------------------------------------------------------------- /ruby/3.3/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:focal 7 | MAINTAINER Instructure 8 | ENV CACHE_BUST 2024-06-24 9 | 10 | ENV RUBY_MAJOR 3.3 11 | 12 | USER root 13 | RUN mkdir -p /usr/src/app 14 | RUN chown docker:docker /usr/src/app 15 | 16 | RUN apt-get update \ 17 | && apt-get install -y --no-install-recommends \ 18 | software-properties-common \ 19 | && apt-add-repository -y ppa:instructure/ruby \ 20 | && apt-get update \ 21 | && apt-get install -y \ 22 | ruby$RUBY_MAJOR \ 23 | ruby$RUBY_MAJOR-dev \ 24 | make \ 25 | imagemagick \ 26 | libbz2-dev \ 27 | libcurl4-openssl-dev \ 28 | libevent-dev \ 29 | libffi-dev \ 30 | libglib2.0-dev \ 31 | libjpeg-dev \ 32 | libmagickcore-dev \ 33 | libmagickwand-dev \ 34 | libmysqlclient-dev \ 35 | libncurses-dev \ 36 | libpq-dev \ 37 | libreadline-dev \ 38 | libsqlite3-dev \ 39 | libssl-dev \ 40 | libxml2-dev \ 41 | libxslt-dev \ 42 | libyaml-dev \ 43 | zlib1g-dev \ 44 | && apt-add-repository -y --remove ppa:instructure/ruby \ 45 | && apt-get clean \ 46 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 47 | # On newer rubygems-integration the deb-installed rubygems cannot be updated outside apt's processes 48 | # so only try to upgrade the bundler version 49 | && gem install --no-document -i /var/lib/gems/$RUBY_MAJOR.0 bundler -v 2.5.3 50 | 51 | ENV BUNDLE_APP_CONFIG /home/docker/.bundle 52 | 53 | USER docker 54 | RUN echo 'gem: --no-document' >> /home/docker/.gemrc \ 55 | && mkdir -p /home/docker/.gem/ruby/$RUBY_MAJOR.0/build_info \ 56 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/cache \ 57 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/doc \ 58 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/extensions \ 59 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/gems \ 60 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/specifications 61 | ENV GEM_HOME /home/docker/.gem/ruby/$RUBY_MAJOR.0 62 | ENV PATH $GEM_HOME/bin:$PATH 63 | WORKDIR /usr/src/app 64 | -------------------------------------------------------------------------------- /ruby/3.4-jammy/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:jammy 7 | MAINTAINER Instructure 8 | 9 | ENV RUBY_MAJOR 3.4 10 | 11 | USER root 12 | RUN mkdir -p /usr/src/app 13 | RUN chown docker:docker /usr/src/app 14 | 15 | RUN apt-get update \ 16 | && apt-get install -y --no-install-recommends \ 17 | software-properties-common \ 18 | && apt-add-repository -y ppa:instructure/ruby \ 19 | && apt-get update \ 20 | && apt-get install -y \ 21 | ruby$RUBY_MAJOR \ 22 | ruby$RUBY_MAJOR-dev \ 23 | make \ 24 | imagemagick \ 25 | libbz2-dev \ 26 | libcurl4-openssl-dev \ 27 | libevent-dev \ 28 | libffi-dev \ 29 | libglib2.0-dev \ 30 | libjpeg-dev \ 31 | libmagickcore-dev \ 32 | libmagickwand-dev \ 33 | libmysqlclient-dev \ 34 | libncurses-dev \ 35 | libpq-dev \ 36 | libreadline-dev \ 37 | libsqlite3-dev \ 38 | libssl-dev \ 39 | libxml2-dev \ 40 | libxslt-dev \ 41 | libyaml-dev \ 42 | zlib1g-dev \ 43 | && apt-add-repository -y --remove ppa:instructure/ruby \ 44 | && apt-get clean \ 45 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 46 | # On newer rubygems-integration the deb-installed rubygems cannot be updated outside apt's processes 47 | # so only try to upgrade the bundler version 48 | && gem install --no-document -i /var/lib/gems/$RUBY_MAJOR.0 bundler -v 2.6.3 49 | 50 | ENV BUNDLE_APP_CONFIG /home/docker/.bundle 51 | 52 | USER docker 53 | RUN echo 'gem: --no-document' >> /home/docker/.gemrc \ 54 | && mkdir -p /home/docker/.gem/ruby/$RUBY_MAJOR.0/build_info \ 55 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/cache \ 56 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/doc \ 57 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/extensions \ 58 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/gems \ 59 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/specifications 60 | ENV GEM_HOME /home/docker/.gem/ruby/$RUBY_MAJOR.0 61 | ENV PATH $GEM_HOME/bin:$PATH 62 | WORKDIR /usr/src/app 63 | -------------------------------------------------------------------------------- /ruby/3.4/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:ruby` 4 | 5 | ARG ROOT_PATH=instructure 6 | FROM --platform=${TARGETPLATFORM} ${ROOT_PATH}/core:focal 7 | MAINTAINER Instructure 8 | 9 | ENV RUBY_MAJOR 3.4 10 | 11 | USER root 12 | RUN mkdir -p /usr/src/app 13 | RUN chown docker:docker /usr/src/app 14 | 15 | RUN apt-get update \ 16 | && apt-get install -y --no-install-recommends \ 17 | software-properties-common \ 18 | && apt-add-repository -y ppa:instructure/ruby \ 19 | && apt-get update \ 20 | && apt-get install -y \ 21 | ruby$RUBY_MAJOR \ 22 | ruby$RUBY_MAJOR-dev \ 23 | make \ 24 | imagemagick \ 25 | libbz2-dev \ 26 | libcurl4-openssl-dev \ 27 | libevent-dev \ 28 | libffi-dev \ 29 | libglib2.0-dev \ 30 | libjpeg-dev \ 31 | libmagickcore-dev \ 32 | libmagickwand-dev \ 33 | libmysqlclient-dev \ 34 | libncurses-dev \ 35 | libpq-dev \ 36 | libreadline-dev \ 37 | libsqlite3-dev \ 38 | libssl-dev \ 39 | libxml2-dev \ 40 | libxslt-dev \ 41 | libyaml-dev \ 42 | zlib1g-dev \ 43 | && apt-add-repository -y --remove ppa:instructure/ruby \ 44 | && apt-get clean \ 45 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ \ 46 | # On newer rubygems-integration the deb-installed rubygems cannot be updated outside apt's processes 47 | # so only try to upgrade the bundler version 48 | && gem install --no-document -i /var/lib/gems/$RUBY_MAJOR.0 bundler -v 2.6.3 49 | 50 | ENV BUNDLE_APP_CONFIG /home/docker/.bundle 51 | 52 | USER docker 53 | RUN echo 'gem: --no-document' >> /home/docker/.gemrc \ 54 | && mkdir -p /home/docker/.gem/ruby/$RUBY_MAJOR.0/build_info \ 55 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/cache \ 56 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/doc \ 57 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/extensions \ 58 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/gems \ 59 | /home/docker/.gem/ruby/$RUBY_MAJOR.0/specifications 60 | ENV GEM_HOME /home/docker/.gem/ruby/$RUBY_MAJOR.0 61 | ENV PATH $GEM_HOME/bin:$PATH 62 | WORKDIR /usr/src/app 63 | -------------------------------------------------------------------------------- /ruby/README.md: -------------------------------------------------------------------------------- 1 | # Introduction 2 | Your one-stop-shop for Instructure official Docker/Ruby love. If you 3 | need ruby (2.1, 2.2, or 2.3) in Docker but don't need web services (we've 4 | got `instructure/ruby-passenger` for that) you're in the right place. 5 | Batteries (finicky C libs, see Dockerfile for full listing) are 6 | included, so drop your app in (we suggest /usr/src/app) and start hacking. 7 | 8 | # Making changes 9 | Aside from the RVM image all of these files are generated using a Rake task 10 | (generate:ruby) from the Dockerfile in the template directory. If you need to 11 | make changes, make them to the template and then run the generation task. 12 | 13 | # RVM 14 | Included in this directory is a Dockerfile that installs RVM and all three 15 | supported ruby versions. This setup is intended for use in CI environments 16 | testing gems against multiple ruby versions. Sadly, due to the way RVM works 17 | you'll need to run most commands with the -l flag supplied to bash to ensure 18 | RVM works as you expect. 19 | -------------------------------------------------------------------------------- /scala-sbt/1.5/Dockerfile: -------------------------------------------------------------------------------- 1 | # GENERATED FILE, DO NOT MODIFY! 2 | # To update this file please edit the relevant template and run the generation 3 | # task `rake generate:scala-sbt` 4 | 5 | FROM instructure/java:16 6 | MAINTAINER Instructure Engineering 7 | USER root 8 | 9 | RUN echo 'deb https://repo.scala-sbt.org/scalasbt/debian all main' > /etc/apt/sources.list.d/sbt.list && \ 10 | echo 'deb https://repo.scala-sbt.org/scalasbt/debian /' > /etc/apt/sources.list.d/sbt_old.list && \ 11 | apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 \ 12 | --recv 2EE0EA64E40A89B84B2DF73499E82A75642AC823 13 | 14 | 15 | ARG SBT_VERSION=1.5.5 16 | RUN apt-get update && \ 17 | apt-get install -y --no-install-recommends bc sbt=$SBT_VERSION && \ 18 | apt-get clean autoremove -y && \ 19 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /root/.sbt /root/.ivy2 20 | 21 | COPY sbt-private /usr/local/bin 22 | RUN chmod 755 /usr/local/bin/sbt-private && \ 23 | mkdir -p /usr/src/app && \ 24 | chown docker:docker /usr/src/app 25 | WORKDIR /usr/src/app 26 | USER docker 27 | -------------------------------------------------------------------------------- /scala-sbt/1.5/sbt-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # GENERATED FILE, DO NOT MODIFY! 3 | # To update this file please edit the relevant template and run the generation 4 | # task `rake generate:scala-sbt` 5 | 6 | SBT_MINOR_VERSION=1.5 7 | SBT_MAJOR_VERSION=1.0 8 | SBT_CONF_DIR=$HOME/.sbt/$SBT_MAJOR_VERSION 9 | USER_FILE=$SBT_CONF_DIR/users.sbt 10 | 11 | mkdir -p $SBT_CONF_DIR 12 | 13 | if [ -n "$MAVEN_PRIVATE_HOSTNAME" ] && [ -n "$MAVEN_PRIVATE_USERNAME" ] && [ -n "$MAVEN_PRIVATE_PASSWORD" ]; then 14 | echo "credentials += Credentials(\"Artifactory Realm\", \"$MAVEN_PRIVATE_HOSTNAME\", \"$MAVEN_PRIVATE_USERNAME\", \"$MAVEN_PRIVATE_PASSWORD\")" > $USER_FILE 15 | fi 16 | 17 | # Run the SBT command with the credentials which have been added above. 18 | sbt "$@" 19 | EXIT_CODE=$? 20 | 21 | [ -e "$USER_FILE" ] && rm $USER_FILE 22 | exit $EXIT_CODE 23 | -------------------------------------------------------------------------------- /scala-sbt/README.md: -------------------------------------------------------------------------------- 1 | # SBT 2 | 3 | This is a base docker image for building SBT based projects. 4 | 5 | Includes a wrapper around __sbt__ named __sbt-private__ for the purpose of providing artifactory credentials from the environment at runtime. 6 | 7 | ## Tags 8 | 9 | Available tags are `0.13` and `1.0`, which point to the respective SBT minor versions. 10 | 11 | ## Usage 12 | 13 | Even with different tags, you can always use the any SBT version you want by specifying the SBT version you want to use in `project/build.properties` file. This is a valid pattern SBT 0.13.15 onwards. See [this link](http://www.scala-sbt.org/0.13/docs/Basic-Def.html) for more details. 14 | 15 | When using the image as a base for another image, always cache the SBT jars by running an SBT command (eg. `sbt clean`) in the directory where the `project/build.properties` file resides, if you're using it, or anywhere if you're not. Make sure you run the command as the user you will be using SBT with, as it will download the JARs to the user's home directory. 16 | 17 | ## Adding new versions 18 | 19 | Make changes to the `manifest.yml` file in the root of the project to add new versions. 20 | -------------------------------------------------------------------------------- /scala-sbt/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= generation_message %> 2 | FROM <%= base_image %> 3 | MAINTAINER Instructure Engineering 4 | USER root 5 | 6 | RUN echo 'deb https://repo.scala-sbt.org/scalasbt/debian all main' > /etc/apt/sources.list.d/sbt.list && \ 7 | echo 'deb https://repo.scala-sbt.org/scalasbt/debian /' > /etc/apt/sources.list.d/sbt_old.list && \ 8 | apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 \ 9 | --recv 2EE0EA64E40A89B84B2DF73499E82A75642AC823 10 | 11 | 12 | ARG SBT_VERSION=<%= full_version %> 13 | RUN apt-get update && \ 14 | apt-get install -y --no-install-recommends bc sbt=$SBT_VERSION && \ 15 | apt-get clean autoremove -y && \ 16 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /root/.sbt /root/.ivy2 17 | 18 | COPY sbt-private /usr/local/bin 19 | RUN chmod 755 /usr/local/bin/sbt-private && \ 20 | mkdir -p /usr/src/app && \ 21 | chown docker:docker /usr/src/app 22 | WORKDIR /usr/src/app 23 | USER docker 24 | -------------------------------------------------------------------------------- /scala-sbt/template/sbt-private: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | <%= generation_message %> 3 | SBT_MINOR_VERSION=<%= minor_version %> 4 | SBT_MAJOR_VERSION=<%= major_version %> 5 | SBT_CONF_DIR=$HOME/.sbt/$SBT_MAJOR_VERSION 6 | USER_FILE=$SBT_CONF_DIR/users.sbt 7 | 8 | mkdir -p $SBT_CONF_DIR 9 | 10 | if [ -n "$MAVEN_PRIVATE_HOSTNAME" ] && [ -n "$MAVEN_PRIVATE_USERNAME" ] && [ -n "$MAVEN_PRIVATE_PASSWORD" ]; then 11 | echo "credentials += Credentials(\"Artifactory Realm\", \"$MAVEN_PRIVATE_HOSTNAME\", \"$MAVEN_PRIVATE_USERNAME\", \"$MAVEN_PRIVATE_PASSWORD\")" > $USER_FILE 12 | fi 13 | 14 | # Run the SBT command with the credentials which have been added above. 15 | sbt "$@" 16 | EXIT_CODE=$? 17 | 18 | [ -e "$USER_FILE" ] && rm $USER_FILE 19 | exit $EXIT_CODE 20 | -------------------------------------------------------------------------------- /templates/node_install.Dockerfile: -------------------------------------------------------------------------------- 1 | ENV NODE_VERSION <%= node_version %> 2 | ENV NPM_VERSION <%= npm_version %> 3 | 4 | RUN mkdir -p /usr/src/app && chown docker:docker /usr/src/app 5 | WORKDIR /usr/src/app 6 | 7 | <% if node_version.to_i < 16 -%> 8 | <%# Non-active Node versions do not work with the new method (so far) -%> 9 | RUN curl -fsSL https://deb.nodesource.com/gpgkey/nodesource.gpg.key | gpg --dearmor | apt-key add - && \ 10 | echo "deb https://deb.nodesource.com/node_<%= node_version %>.x <%= base_distro %> main" > /etc/apt/sources.list.d/nodesource.list && \ 11 | apt-get update && \ 12 | apt-get install -y --no-install-recommends nodejs && \ 13 | apt-get clean && \ 14 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ && \ 15 | npm install -g "npm@$NPM_VERSION" && \ 16 | rm -rf /root/.npm/_cacache && \ 17 | npm cache clean --force 18 | <% else -%> 19 | RUN apt-get update && \ 20 | apt-get install -y curl && \ 21 | mkdir -p /etc/apt/keyrings && \ 22 | curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg && \ 23 | echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_<%= node_version %>.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list && \ 24 | apt-get update && \ 25 | apt-get install -y --no-install-recommends nodejs && \ 26 | apt-get clean && \ 27 | rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ && \ 28 | npm install -g "npm@$NPM_VERSION" && \ 29 | rm -rf /root/.npm/_cacache && \ 30 | npm cache clean --force 31 | <% end -%> 32 | 33 | COPY npm-private /usr/local/bin 34 | -------------------------------------------------------------------------------- /templates/yarn_install.Dockerfile: -------------------------------------------------------------------------------- 1 | ENV YARN_VERSION <%= yarn_version %> 2 | 3 | RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - \ 4 | && echo "" \ 5 | && echo "deb https://dl.yarnpkg.com/debian/ stable main" > /etc/apt/sources.list.d/yarn.list \ 6 | && apt-get update \ 7 | && apt-get install -y --no-install-recommends yarn<%= yarn_version == 'latest' ? '' : "=$YARN_VERSION"%> \ 8 | && apt-get clean \ 9 | && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/ 10 | 11 | COPY yarn-private /usr/local/bin 12 | -------------------------------------------------------------------------------- /tini/README.md: -------------------------------------------------------------------------------- 1 | # Tini 2 | 3 | This is an image to pull down and verify the `tini` binary before 4 | consuming it in a multi-stage build. 5 | 6 | ## Consuming 7 | 8 | The intended use is to consume this as a external multi-stage dependency 9 | without introducing any artifacts. 10 | 11 | For example: 12 | 13 | ```Dockerfile 14 | FROM instructure/tini: as tini 15 | 16 | FROM ... 17 | 18 | COPY --from=tini /tini /usr/local/bin/tini 19 | ... 20 | 21 | ``` 22 | -------------------------------------------------------------------------------- /tini/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= from_image(base_image) %> 2 | 3 | RUN apk add --no-cache \ 4 | gnupg 5 | 6 | # Install Tini for init use (reaps defunct processes and forwards signals) 7 | 8 | RUN apkArch="$(apk --print-arch)"; \ 9 | case "$apkArch" in \ 10 | aarch64) export PLATFORM='-arm64' ;; \ 11 | x86_64) export PLATFORM='' ;; \ 12 | esac; \ 13 | wget -O /tini https://github.com/krallin/tini/releases/download/<%= version %>/tini$PLATFORM ;\ 14 | wget -O /tini.asc https://github.com/krallin/tini/releases/download/<%= version %>/tini$PLATFORM.asc 15 | 16 | ARG KEYSERVERS="ipv4.pool.sks-keyservers.net pgp.mit.edu keyserver.ubuntu.com" 17 | RUN \ 18 | set -ex; \ 19 | for ks in ${KEYSERVERS}; do gpg --no-tty --keyserver "${ks}" --recv-keys <%= gpg_key %> && break; done \ 20 | && gpg --no-tty --batch --verify /tini.asc /tini \ 21 | && chmod +x /tini 22 | -------------------------------------------------------------------------------- /tini/v0.16.1/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM alpine 2 | 3 | RUN apk add --no-cache \ 4 | gnupg 5 | 6 | # Install Tini for init use (reaps defunct processes and forwards signals) 7 | 8 | RUN apkArch="$(apk --print-arch)"; \ 9 | case "$apkArch" in \ 10 | aarch64) export PLATFORM='-arm64' ;; \ 11 | x86_64) export PLATFORM='' ;; \ 12 | esac; \ 13 | wget -O /tini https://github.com/krallin/tini/releases/download/v0.16.1/tini$PLATFORM ;\ 14 | wget -O /tini.asc https://github.com/krallin/tini/releases/download/v0.16.1/tini$PLATFORM.asc 15 | 16 | ARG KEYSERVERS="ipv4.pool.sks-keyservers.net pgp.mit.edu keyserver.ubuntu.com" 17 | RUN \ 18 | set -ex; \ 19 | for ks in ${KEYSERVERS}; do gpg --no-tty --keyserver "${ks}" --recv-keys 595E85A6B1B4779EA4DAAEC70B588DFF0527A9B7 && break; done \ 20 | && gpg --no-tty --batch --verify /tini.asc /tini \ 21 | && chmod +x /tini 22 | -------------------------------------------------------------------------------- /tini/v0.18.0/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM alpine 2 | 3 | RUN apk add --no-cache \ 4 | gnupg 5 | 6 | # Install Tini for init use (reaps defunct processes and forwards signals) 7 | 8 | RUN apkArch="$(apk --print-arch)"; \ 9 | case "$apkArch" in \ 10 | aarch64) export PLATFORM='-arm64' ;; \ 11 | x86_64) export PLATFORM='' ;; \ 12 | esac; \ 13 | wget -O /tini https://github.com/krallin/tini/releases/download/v0.18.0/tini$PLATFORM ;\ 14 | wget -O /tini.asc https://github.com/krallin/tini/releases/download/v0.18.0/tini$PLATFORM.asc 15 | 16 | ARG KEYSERVERS="ipv4.pool.sks-keyservers.net pgp.mit.edu keyserver.ubuntu.com" 17 | RUN \ 18 | set -ex; \ 19 | for ks in ${KEYSERVERS}; do gpg --no-tty --keyserver "${ks}" --recv-keys 595E85A6B1B4779EA4DAAEC70B588DFF0527A9B7 && break; done \ 20 | && gpg --no-tty --batch --verify /tini.asc /tini \ 21 | && chmod +x /tini 22 | -------------------------------------------------------------------------------- /tini/v0.19.0/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=${TARGETPLATFORM} alpine 2 | 3 | RUN apk add --no-cache \ 4 | gnupg 5 | 6 | # Install Tini for init use (reaps defunct processes and forwards signals) 7 | 8 | RUN apkArch="$(apk --print-arch)"; \ 9 | case "$apkArch" in \ 10 | aarch64) export PLATFORM='-arm64' ;; \ 11 | x86_64) export PLATFORM='' ;; \ 12 | esac; \ 13 | wget -O /tini https://github.com/krallin/tini/releases/download/v0.19.0/tini$PLATFORM ;\ 14 | wget -O /tini.asc https://github.com/krallin/tini/releases/download/v0.19.0/tini$PLATFORM.asc 15 | 16 | ARG KEYSERVERS="ipv4.pool.sks-keyservers.net pgp.mit.edu keyserver.ubuntu.com" 17 | RUN \ 18 | set -ex; \ 19 | for ks in ${KEYSERVERS}; do gpg --no-tty --keyserver "${ks}" --recv-keys 595E85A6B1B4779EA4DAAEC70B588DFF0527A9B7 && break; done \ 20 | && gpg --no-tty --batch --verify /tini.asc /tini \ 21 | && chmod +x /tini 22 | -------------------------------------------------------------------------------- /yq/4.44.1/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM --platform=${TARGETPLATFORM} alpine:3.20 2 | LABEL maintainer="Instructure" 3 | 4 | ENV YQ_VERSION="4.44.1" 5 | 6 | RUN apk update && \ 7 | apk add --no-cache "yq~${YQ_VERSION}" 8 | 9 | ENTRYPOINT ["yq"] 10 | -------------------------------------------------------------------------------- /yq/template/Dockerfile: -------------------------------------------------------------------------------- 1 | <%= from_image(base_image) %> 2 | LABEL maintainer="Instructure" 3 | 4 | ENV YQ_VERSION="<%= version %>" 5 | 6 | RUN apk update && \ 7 | apk add --no-cache "yq~${YQ_VERSION}" 8 | 9 | ENTRYPOINT ["yq"] 10 | --------------------------------------------------------------------------------