diff --git a/Chapter 3: Time Series Analysis/Dockerfile b/Chapter 3: Time Series Analysis/Dockerfile new file mode 100644 index 0000000..92c84e3 --- /dev/null +++ b/Chapter 3: Time Series Analysis/Dockerfile @@ -0,0 +1,6 @@ +FROM postgres:15.5-alpine + +ENV POSTGRES_PASSWORD postgres + +COPY us_retail_sales.csv /docker-entrypoint-initdb.d/ +COPY create_retail_sales_table.sql /docker-entrypoint-initdb.d/ diff --git a/Chapter 3: Time Series Analysis/create_retail_sales_table.sql b/Chapter 3: Time Series Analysis/create_retail_sales_table.sql index 210d37d..1fae484 100644 --- a/Chapter 3: Time Series Analysis/create_retail_sales_table.sql +++ b/Chapter 3: Time Series Analysis/create_retail_sales_table.sql @@ -13,6 +13,7 @@ sales_month date -- populate the table with data from the csv file. Download the file locally before completing this step COPY retail_sales FROM '/localpath/us_retail_sales.csv' -- change to the location you saved the csv file +-- FROM '/docker-entrypoint-initdb.d/us_retail_sales.csv' -- for docker comment out the line above and uncomment this one DELIMITER ',' CSV HEADER ;