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

Menambahkan opsi penggunaan docker #45

Merged
merged 42 commits into from
Jun 24, 2024
Merged

Menambahkan opsi penggunaan docker #45

merged 42 commits into from
Jun 24, 2024

Conversation

reacto11mecha
Copy link
Member

Harus di squash merge, makan banyak commit kalo nggak.

Masih ada ruang untuk improvisasi, khususnya si web wajib jalan setelah database, jangan sebelum database jalan.
Si next js masih ga bisa dapet akses buat upload file gambar, perlu investigasi juga.
Tambah healthcheck di databasenya juga.

docker-compose.yml untuk saat ini.

version: "3.8"
services:
  db:
    image: mysql:latest
    cap_add:
      - SYS_NICE
    restart: always
    environment:
      - MYSQL_DATABASE=sora
      - MYSQL_USER=sora-user
      - MYSQL_PASSWORD=replacewithsecurepass
      - MYSQL_ROOT_PASSWORD=replacewithsecurepass
    ports:
      - '3306:3306'
    volumes:
      - db:/var/lib/mysql
      - ./db/init.sql:/docker-entrypoint-initdb.d/init.sql

  web:
    container_name: sora_web
    image: rmecha/sora-baseline-web:proper-docker
    restart: always
    environment:
      DB_HOST: db
      DB_NAME: sora
      DB_USERNAME: sora-user
      DB_PASSWORD: replacewithsecurepass
      AUTH_SECRET: replacewithstrongsecuresecret
    ports:
      - 0.0.0.0:3000:3000
    volumes:
      - web_uploads:/app/apps/web/public/uploads

volumes:
  db:
  web_uploads:

@reacto11mecha
Copy link
Member Author

Udah ada docker compose yml langsung, squash merge abistu lanjut desktop

@reacto11mecha reacto11mecha merged commit 3fb799c into main Jun 24, 2024
4 checks passed
@reacto11mecha reacto11mecha deleted the proper-docker branch June 24, 2024 23:19
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.

1 participant