-
Notifications
You must be signed in to change notification settings - Fork 2
Upgrade nginx #24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upgrade nginx #24
Changes from all commits
e80e1d2
dbc6410
f191c47
dd004af
999f34c
3dc10a6
61b75b9
feb6c79
735fe92
b3af83a
26637c1
a041634
d1c449f
eda247b
fded32a
5d77a78
e906962
ffc025f
986e9cb
2c75c27
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,15 @@ | ||
| name: Build, Publish and Scan (Managed) | ||
| on: | ||
| workflow_dispatch: | ||
| push: | ||
| branches: ["main", "master", "develop"] | ||
| pull_request: | ||
| branches: ["main", "master", "develop"] | ||
| release: | ||
| types: [published] | ||
| jobs: | ||
| build-publish-scan: | ||
| uses: BERDataLakehouse/.github/.github/workflows/build_publish_scan.yaml@main | ||
|
bio-boris marked this conversation as resolved.
bio-boris marked this conversation as resolved.
|
||
| permissions: | ||
| contents: read | ||
| packages: write | ||
This file was deleted.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,51 +1,29 @@ | ||
| FROM openresty/openresty:buster | ||
|
|
||
| # These ARGs values are passed in via the docker build command | ||
| ARG BUILD_DATE | ||
| ARG VCS_REF | ||
| ARG BRANCH | ||
|
|
||
| COPY deployment/ /kb/deployment/ | ||
|
|
||
| #RUN cp /kb/deployment/conf/sources.list /etc/apt/sources.list && \ | ||
| RUN DEBIAN_FRONTEND=noninteractive apt-get update && \ | ||
| DEBIAN_FRONTEND=noninteractive apt-get upgrade -y && \ | ||
| DEBIAN_FRONTEND=noninteractive apt-get install -y \ | ||
| software-properties-common ca-certificates apt-transport-https curl net-tools wget | ||
|
|
||
| RUN rm -rf /etc/nginx && \ | ||
| ln -s /usr/local/openresty/nginx/conf /etc/nginx && \ | ||
| cd /etc/nginx && \ | ||
| mkdir ssl /var/log/nginx && \ | ||
| mkdir /usr/local/openresty/nginx/conf/conf.d && \ | ||
| openssl req -x509 -newkey rsa:4096 -keyout ssl/key.pem -out ssl/cert.pem -days 365 -nodes \ | ||
| -subj '/C=US/ST=California/L=Berkeley/O=Lawrence Berkeley National Lab/OU=KBase/CN=localhost' && \ | ||
| cd /tmp && \ | ||
| wget -N https://github.com/kbase/dockerize/raw/master/dockerize-linux-amd64-v0.6.1.tar.gz && \ | ||
| tar xvzf dockerize-linux-amd64-v0.6.1.tar.gz && \ | ||
| rm dockerize-linux-amd64-v0.6.1.tar.gz && \ | ||
| mv dockerize /kb/deployment/bin | ||
|
|
||
| COPY nginx-sites.d/ /usr/local/openresty/nginx/conf/sites-enabled | ||
|
|
||
|
|
||
| # The BUILD_DATE value seem to bust the docker cache when the timestamp changes, move to | ||
| # the end | ||
| LABEL org.label-schema.build-date=$BUILD_DATE \ | ||
| org.label-schema.vcs-url="https://github.com/kbase/nginx.git" \ | ||
| org.label-schema.vcs-ref=$VCS_REF \ | ||
| org.label-schema.schema-version="1.0.0-rc1" \ | ||
| us.kbase.vcs-branch=$BRANCH \ | ||
| maintainer="Steve Chan sychan@lbl.gov" | ||
|
|
||
|
|
||
| ENTRYPOINT [ "/kb/deployment/bin/dockerize" ] | ||
|
|
||
| # Here are some default params passed to dockerize. They would typically | ||
| # be overidden by docker-compose at startup | ||
| CMD [ "-template", "/kb/deployment/conf/.templates/openresty.conf.templ:/etc/nginx/nginx.conf", \ | ||
| "-template", "/kb/deployment/conf/.templates/minikb-narrative.templ:/etc/nginx/sites-enabled/minikb-narrative", \ | ||
| "-env", "/kb/deployment/conf/localhost.ini", \ | ||
| "-stdout", "/var/log/nginx/access.log", \ | ||
| "-stdout", "/var/log/nginx/error.log", \ | ||
| "nginx" ] | ||
| FROM openresty/openresty:1.29.2.4-alpine-fat@sha256:af355ebd6f01e580823b6718e8a2e39be3b45d9437fc92144e43ac72020f7461 | ||
|
kkellerlbl marked this conversation as resolved.
|
||
| ENV DEBIAN_FRONTEND=noninteractive | ||
|
bio-boris marked this conversation as resolved.
|
||
|
|
||
| COPY deployment /kb/deployment | ||
|
|
||
| RUN apk update && \ | ||
| apk upgrade && \ | ||
| apk add --no-cache \ | ||
| curl vim htop wget \ | ||
| pcre openssl zlib ca-certificates && \ | ||
| rm -rf /var/cache/apk/* | ||
|
bio-boris marked this conversation as resolved.
|
||
|
|
||
| RUN mkdir -p /etc/nginx/ssl /etc/nginx/conf.d /etc/nginx/sites-enabled /var/log/nginx && \ | ||
| touch /var/log/nginx/access.log /var/log/nginx/error.log | ||
|
bio-boris marked this conversation as resolved.
|
||
|
|
||
| RUN rm -f /usr/local/openresty/nginx/conf/nginx.conf \ | ||
| /etc/nginx/conf.d/default.conf | ||
|
|
||
| RUN ln -s /usr/local/openresty/nginx/conf/mime.types /etc/nginx/mime.types | ||
|
|
||
|
|
||
| RUN mkdir -p /kb/deployment/bin && \ | ||
| wget -O /tmp/dockerize.tar.gz \ | ||
| https://github.com/kbase/dockerize/raw/master/dockerize-linux-amd64-v0.6.1.tar.gz && \ | ||
| tar xzf /tmp/dockerize.tar.gz -C /tmp && \ | ||
| mv /tmp/dockerize /kb/deployment/bin/ && \ | ||
| rm /tmp/dockerize.tar.gz | ||
|
bio-boris marked this conversation as resolved.
bio-boris marked this conversation as resolved.
|
||
|
|
||
| ENTRYPOINT [ "/kb/deployment/bin/dockerize" ] | ||
|
|
||
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1 @@ | ||
| # nginx | ||
| Version of standard nginx image that supports KBase configuration | ||
|
|
||
| # Passing environment variables through Nginx to the narrative containers | ||
|
|
||
| This section is no longer relevant. Narrative containers (and their environment variables) are managed by traefiker. | ||
| # NGINX | ||
|
bio-boris marked this conversation as resolved.
|
||
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
Uh oh!
There was an error while loading. Please reload this page.