Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
laradock
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kerwin
laradock
Commits
265bc139
Unverified
Commit
265bc139
authored
Nov 23, 2017
by
Mahmoud Zalt
Committed by
GitHub
Nov 23, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1251 from mouyong/master
Set environment to change source.
parents
9b8d4806
8d410e9c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
2 deletions
+15
-2
env-example
env-example
+5
-0
Dockerfile
nginx/Dockerfile
+10
-2
No files found.
env-example
View file @
265bc139
...
...
@@ -2,6 +2,11 @@
# General Setup
###########################################################
### Environment ########################################################################################################
# If you're in China, or you need to change sources, will be set CHANGE_SOURCE to true in .env.
CHANGE_SOURCE=false
### Docker compose files ###############################################################################################
# Select which docker-compose files to include.
...
...
nginx/Dockerfile
View file @
265bc139
...
...
@@ -4,14 +4,22 @@ MAINTAINER Mahmoud Zalt <mahmoud@zalt.me>
ADD
nginx.conf /etc/nginx/
ARG
PHP_UPSTREAM_CONTAINER=php-fpm
ARG
PHP_UPSTREAM_PORT=9000
# If you're in China, or you need to change sources, will be set CHANGE_SOURCE to true in .env.
ARG
CHANGE_SOURCE=false
RUN if
[
${
CHANGE_SOURCE
}
=
true
]
;
then
\
# Change application source from dl-cdn.alpinelinux.org to aliyun source
RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/' /etc/apk/repositories
;fi
RUN
apk update
\
&&
apk upgrade
\
&&
apk add
--no-cache
bash
\
&&
adduser
-D
-H
-u
1000
-s
/bin/bash www-data
ARG
PHP_UPSTREAM_CONTAINER=php-fpm
ARG
PHP_UPSTREAM_PORT=9000
# Set upstream conf and remove the default conf
RUN
echo
"upstream php-upstream { server
${
PHP_UPSTREAM_CONTAINER
}
:
${
PHP_UPSTREAM_PORT
}
; }"
>
/etc/nginx/conf.d/upstream.conf
\
&&
rm
/etc/nginx/conf.d/default.conf
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment