Timestamps: 1:58 Prerequisites 2:40 Setup repo 3:30 Docker setup for db 6:30 Setup directories for frontend backend 6:40 GO backend coding segment begins 27:15 Deploy GO app with docker 37:08 Backend and DB test 45:00 Next.js frontend coding segment begins (includes testing) 1:15:10 Deploy Next.js app with docker and test Command to get inside postgres: docker exec -it db psql -U postgres
I'm a frontend JR, I have a question regarding docker with typescript and nextjs, if you use it in a project with pure react, just make up docker-compose build and docker-compose up, they install all dependencies, but with typescript, despite install, they still return an error referring to the node module, as if it had not been installed, just correcting it by typing npm install with sudo su in the container, how to solve it?
not sure if I get it 100%, but everything you caan type on the container can usually be done in the dockerfile. so try to add the npm install in the dockerfile and see how it goes
The problem is the following, when I create a docker image, with react without typescript, if I delete the local repository from my machine, and make another clone, after running the make up command, it will run and install the entire node_module normally, but when using typescript, eslint reports a node module not found error, as if it had not been installed in the docker image.@@francescociulla
Hello sir I am still confused with docker compose. Suppose I deployed my nextjs app in Vercel and go backend in ec2...where this docker-compose file will be put? Is it just when working with local development or while deploying both frontend and backend together in same platform?
it depends on the platofrm you use. you can use the docker compose to run it locally and create the iamges, then use the images on the service of your cloud provider
To safeguard environment variables in production for Go apps, a good idea is to avoid hardcoding secrets in your code and set environment variables directly in your deployment environment. Utilize a secrets management service (AWS Secrets Manager or HashiCorp Vault for example). Also, be sure that your .env files are excluded from version control by adding them to .gitignore. When possible, encrypt sensitive data to add an extra layer of security. I hope it helps. Good luck with your project!
Can you please add timestamps to the video like Setup, Layout Creation, Authentication, Database Creation etc. I was looking specifically how you solve authentication with next14 and postgresql, but checking every minute through 1hour and 14minutes is a bit daunting. Otherwise thanks!
in this video there is no authentication, altough I am planning to do one. anyway there is a version with timestamps here ruclips.net/video/429-r55KFmM/видео.html
@@francescociulla coded it. I found that the executable files are not running from the app dir, Its running successfully from the following path usr/local/bin/api
Sir please help me i got this error 0.227 go: errors parsing go.mod: 0.227 /app/go.mod:3: invalid go version '1.22.1': must match format 1.23 ------ failed to solve: process "/bin/sh -c go get -d -v ./..." did not complete successfully: exit code: 1,,,, in 36.36 min in video Please help me
Timestamps:
1:58 Prerequisites
2:40 Setup repo
3:30 Docker setup for db
6:30 Setup directories for frontend backend
6:40 GO backend coding segment begins
27:15 Deploy GO app with docker
37:08 Backend and DB test
45:00 Next.js frontend coding segment begins (includes testing)
1:15:10 Deploy Next.js app with docker and test
Command to get inside postgres: docker exec -it db psql -U postgres
thanks. your comment has been highlighted here twitter.com/FrancescoCiull4/status/1783019802442727674
Excellent video, helped me a lot, thanks!
thank you and thansk for adding timestamps!
I love your accent
thank you!
Loved it
thanks. your comment has been featured here twitter.com/FrancescoCiull4/status/1785545596255817990
@@francescociulla could you please have a discord server for your community . im so much intersted in the next js projects you do
@ilyaerr5681 I have. Check the links on yt
@@ilyaerr5681 discord.com/invite/ns5x8bTz25
I'm a frontend JR, I have a question regarding docker with typescript and nextjs, if you use it in a project with pure react, just make up docker-compose build and docker-compose up, they install all dependencies, but with typescript, despite install, they still return an error referring to the node module, as if it had not been installed, just correcting it by typing npm install with sudo su in the container, how to solve it?
not sure if I get it 100%, but everything you caan type on the container can usually be done in the dockerfile. so try to add the npm install in the dockerfile and see how it goes
The problem is the following, when I create a docker image, with react without typescript, if I delete the local repository from my machine, and make another clone, after running the make up command, it will run and install the entire node_module normally, but when using typescript, eslint reports a node module not found error, as if it had not been installed in the docker image.@@francescociulla
Hello sir I am still confused with docker compose. Suppose I deployed my nextjs app in Vercel and go backend in ec2...where this docker-compose file will be put? Is it just when working with local development or while deploying both frontend and backend together in same platform?
it depends on the platofrm you use. you can use the docker compose to run it locally and create the iamges, then use the images on the service of your cloud provider
thank you so much!!!!
you are welcome
What's about the new go1.22 router pattern ? Thx
method matching and wildcards. These features let you express common routes as patterns instead of Go code.
Thanks for the great pilot project. Appreciate it.
is it possible to remove docker code and just implement with out docker ?
absolutely. just change 0.0.0.0 to localhost and "db" to the ip of the db
How to safeguard environment variables for production?
To safeguard environment variables in production for Go apps, a good idea is to avoid hardcoding secrets in your code and set environment variables directly in your deployment environment. Utilize a secrets management service (AWS Secrets Manager or HashiCorp Vault for example). Also, be sure that your .env files are excluded from version control by adding them to .gitignore. When possible, encrypt sensitive data to add an extra layer of security. I hope it helps. Good luck with your project!
Fantastic, thanks for share!
you are welcome. a better and edited version is coming out next week, stay tuned
Can you please add timestamps to the video like Setup, Layout Creation, Authentication, Database Creation etc.
I was looking specifically how you solve authentication with next14 and postgresql, but checking every minute through 1hour and 14minutes is a bit daunting.
Otherwise thanks!
in this video there is no authentication, altough I am planning to do one. anyway there is a version with timestamps here ruclips.net/video/429-r55KFmM/видео.html
can you provide me the db scripts to create tables
check the github repository link
This not work on fetch ssr with next14😢
yes i heard about that, but this might change in the future
Do you have the github link?
github.com/FrancescoXX/go-fullstack-app
Showing api executable not found
did you cloned the project or coded it on your own?
@@francescociulla coded it. I found that the executable files are not running from the app dir,
Its running successfully from the following path usr/local/bin/api
Sir please help me i got this error 0.227 go: errors parsing go.mod:
0.227 /app/go.mod:3: invalid go version '1.22.1': must match format 1.23
------
failed to solve: process "/bin/sh -c go get -d -v ./..." did not complete successfully: exit code: 1,,,, in 36.36 min in video Please help me
are you using the github repository or coded it from scratch?