Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

unify configuration (use environment variables) and dockerize #62

Merged
merged 12 commits into from
Apr 29, 2024

Conversation

cirroskais
Copy link

Sponsored by MadHouse Labs:tm:

@cirroskais cirroskais changed the title unify configuration (use environtment variables) and dockerize unify configuration (use environment variables) and dockerize Apr 28, 2024
@nbitzz nbitzz linked an issue Apr 28, 2024 that may be closed by this pull request
@nbitzz
Copy link
Contributor

nbitzz commented Apr 28, 2024

added #22 here because this solves it by doing the exact opposite of what #22 suggests

@cirroskais
Copy link
Author

cirroskais commented Apr 28, 2024

almost ready for review; only issue currently standing is that assets are not copied over to the image
image

@cirroskais cirroskais marked this pull request as ready for review April 28, 2024 09:28
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image

@nbitzz nbitzz requested a review from Jack5079 April 28, 2024 16:38
@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

Man i should just merge this shoulndt i

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

@Jack5079 Oi

.env.example Outdated Show resolved Hide resolved
@Jack5079
Copy link
Member

So damn true!

@cirroskais
Copy link
Author

Lgtm

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

i dotn fgjuicking know just merge it

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

We can like fix the API mounting later right now idgaf

@cirroskais
Copy link
Author

error while creating account:

file:///usr/src/app/node_modules/@hono/node-server/dist/index.mjs:151
  for (const [k, v] of headers) {
                       ^

TypeError: headers is not iterable
    at buildOutgoingHttpHeaders (file:///usr/src/app/node_modules/@hono/node-server/dist/index.mjs:151:24)
    at responseViaResponseObject (file:///usr/src/app/node_modules/@hono/node-server/dist/index.mjs:315:27)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

@cirroskais
Copy link
Author

currently deployed at https://monofile.dev.madhouselabs.net/ go crazy

@Jack5079
Copy link
Member

image

@cirroskais
Copy link
Author

TypeError: AuthTokens.find is not a function
    at getToken (file:///usr/src/app/out/server/lib/auth.js:36:23)
    at Module.validate (file:///usr/src/app/out/server/lib/auth.js:39:12)
    at Module.getFromToken (file:///usr/src/app/out/server/lib/accounts.js:49:22)
    at getAccount (file:///usr/src/app/out/server/lib/middleware.js:9:33)
    at dispatch (file:///usr/src/app/node_modules/hono/dist/compose.js:29:23)
    at file:///usr/src/app/node_modules/hono/dist/compose.js:6:12
    at file:///usr/src/app/node_modules/hono/dist/hono-base.js:226:31
    at Hono.dispatch (file:///usr/src/app/node_modules/hono/dist/hono-base.js:236:7)
    at fetch (file:///usr/src/app/node_modules/hono/dist/hono-base.js:60:19)
    at Server.<anonymous> (file:///usr/src/app/node_modules/@hono/node-server/dist/index.mjs:362:13)

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

AAAAAAAAAAAAAAAAAAAAa

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

error while creating account:

file:///usr/src/app/node_modules/@hono/node-server/dist/index.mjs:151
  for (const [k, v] of headers) {
                       ^

TypeError: headers is not iterable
    at buildOutgoingHttpHeaders (file:///usr/src/app/node_modules/@hono/node-server/dist/index.mjs:151:24)
    at responseViaResponseObject (file:///usr/src/app/node_modules/@hono/node-server/dist/index.mjs:315:27)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

Pull latest commit to api-v1

@cirroskais
Copy link
Author

deployed

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

TypeError: AuthTokens.find is not a function
    at getToken (file:///usr/src/app/out/server/lib/auth.js:36:23)
    at Module.validate (file:///usr/src/app/out/server/lib/auth.js:39:12)
    at Module.getFromToken (file:///usr/src/app/out/server/lib/accounts.js:49:22)
    at getAccount (file:///usr/src/app/out/server/lib/middleware.js:9:33)
    at dispatch (file:///usr/src/app/node_modules/hono/dist/compose.js:29:23)
    at file:///usr/src/app/node_modules/hono/dist/compose.js:6:12
    at file:///usr/src/app/node_modules/hono/dist/hono-base.js:226:31
    at Hono.dispatch (file:///usr/src/app/node_modules/hono/dist/hono-base.js:236:7)
    at fetch (file:///usr/src/app/node_modules/hono/dist/hono-base.js:60:19)
    at Server.<anonymous> (file:///usr/src/app/node_modules/@hono/node-server/dist/index.mjs:362:13)

Man i don't even know 😭

@cirroskais
Copy link
Author

TypeError: AuthTokens.find is not a function
    at getToken (file:///usr/src/app/out/server/lib/auth.js:36:23)
    at Module.validate (file:///usr/src/app/out/server/lib/auth.js:39:12)
    at Module.getFromToken (file:///usr/src/app/out/server/lib/accounts.js:49:22)
    at getAccount (file:///usr/src/app/out/server/lib/middleware.js:9:33)
    at dispatch (file:///usr/src/app/node_modules/hono/dist/compose.js:29:23)
    at file:///usr/src/app/node_modules/hono/dist/compose.js:6:12
    at file:///usr/src/app/node_modules/hono/dist/hono-base.js:226:31
    at Hono.dispatch (file:///usr/src/app/node_modules/hono/dist/hono-base.js:236:7)
    at fetch (file:///usr/src/app/node_modules/hono/dist/hono-base.js:60:19)
    at Server.<anonymous> (file:///usr/src/app/node_modules/@hono/node-server/dist/index.mjs:362:13)

Man i don't even know 😭

i was stupid and set tokens.json to " {} " and not " [] " my fault og

you should probably make it... make those files. if they dont exist

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

TypeError: AuthTokens.find is not a function
    at getToken (file:///usr/src/app/out/server/lib/auth.js:36:23)
    at Module.validate (file:///usr/src/app/out/server/lib/auth.js:39:12)
    at Module.getFromToken (file:///usr/src/app/out/server/lib/accounts.js:49:22)
    at getAccount (file:///usr/src/app/out/server/lib/middleware.js:9:33)
    at dispatch (file:///usr/src/app/node_modules/hono/dist/compose.js:29:23)
    at file:///usr/src/app/node_modules/hono/dist/compose.js:6:12
    at file:///usr/src/app/node_modules/hono/dist/hono-base.js:226:31
    at Hono.dispatch (file:///usr/src/app/node_modules/hono/dist/hono-base.js:236:7)
    at fetch (file:///usr/src/app/node_modules/hono/dist/hono-base.js:60:19)
    at Server.<anonymous> (file:///usr/src/app/node_modules/@hono/node-server/dist/index.mjs:362:13)

Man i don't even know 😭

i was stupid and set tokens.json to " {} " and not " [] " my fault og

you should probably make it... make those files. if they dont exist

if it fails it just. doesn't gaf and sets the authtoken array to [] so like it'll happen eventually anywaaaay

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

We should really have just used SQL why didnt we monofile from scratch

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

Ok so yeah it basically works we can merge right

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

Switching to mongodb

@cirroskais
Copy link
Author

LGTM

@cirroskais
Copy link
Author

@nbitzz mergeeeee

@nbitzz nbitzz merged commit 2112c75 into mollersuite:api-v1 Apr 29, 2024
@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH

@nbitzz
Copy link
Contributor

nbitzz commented Apr 29, 2024

@Jack5079 Monobot for automatic deployments of monofile whwene>>
Maybe i should do that actually

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add config.json to .gitignore
3 participants