File tree Expand file tree Collapse file tree 2 files changed +8
-12
lines changed Expand file tree Collapse file tree 2 files changed +8
-12
lines changed Original file line number Diff line number Diff line change 1
- FROM ubuntu:16.04
1
+ FROM python:3.9.9
2
2
ENV workdir /app
3
3
RUN apt-get update
4
4
RUN apt-get install -y \
5
- wget \
6
- python-pip \
7
- software-properties-common \
8
- python-software-properties \
9
- curl
10
- RUN wget -q https://www.postgresql.org/media/keys/ACCC4CF8.asc -O - | apt-key add -
11
- RUN sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt/ xenial-pgdg main" >> /etc/apt/sources.list.d/pgdg.list'
12
- RUN apt-get update
13
- RUN apt-get install -y postgresql postgresql-contrib
5
+ curl \
6
+ postgresql-client
7
+
8
+ # Install AWS and GCP cli
14
9
RUN pip install awscli
15
10
RUN curl -sSL https://sdk.cloud.google.com | bash
16
11
RUN ln -f -s /root/google-cloud-sdk/bin/gsutil /usr/bin/gsutil
17
12
WORKDIR $workdir
18
13
COPY ./start.sh .
19
- CMD ./start.sh
14
+ CMD ./start.sh
Original file line number Diff line number Diff line change 2
2
export PGPASSWORD=$POSTGRES_PASSWORD
3
3
4
4
date=$( date ' +%y%m%d_%H%M' )
5
- backupFile=osmseed-${date} .sql.gz
5
+ backupFile=osmseed-db- ${date} .sql.gz
6
6
stateFile=" state.txt"
7
7
restoreFile=" backup.sql.gz"
8
8
9
+ echo " Start... $DB_ACTION action"
9
10
# Backing up DataBase
10
11
if [ " $DB_ACTION " == " backup" ]; then
11
12
# Backup database and make maximum compression at the slowest speed
You can’t perform that action at this time.
0 commit comments