build proxy

This commit is contained in:
Darren 2023-12-11 10:44:09 +08:00 committed by GitHub
parent 5be2248e3c
commit 20dfb44d78
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -11,7 +11,7 @@ RUN apt-get update && apt-get install --no-install-recommends -y curl jq && rm -
COPY ./config/initproxy.conf /etc/
COPY ./s6/w9init/setuser.sh /app/setuser.sh
COPY ./s6/w9init/migration.sh /app/migration.sh
COPY ./s6/w9init/proxy.sh /app/proxy.sh
COPY ./s6/w9init/setproxy.sh /app/setproxy.sh
RUN chmod +x /app/setuser.sh /app/migration.sh
RUN export add_ip_data="const ipDataFile={[CLOUDFRONT_URL]:'ip-ranges.json',[CLOUDFARE_V4_URL]:'ips-v4',[CLOUDFARE_V6_URL]:'ips-v6'}[url];logger.info(ipDataFile);if(ipDataFile){return fs.readFile(__dirname+'/../lib/ipData/'+ipDataFile,'utf8',(error,data)=>{if(error){logger.error('fetch '+ipDataFile+' error');reject(error);return}logger.info('fetch '+ipDataFile+' success');resolve(data)})}" && \