From ac57d50f42e7ca060dcc109bcbae745e0e7a6038 Mon Sep 17 00:00:00 2001 From: Megan Guiney Date: Thu, 4 Jan 2018 15:32:34 -0800 Subject: [PATCH] Make run-in-docker script use Xenial This will allow us to run Py35 tests while testing in the container Change-Id: Ia95262c37a9eb843b8afdedf6e9adf76a9f5641f --- docker/Dockerfile | 9 +++++---- docker/scripts/api-init-db | 4 +++- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index a8327ea6..b1dc650e 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,4 +1,6 @@ -FROM ubuntu:14.04 +FROM ubuntu:16.04 + +RUN apt update && apt install -y sudo RUN \ groupadd dev && \ @@ -8,12 +10,11 @@ RUN \ ENV DEBIAN_FRONTEND noninteractive RUN \ - apt-get update && \ - apt-get -y install \ + apt -y install \ sudo git vim wget \ nginx \ python-dev python3-dev python-pip \ - libmysqlclient-dev mysql-client-5.6 mysql-server-5.6 libffi-dev\ + libmysqlclient-dev mysql-client mysql-server libffi-dev\ npm && \ rm -rf /var/lib/apt/lists/* && \ rm -rf /var/lib/mysql/* && \ diff --git a/docker/scripts/api-init-db b/docker/scripts/api-init-db index edad5421..f269f8d0 100755 --- a/docker/scripts/api-init-db +++ b/docker/scripts/api-init-db @@ -1,5 +1,7 @@ #!/bin/bash [[ ${DEBUG_MODE} ]] && set -x mysql --no-defaults -S ${SQL_DIR}/mysql.socket -e 'CREATE DATABASE refstack;' +mysql --no-defaults -S ${SQL_DIR}/mysql.socket -e 'set @@global.show_compatibility_56=ON;' + cd /home/dev/refstack -.venv/bin/python bin/refstack-manage upgrade --revision head \ No newline at end of file +.venv/bin/python bin/refstack-manage upgrade --revision head