Problems with web app -> new to web development

Hello to everyone!
I’m relatively new to web programming and Elixir/Phoenix.

I’m trying to learn wen development using real world examples like this:

I think I have really trivial problem, but unfortunately I don’t know how to solve it.

In a description how to run an application locally I have this kind of instructions:

-You need to setup a postgresql DB version 9.5
-Rename the file dev.secret_example.exs to dev.secret.exs
-Fill out the parameters of dev.secret.exs
-mix ecto.create (Create the DB)
-mix ecto.migrate (Run the migration)
-mix phoenix.server (You’re good to go!)

The problem is after I’ve renamed dev.secret_example.exs to dev.secret.exs
I don’t know how to “Fill out the parameters of dev.secret.exs”…

I know how to change user name and password for PostgreSQL ONLY…

That’s the code that I have:
use Mix.Config

In this file, we keep production configuration that

you likely want to automate and keep it away from

your version control system.

Configure your database

config :cercleApi, CercleApi.Repo,
adapter: Ecto.Adapters.Postgres,
username: “postgres”,
password: “postgres”,
database: “cercle”,
hostname: “localhost???”,
pool_size: 10

config :arc,
bucket: “YOUR_AWS_BUCKET???”,
virtual_host: true

config :ex_aws,
access_key_id: “YOUR_KEY_ID???”,
secret_access_key: “YOUR_SECRET_KEY???”,
region: “YOUR_REGION??? Israel???”

config :cercleApi, basic_auth: [
username: “admin???”,
password: “admin???”,
realm: “Admin Area???”
]

config :mailman,
relay: “smtp.postmarkapp.com”,
port: 587,
username: “SMTP_LOGIN???”,
password: “SMTP_PASSWORD???”,
tls: :always

all the ??? is something I don’t know what to do…

I’m asking for help,
Thanks!

Hi,

Welcome to the forum.
If you are new to web development I suggest, that you should learn first the basics to get a solid foundation.
This foundation will help you to understand all the feature projects you will attempt going further in this field.

So the first thing is to follow the tutorial on phoenix website or better yet read this book https://pragprog.com/book/phoenix14/programming-phoenix-1-4.(I never read the book but heard that it is good, especially because it is written by the creator of elixir and phoenix).

Now back on topic:

In app you are trying out you have the following things:

PostgreSQL is your database, you need to install this and it varies depending on your OS(operating system).

Amazon Web Services(AWS), this a is a very big subject but for you project it seems that they are using it for cloud storage.
You need to create an S3 account iwth aws for this.

Basic login for administrators to the site

At the end there is an email service that will send you emails to a email server or provider so for example: mailgun sendgrid mailchimp etc.
This service will send emails when certain things happen in your application for example singup a user.

They are all advanced things which should be tackled after learning the basics.

Hope this helps.

1 Like

Thanks a lot for an answer !!!

Hope I wouldn’t bother you with couple of other questions:
I’ve installed database, but

  1. hostname: “localhost" (should i change it to something like 4000??),
    pool_size: 10 (should i change it to something else??)
  2. I’ll create an AWS account for this.

Thanks, I’ll check the book too!

You are not bothering me.

By default the hostname is localhost for the server which usually also 127.0.0.1

You don’t need to change the pool_size

With AWS it gets trickier.

So let me offer a good path to start:

HTML CSS Phoenix - this should be the basics, not the github project. That comes after you understand each of this pieces, in web dev the only thing you will have to use a lot is patience and a lot of learning.

Don’t jump ahead.

3 Likes

Also get at praprog discount of 35% at any book they have using the code ElixirForum

More info here

1 Like

Also if you really want to learn by diving right in then I suggest you start with a smaller project like a todo list or a blog.

Something like this https://elixircasts.io/phoenix-contexts

3 Likes

Thanks!

2 Likes

You are welcome