Page Menu
Home
GRNET
Search
Configure Global Search
Log In
Files
F904826
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Fri, Aug 29, 3:08 PM
Size
1 KB
Mime Type
text/x-diff
Expires
Sun, Aug 31, 3:08 PM (1 d, 20 h)
Engine
blob
Format
Raw Data
Handle
252265
Attached To
rDOCKERWEBDNS webdns_docker
View Options
diff --git a/webdns/entrypoint.sh b/webdns/entrypoint.sh
index fec68fd..34c4ba6 100644
--- a/webdns/entrypoint.sh
+++ b/webdns/entrypoint.sh
@@ -1,29 +1,40 @@
#!/bin/bash
if [ -z "${MYSQL_HOST}" ]; then
echo "You need to specify a mysql host."
exit
fi
MYSQL_DATABASE=${MYSQL_DATABASE-dns}
MYSQL_USER=${MYSQL_USER-dns}
MYSQL_PORT=${MYSQL_PORT-3306}
MYSQL_PASSWORD=${MYSQL_PASSWORD-12345}
+MYSQL_TEST_DATABASE="${MYSQL_DATABASE}_test"
+MYSQL_TEST_USER="${MYSQL_USER}_test"
+
sleep 20
cat << EOF > /srv/webdns/config/database.yml
development:
database: ${MYSQL_DATABASE}
adapter: mysql2
encoding: utf8
username: ${MYSQL_USER}
password: ${MYSQL_PASSWORD}
host: ${MYSQL_HOST}
+
+test:
+ database: ${MYSQL_TEST_DATABASE}
+ adapter: mysql2
+ encoding: utf8
+ username: ${MYSQL_TEST_USER}
+ password: ${MYSQL_PASSWORD}
+ host: ${MYSQL_HOST}
EOF
/usr/bin/rake db:migrate
/usr/bin/rails runner /seeds_users.rb
#/usr/bin/rails runner seeds_policies.rb
cd /srv/webdns
rails server
Event Timeline
Log In to Comment