Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
Restyaboard
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Merge Requests
0
Merge Requests
0
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Ali Arshad
Restyaboard
Commits
f88ddbd6
Commit
f88ddbd6
authored
Sep 17, 2015
by
Tsubasa Namiki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
A user can specify which version to install
parent
7e29b8a8
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
16 additions
and
16 deletions
+16
-16
docker-compose.yml
docker-compose.yml
+2
-0
Dockerfile
restyaboard/Dockerfile
+3
-15
docker-entrypoint.sh
restyaboard/docker-entrypoint.sh
+11
-1
No files found.
docker-compose.yml
View file @
f88ddbd6
...
@@ -27,6 +27,8 @@ restyaboard:
...
@@ -27,6 +27,8 @@ restyaboard:
-
postgres:postgres
-
postgres:postgres
ports
:
ports
:
-
1234:80
-
1234:80
environment
:
RESTYABOARD_VERSION
:
v0.1.2
volumes_from
:
volumes_from
:
-
data
-
data
restart
:
always
restart
:
always
restyaboard/Dockerfile
View file @
f88ddbd6
...
@@ -12,7 +12,7 @@ COPY etc/yum.repos.d/nginx.repo /etc/yum.repos.d/
...
@@ -12,7 +12,7 @@ COPY etc/yum.repos.d/nginx.repo /etc/yum.repos.d/
# update & install package
# update & install package
RUN
\
RUN
\
yum update
-y
;
\
yum update
-y
;
\
yum install
-y
git
bzip2 cronie postfix postgresql
;
\
yum install
-y
bzip2 cronie postfix postgresql
;
\
yum install
-y
--enablerepo
=
nginx nginx
;
\
yum install
-y
--enablerepo
=
nginx nginx
;
\
yum install
-y
--enablerepo
=
remi-php56
\
yum install
-y
--enablerepo
=
remi-php56
\
php php-fpm php-pgsql php-mbstring php-pecl-imagick
;
\
php php-fpm php-pgsql php-mbstring php-pecl-imagick
;
\
...
@@ -24,25 +24,13 @@ RUN \
...
@@ -24,25 +24,13 @@ RUN \
sed
-i
's/^user = apache$/user = nginx/g'
/etc/php-fpm.d/www.conf
;
\
sed
-i
's/^user = apache$/user = nginx/g'
/etc/php-fpm.d/www.conf
;
\
sed
-i
's/^group = apache$/group = nginx/g'
/etc/php-fpm.d/www.conf
sed
-i
's/^group = apache$/group = nginx/g'
/etc/php-fpm.d/www.conf
# install restyaboard
# remove document root
RUN
\
RUN
rm
-rf
/usr/share/nginx/html
rm
-rf
/usr/share/nginx/html
;
\
git clone https://github.com/RestyaPlatform/board.git
\
/usr/share/nginx/html
WORKDIR
/usr/share/nginx/html
RUN
\
cp restyaboard.conf /etc/nginx/conf.d
;
\
cp
-R
media /tmp
;
\
npm install
;
\
grunt build:live
;
\
echo
'*/5 * * * * php /usr/share/nginx/htmlserver/php/R/shell/cron.php'
\
>
/var/spool/cron/root
# volume
# volume
VOLUME
/usr/share/nginx/html/media
VOLUME
/usr/share/nginx/html/media
# entry point
# entry point
COPY
docker-entrypoint.sh /
COPY
docker-entrypoint.sh /
RUN
chmod +x /docker-entrypoint.sh
ENTRYPOINT
["/docker-entrypoint.sh"]
ENTRYPOINT
["/docker-entrypoint.sh"]
CMD
["start"]
CMD
["start"]
restyaboard/docker-entrypoint.sh
View file @
f88ddbd6
...
@@ -3,6 +3,17 @@
...
@@ -3,6 +3,17 @@
set
-e
set
-e
if
[
"
$1
"
=
'start'
]
;
then
if
[
"
$1
"
=
'start'
]
;
then
# provision
cd
/tmp
curl
-L
-o
restyaboard.tar.gz https://github.com/RestyaPlatform/board/archive/
${
RESTYABOARD_VERSION
}
.tar.gz
mkdir html
&&
tar
xzvf restyaboard.tar.gz
-C
html
--strip-components
1
cp
-rf
html /usr/share/nginx/
cd
/usr/share/nginx/html
cp restyaboard.conf /etc/nginx/conf.d
npm install
grunt build:live
echo
'*/5 * * * * php /usr/share/nginx/htmlserver/php/R/shell/cron.php'
>
/var/spool/cron/root
# config
# config
sed
-i
"s/^.*'R_DB_NAME'.*
$/
define('R_DB_NAME', 'restyaboard');/g"
\
sed
-i
"s/^.*'R_DB_NAME'.*
$/
define('R_DB_NAME', 'restyaboard');/g"
\
/usr/share/nginx/html/server/php/R/config.inc.php
/usr/share/nginx/html/server/php/R/config.inc.php
...
@@ -16,7 +27,6 @@ if [ "$1" = 'start' ]; then
...
@@ -16,7 +27,6 @@ if [ "$1" = 'start' ]; then
/usr/share/nginx/html/server/php/R/config.inc.php
/usr/share/nginx/html/server/php/R/config.inc.php
# media
# media
cp
-R
/tmp/media /usr/share/nginx/html
chmod
-R
go+w /usr/share/nginx/html/media
chmod
-R
go+w /usr/share/nginx/html/media
chmod
-R
go+w /usr/share/nginx/html/client/img
chmod
-R
go+w /usr/share/nginx/html/client/img
...
...
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