Kaballas commited on
Commit
f11c216
·
verified ·
1 Parent(s): ba0ae3d

Create Docker

Browse files
Files changed (1) hide show
  1. Docker +16 -0
Docker ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Use the official PostgresML image
2
+ FROM ghcr.io/postgresml/postgresml:2.7.12
3
+
4
+ # Optional: Set environment variables if needed
5
+ ENV POSTGRES_DB=postgresml
6
+ ENV POSTGRES_USER=postgresml
7
+
8
+ # Expose the necessary ports
9
+ EXPOSE 5432 8000
10
+
11
+ # Create a volume for persistent PostgreSQL data
12
+ VOLUME ["/var/lib/postgresql"]
13
+
14
+ # Set the default command to run when the container starts
15
+ # This matches the original docker run command
16
+ CMD ["sudo", "-u", "postgresml", "psql", "-d", "postgresml"]