File tree Expand file tree Collapse file tree 2 files changed +17
-5
lines changed Expand file tree Collapse file tree 2 files changed +17
-5
lines changed Original file line number Diff line number Diff line change @@ -23,7 +23,11 @@ services:
23
23
# emails, do periodic checks etc. I recommend using this to your
24
24
# advantage to automate schedulable tasks.
25
25
sidekiq :
26
- build : .
26
+ build :
27
+ context : .
28
+ args :
29
+ PUID : ${UID}
30
+ PGID : ${GID}
27
31
platform : linux/amd64
28
32
command : bundle exec sidekiq -C config/sidekiq.yml
29
33
environment :
@@ -40,7 +44,11 @@ services:
40
44
# Using this mechanism you can also perform database migrations and rollbacks
41
45
# docker-compose exec rails rails db:migrate
42
46
rails :
43
- build : .
47
+ build :
48
+ context : .
49
+ args :
50
+ PUID : ${UID}
51
+ PGID : ${GID}
44
52
platform : linux/amd64
45
53
container_name : rails
46
54
command : sh -c "rm -f tmp/pids/server.pid && bundle exec rails s -p 3000 -b '0.0.0.0'"
@@ -68,14 +76,18 @@ services:
68
76
# This container only starts to prepare the database. It will then exit after it is done.
69
77
# Use db/seed.rb to seed your database for development.
70
78
rails_startup :
71
- build : .
79
+ build :
80
+ context : .
81
+ args :
82
+ PUID : ${UID}
83
+ PGID : ${GID}
72
84
platform : linux/amd64
73
85
environment :
74
86
DATABASE_URL : postgres://postgres:postgres@db
75
87
depends_on :
76
88
- db
77
89
- redis
78
- command : sh sh bin/dbsetup
90
+ command : sh bin/dbsetup
79
91
80
92
# ****************
81
93
# Tools
Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ ADD --chown=srv:srv docker/unit/start.sh docker/unit/waitpg.sh docker/unit/waitr
35
35
36
36
RUN mkdir -p /run/redis && \
37
37
mkdir -p /run/postgresql && \
38
- chown -R srv:srv /run \
38
+ chown -R srv:srv /run && \
39
39
chown -R srv /srv && \
40
40
chgrp -R srv /srv
41
41
You can’t perform that action at this time.
0 commit comments