Pasting files in root dir

This commit is contained in:
Miguel Martinez
2016-06-03 14:46:28 -07:00
parent 9fc0a96494
commit d3a4731407
4 changed files with 14 additions and 11 deletions

View File

@@ -38,6 +38,7 @@ ENV RAILS_ENV=development
ENV BITNAMI_APP_NAME=rails
ENV BITNAMI_IMAGE_VERSION=4.2.6-r0
USER bitnami
WORKDIR /app
EXPOSE 3000

View File

@@ -1 +1,6 @@
# bitnami-docker-rails
WIP
DO not run the docker-compose up in this directory, .gitignores will
conflict

View File

@@ -8,17 +8,13 @@ services:
mariadb:
tty: true
image: bitnami/mariadb:latest
environment:
- MARIADB_ROOT_PASSWORD=
- MARIADB_USER=
- MARIADB_PASSWORD=
- MARIADB_DATABASE=
volumes:
- mariadb-data:/bitnami/mariadb
myapp:
tty: true
build: .
# build: .
image: gcr.io/bitnami-containers/rails:4.2.6-r1
environment:
- DATABASE_URL=mysql2://mariadb/my_app_development
depends_on:
@@ -26,4 +22,4 @@ services:
ports:
- 3000:3000
volumes:
- ./app:/app
- .:/app

View File

@@ -1,7 +1,8 @@
#!/bin/bash
set -e
INIT_SEM=/tmp/initialized.sem
GEMFILE=/app/Gemfile
fresh_container() {
[ ! -f $INIT_SEM ]
}
@@ -24,8 +25,8 @@ wait_for_db() {
log "Error: Couldn't connect to mariadb."
exit 1
fi
log "Still trying to connect to mariadb at $mariadb_address. Attempt $counter."
sleep 2
log "Trying to connect to mariadb at $mariadb_address. Attempt $counter."
sleep 5
done
}
@@ -42,7 +43,7 @@ log () {
if ! app_present; then
log "Creating rails application"
rails new . --skip-bundle --database mysql --quiet
rails new . --skip-bundle --database mysql
fi
if ! gems_up_to_date; then