NGINX : Usable Environment Variables

  • Tình trạng: Closed
  • Giải thưởng: $100
  • Các bài thi đã nhận: 5
  • Người chiến thắng: zico4reel

Tóm tắt cuộc thi

We are looking for the simplest method possible (if possible) to pass an environment variable we can use into our Nginx sites-available domains.

We are not using Docker. Without Docker

Thus far we have not found it, so we are putting it out there in the form of a contest.

I do not use docker.

For instance Linux comes with /etc/environment file which I have added many variables=values for instance:
export SM_IP_GATEWAY="96.69.208.332"
export SM_DOMAIN="compumatter.biz"
export SM_EXTIP="96.69.208.129"

How to get those values to use in NGNIX

The goal is to get those same variables that are inside /etc/environment to be available within
NGINX
* /etc/nginx/nginx.conf
* /etc/nginx/sites-available/somedomain.com
So inside I should be able to see SM_DOMAIN would available as compumatter.biz

Các kĩ năng yêu cầu

Bảng thông báo công khai

  • mangeshgwagle
    mangeshgwagle
    • cách đây 2 năm

    Do you want nginx to read these environment variables on startup or runtime as well ??

    • cách đây 2 năm
  • zico4reel
    zico4reel
    • cách đây 2 năm

    Hi, kindly check my entry and let me know, Thanks, Kind regards

    • cách đây 2 năm
  • Anishsapkota000
    Anishsapkota000
    • cách đây 2 năm

    Are you configuring it in docker or directly in the server?

    • cách đây 2 năm

Làm thế nào để bắt đầu với cuộc thi

  • Đăng cuộc thi của bạn

    Đăng cuộc thi của bạn Nhanh chóng và dễ dàng

  • Nhận được vô số bài dự thi

    Nhận được vô số Bài dự thi Từ khắp nơi trên thế giới

  • Trao giải cho bài thi xuất sắc nhất

    Trao giải cho bài thi xuất sắc nhất Download File - Đơn giản!

Đăng cuộc thi ngay hoặc tham gia với chúng tôi ngay hôm nay!