-
Notifications
You must be signed in to change notification settings - Fork 45
Standardize deployment features #824
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
base: master
Are you sure you want to change the base?
Changes from all commits
88dd7f3
ab6707a
b291fd4
4acf6b3
cbc23f6
f8822eb
28d8f31
4cccc60
2e4b060
f66a764
7d5bd94
3afb179
7a9648c
5842f28
28cf960
c48afa2
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -22,6 +22,12 @@ | |
|
|
||
| prometheus_pass="$(tr -dc A-Za-z0-9 </dev/urandom | head -c 16)" | ||
|
|
||
| # Generate MLS private keys using openssl | ||
| mls_ed25519_key="$(openssl genpkey -algorithm ed25519 2>/dev/null | awk '{printf " %s\n", $0}')" | ||
| mls_ecdsa_p256_key="$(openssl genpkey -algorithm ec -pkeyopt ec_paramgen_curve:P-256 2>/dev/null | awk '{printf " %s\n", $0}')" | ||
| mls_ecdsa_p384_key="$(openssl genpkey -algorithm ec -pkeyopt ec_paramgen_curve:P-384 2>/dev/null | awk '{printf " %s\n", $0}')" | ||
| mls_ecdsa_p521_key="$(openssl genpkey -algorithm ec -pkeyopt ec_paramgen_curve:P-521 2>/dev/null | awk '{printf " %s\n", $0}')" | ||
|
Check warning on line 29 in bin/offline-secrets.sh
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I have a recommendation here, by reading the lines its a bit hard to understand key generate function and how its going to be used the secrets.yaml. Here is my proposal. Lets add the YAML indentation as constant with a comment like: And the add simple function to add indentation for each key we generate here with: Finally generate the keys with this functon: The benefit of this approach is if the indentation changes we just can change the parameter and Kinda DRY.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. okay, agreed, this would be more readable, ill do it 👍 |
||
|
|
||
| if [[ ! -f $VALUES_DIR/wire-server/secrets.yaml ]]; then | ||
| echo "Writing $VALUES_DIR/wire-server/secrets.yaml" | ||
| cat <<EOF > $VALUES_DIR/wire-server/secrets.yaml | ||
|
|
@@ -37,8 +43,8 @@ | |
| awsKeyId: dummykey | ||
| awsSecretKey: dummysecret | ||
| rabbitmq: | ||
| username: wire-server | ||
| password: verysecurepassword | ||
| username: guest | ||
| password: guest | ||
| # These are only necessary if you wish to support sign up via SMS/calls | ||
| # And require accounts at twilio.com / nexmo.com | ||
| setTwilio: |- | ||
|
|
@@ -52,25 +58,38 @@ | |
| awsKeyId: "$minio_cargohold_access_key" | ||
| awsSecretKey: "$minio_cargohold_secret_key" | ||
| rabbitmq: | ||
| username: wire-server | ||
| password: verysecurepassword | ||
| username: guest | ||
| password: guest | ||
| cannon: | ||
| secrets: | ||
| rabbitmq: | ||
| username: wire-server | ||
| password: verysecurepassword | ||
| username: guest | ||
| password: guest | ||
| galley: | ||
| secrets: | ||
| rabbitmq: | ||
| username: guest | ||
| password: guest | ||
| pgPassword: verysecurepassword | ||
| awsKeyId: dummykey | ||
| awsSecretKey: dummysecret | ||
| mlsPrivateKeys: | ||
| removal: | ||
| ed25519: | | ||
| $mls_ed25519_key | ||
| ecdsa_secp256r1_sha256: | | ||
| $mls_ecdsa_p256_key | ||
| ecdsa_secp384r1_sha384: | | ||
| $mls_ecdsa_p384_key | ||
| ecdsa_secp521r1_sha512: | | ||
| $mls_ecdsa_p521_key | ||
| gundeck: | ||
| secrets: | ||
| awsKeyId: dummykey | ||
| awsSecretKey: dummysecret | ||
| rabbitmq: | ||
| username: wire-server | ||
| password: verysecurepassword | ||
| username: guest | ||
| password: guest | ||
| nginz: | ||
| secrets: | ||
| zAuth: | ||
|
|
@@ -86,8 +105,8 @@ | |
| background-worker: | ||
| secrets: | ||
| rabbitmq: | ||
| username: wire-server | ||
| password: verysecurepassword | ||
| username: guest | ||
| password: guest | ||
| EOF | ||
|
|
||
| fi | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,3 @@ | ||
| Added: missing webapp feature flags to webapp example values | ||
| Added: config for MLS deployment into example files | ||
| Added: config for Federation deployment into example files |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1 +1,28 @@ | ||
| # using upstream values for coturn helm | ||
| # using upstream values for coturn helm | ||
| replicaCount: 3 | ||
| # image: | ||
| # tag: some-tag # (only override if you want a newer/different version than what is in the chart) | ||
| config: | ||
| verboseLogging: false | ||
| # rateLimit: | ||
| # allowlist: # List of IPs to be excluded from rate limiting | ||
| # - | ||
| coturnTurnExternalIP: "__COTURN_EXT_IP__" | ||
| coturnTurnListenIP: "__COTURN_HOST_IP__" | ||
| coturnTurnRelayIP: "__COTURN_HOST_IP__" | ||
| coturnFederationListeningIP: "__COTURN_HOST_IP__" | ||
| # Uncomment to enable federation | ||
| # federate: | ||
| # enabled: true | ||
| # port: 9191 | ||
| # dtls: | ||
| # enabled: true | ||
| # tls: | ||
| # issuerRef: letsencrypt-http01 | ||
| # kind: ClusterIssuer | ||
| # certificate: | ||
| # dnsNames: | ||
| # - coturn.example.com | ||
| # - coturn-0.example.com | ||
| # - coturn-1.example.com | ||
| # - coturn-2.example.com |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,4 @@ | ||
| rabbitmq: | ||
| auth: | ||
| username: wire-server | ||
| password: verysecurepassword | ||
| username: guest | ||
| password: guest |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,7 +1,17 @@ | ||
| replicaCount: 3 | ||
| # image: | ||
| # tag: some-tag # (only override if you want a newer/different version than what is in the chart) | ||
| allowOrigin: https://webapp.example.com | ||
| host: sftd.example.com | ||
| replicaCount: 3 | ||
| tls: | ||
| issuerRef: | ||
| name: letsencrypt-http01 | ||
| kind: ClusterIssuer | ||
| # Uncomment to enable SFT to SFT communication for federated calls | ||
| # multiSFT: | ||
| # enabled: true | ||
| # discoveryRequired: false | ||
| # turnServerURI: "turn:coturn.public.ip.address:3478?transport=udp" | ||
| # secret: "coturn_zrest_secret" | ||
| # Turn on secondary IP listener (for internal IP) when using federation | ||
| # internalIpListener: false |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of using
sedhere we could adjust therabbitmqhost parameter in the prod-values.example.yaml file with comment that the default value is for CI and ephemeral deployment. Though we need to make our CI to deploy rabbitmq-external but that is a task on it's own.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, dirty hacks begone :D