support docker

This commit is contained in:
William Bell committed 2023-08-03 14:22:44 +02:00
1 parent ae4a589307
commit afb9916a5f
5 files changed
+21 -5

No files matched your search

+4
View File
@@ -0,0 +1,4 @@
argon_modules
packages-db.json
data
packages
+1
View File
@@ -9,3 +9,4 @@ argon_modules
# main
packages
packages-db.json
dockerData
+3 -1
View File
@@ -1,9 +1,11 @@
FROM ugric/argon
WORKDIR /app
WORKDIR /isotope-server
COPY . .
RUN isotope install
RUN mkdir data
CMD [ "argon", "." ]
+4 -4
View File
@@ -1,7 +1,7 @@
let packages = null
let accounts = null
let packages = {}
let accounts = []
let indexes = {username: {}, email: {}, id: {}}
let savePath = path.join([program.cwd, "packages-db.json"])
let savePath = path.join([program.cwd, 'data', "packages-db.json"])
let changes = {n: 0, last: 0}
@@ -24,7 +24,7 @@ let randstr(length) = do
let load() = do
if (path.exists(savePath)) do
let file = file.read(savePath)
data = file.json()
data = file.json()||{}
if ("packages" not in data) do
packages = data
accounts = []
+9
View File
@@ -0,0 +1,9 @@
version: '3.7'
services:
server:
image: 'ugric/isotope-server:latest'
ports:
- '7030:7030'
volumes:
- './data:/isotope-server/data'