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

Update synapse installation doc #1661

Merged
merged 3 commits into from
Dec 19, 2022
Merged

Conversation

alfogrillo
Copy link
Contributor

Description

This PR updates the documentation for installing a local synapse instance on Mac OS machines.

- **Rust**: run ``curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh``. more information can be found here https://www.rust-lang.org/tools/install
- **icu4c**: Run ``brew install icu4c``
- **Update env variables for icu4c**: if you use zsh run ``echo 'export PATH="/opt/homebrew/opt/icu4c/bin:$PATH"' >> ~/.zshrc``. Otherwise try to update ``.bash_profile`` in the same way. If you can’t find ``icu4c`` in the default homebew folder try to run ``which icu4c`` to find the correct path and update the command above.
- **pg_config**: you can get it by running ``brew install postgresql``
Copy link
Contributor

Choose a reason for hiding this comment

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

In https://github.com/matrix-org/synapse/pull/13480/files, we postulated that libpq would be enough. Had you tried that out?

Copy link
Contributor

Choose a reason for hiding this comment

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

(original issue: matrix-org/synapse#13464)

Copy link
Contributor Author

@alfogrillo alfogrillo Dec 14, 2022

Choose a reason for hiding this comment

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

Do you mean libpq instead of postgresql?
(I think so after reading the original issue, let me try it)

Copy link
Contributor

Choose a reason for hiding this comment

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

Yeah, exactly

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Doesn't work for me:

$ brew install libpq
Warning: libpq 15.1 is already installed and up-to-date.
To reinstall 15.1, run:
  brew reinstall libpq
$ which pg_config
pg_config not found

Copy link
Contributor

Choose a reason for hiding this comment

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

Hm, ok sorry I may have mixed this up then. It's odd though that postgres is not mentioned in the official install instructions?

https://matrix-org.github.io/synapse/latest/setup/installation.html

@clokep
Copy link
Member

clokep commented Dec 14, 2022

Would it be possible to point to the Synapse docs and ensure those are correct instead of duplicating them here?

@alfogrillo
Copy link
Contributor Author

Would it be possible to point to the Synapse docs and ensure those are correct instead of duplicating them here?

@clokep for what I saw the official documentation explains how to install synapse using prebuilt packages or as a PyPI module.
The goal of this update is being able to run a demo from sources which is useful especially for devs.
Do you think this knowledge is useful outside this repo? If yes, where do you think it should go?

@clokep
Copy link
Member

clokep commented Dec 15, 2022

Would it be possible to point to the Synapse docs and ensure those are correct instead of duplicating them here?

@clokep for what I saw the official documentation explains how to install synapse using prebuilt packages or as a PyPI module. The goal of this update is being able to run a demo from sources which is useful especially for devs. Do you think this knowledge is useful outside this repo? If yes, where do you think it should go?

There's a section on what you need to install for macOS: https://matrix-org.github.io/synapse/latest/setup/installation.html#macos

There's also information in the developer guide of requirements: https://matrix-org.github.io/synapse/latest/development/contributing_guide.html#2-what-do-i-need

That seems to already mention rust though.

@alfogrillo
Copy link
Contributor Author

There's a section on what you need to install for macOS: https://matrix-org.github.io/synapse/latest/setup/installation.html#macos

This seems to be under PyPI. The scope is probably different.

There's also information in the developer guide of requirements: https://matrix-org.github.io/synapse/latest/development/contributing_guide.html#2-what-do-i-need

That seems to already mention rust though.

Yeah it's mentioned.
So I guess most of dependencies are covered.
I think just icu4c and pg_config aren't.

The problem I guess is that there aren't platform specific sections for devs?
If so, it seems like there isn't a good spot where to merge this info in.

Copy link
Member

@stefanceriu stefanceriu left a comment

Choose a reason for hiding this comment

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

No matter what you decide these steps worked on my side and look good to me 👍

@alfogrillo alfogrillo merged commit ef5cef9 into develop Dec 19, 2022
@alfogrillo alfogrillo deleted the alfogrillo/update_synapse_test_doc branch December 19, 2022 16:28
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.

4 participants