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

Redesign Hey infra to support any machines #4452

Open
bigint opened this issue Dec 30, 2023 · 11 comments
Open

Redesign Hey infra to support any machines #4452

bigint opened this issue Dec 30, 2023 · 11 comments

Comments

@bigint
Copy link
Member

bigint commented Dec 30, 2023

Deliverables

  • Deploy the docker image on a Ubuntu box
  • Should support three environments of each docker (mainnet, staging and testnet) all in one box and reverse proxy the port to point the domain/subdomain and use same IP to point each 3 apps
    • Web (web-ubuntu-box)
      • Mainnet - 4783 => hey.xyz
      • Testnet - 5783 => testnet.hey.xyz
      • Staging - 6783 => staging.hey.xyz
    • API (api-ubuntu-box)
      • Mainnet - 4784 => api.hey.xyz
        • Postgres - database: mainnet
      • Testnet - 5784 => testnet-api.hey.xyz
        • Postgres - database: testnet
      • Staging - 6784 => staging-api.hey.xyz
        • Postgres - database: staging
    • OG (og-ubuntu-box)
      • Mainnet - 4785 => og.hey.xyz
      • Testnet - 5785 => og-testnet.hey.xyz
      • Staging - 6785 => og-testnet.hey.xyz
  • Should trigger deployment from GitHub action after docker is deployed
@bigint
Copy link
Member Author

bigint commented Dec 30, 2023

/bounty $150

Copy link

algora-pbc bot commented Dec 30, 2023

💎 $150 bounty created by hey
🙋 If you start working on this, comment /attempt #4452 along with your implementation plan
👉 To claim this bounty, submit a pull request that includes the text /claim #4452 somewhere in its body
📝 Before proceeding, please make sure you can receive payouts in your country
💵 Payment arrives in your account 2-5 days after the bounty is rewarded
💯 You keep 100% of the bounty award
🙏 Thank you for contributing to heyxyz/hey!

👉 Add a bountyShare on socials

Attempt Started (GMT+0) Solution
🔴 @ezhil56x Dec 30, 2023, 8:38:20 AM WIP
🟢 @Raushankumar-prog Mar 4, 2024, 10:00:05 AM WIP

@ezhil56x
Copy link
Contributor

ezhil56x commented Dec 30, 2023

@bigint Can I work on this?
/attempt #4452

Options

@Rutik7066
Copy link

@ezhil56x i was trying to work on this project but was unable to set it up.
og and api works fine but not web output of pnpm run dev

pnpm run dev

> hey@3.0.4-beta dev /home/bot/Desktop/op/hey
> turbo run dev --parallel

• Packages in scope: @hey/abis, @hey/api, @hey/config, @hey/data, @hey/image-cropper, @hey/lens, @hey/lib, @hey/og, @hey/types, @hey/ui, @hey/web
• Running dev in 11 packages
• Remote caching disabled
@hey/og:dev: cache bypass, force executing eda5d50d3eb892f4
@hey/web:dev: cache bypass, force executing e2658fcc8b0c7d2b
@hey/api:dev: cache bypass, force executing 786db3e15ce8b291
@hey/web:dev: 
@hey/web:dev: > @hey/web@0.0.0 dev /home/bot/Desktop/op/hey/apps/web
@hey/web:dev: > next dev --port 4783
@hey/web:dev: 
@hey/og:dev: 
@hey/og:dev: > @hey/og@0.0.0 dev /home/bot/Desktop/op/hey/apps/og
@hey/og:dev: > next dev --port 4785
@hey/og:dev: 
@hey/api:dev: 
@hey/api:dev: > @hey/api@0.0.0 dev /home/bot/Desktop/op/hey/apps/api
@hey/api:dev: > nodemon -w src -x tsx src/server.ts
@hey/api:dev: 
@hey/api:dev: [nodemon] 3.0.2
@hey/api:dev: [nodemon] to restart at any time, enter `rs`
@hey/api:dev: [nodemon] watching path(s): src/**/*
@hey/api:dev: [nodemon] watching extensions: ts,json
@hey/api:dev: [nodemon] starting `tsx src/server.ts`
@hey/og:dev:    ▲ Next.js 14.0.4
@hey/og:dev:    - Local:        http://localhost:4785
@hey/og:dev: 
@hey/web:dev:    ▲ Next.js 14.0.4
@hey/web:dev:    - Local:        http://localhost:4783
@hey/web:dev:    - Experiments (use at your own risk):
@hey/web:dev:      · scrollRestoration
@hey/web:dev: 
@hey/web:dev: `destination` does not start with `/`, `http://`, or `https://` for route {"destination":"undefined/u/:match*","has":[{"key":"user-agent","type":"header","value":".*(bot|telegram|baidu|bing|yandex|iframely|whatsapp|facebook).*"}],"source":"/u/:match*"}
@hey/web:dev: 
@hey/web:dev: `destination` does not start with `/`, `http://`, or `https://` for route {"destination":"undefined/posts/:match*","has":[{"key":"user-agent","type":"header","value":".*(bot|telegram|baidu|bing|yandex|iframely|whatsapp|facebook).*"}],"source":"/posts/:match*"}
@hey/web:dev: 
@hey/web:dev: 
@hey/web:dev: Error: Invalid rewrites found
@hey/web:dev: 
@hey/api:dev: 3:39:33 PM [vite-express] Running in development mode
@hey/api:dev: 3:39:34 PM [vite-express] Using Vite to resolve the config file
@hey/api:dev: Server is listening on port 4784...
@hey/og:dev:  ✓ Ready in 13.7s

@bigint
Copy link
Member Author

bigint commented Jan 3, 2024

@Rutik7066 do you have NEXT_PUBLIC_OG_URL configured on your .env file on web?

@Rutik7066
Copy link

No, I don't have any env configuration

@bigint
Copy link
Member Author

bigint commented Jan 3, 2024

NEXT_PUBLIC_IS_PRODUCTION=false
NEXT_PUBLIC_LENS_NETWORK="mainnet" # mainnet, testnet, staging
NEXT_PUBLIC_OG_URL="http://localhost:4785"

add these 🙇🏼

@Rutik7066
Copy link

NEXT_PUBLIC_IS_PRODUCTION=false
NEXT_PUBLIC_LENS_NETWORK="mainnet" # mainnet, testnet, staging
NEXT_PUBLIC_OG_URL="http://localhost:4785"

add these 🙇🏼

Working now 👍

@vinfinity7
Copy link

@bigint is this still in progress or may i try to make a shell script as youve commented earlier

@Raushankumar-prog
Copy link

Raushankumar-prog commented Mar 4, 2024

/attempt #4452

@ezhil56x
Copy link
Contributor

ezhil56x commented Mar 4, 2024

@Raushankumar-prog

This has been completed and is in wait for other works that are yet to be completed in hey.xyz

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: In Progress
5 participants