Skip to content

[WIP] Fix for PORTAL_STORAGE_PGHOST in helm deployments #8

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

Merged
merged 3 commits into from
Jan 7, 2019

Conversation

stackedsax
Copy link
Contributor

This is just a WIP PR to see if I'm on the right track here.

This is in reference to Issue Haufe-Lexware/wicked.haufe.io#139. Helm deployments are failing because the PORTAL_STORAGE_PGHOST is using the default value of wicked-database instead of the k8s hostname.

I noticed that updateStep12_v1_0_0c and updateStep10_v1_0_0a both had to explicitly update the k8s environment, so I simply followed that process with updateStep14_v1_0_0e.

I haven't figured out exactly how I'm going to test that the right values are getting set. I'd prefer not to go through the whole process of pushing a new image to a personal docker repo to test this out with helm, but I also can't quite envision how to spin up the docker image by itself and pass it all the variables that get set when I run helm. I thought it might be as simple as setting envName=k8s when I spin up the container, but I tried that and it didn't look like what I was expecting.

At this point, I'd just like to hear feedback that this PR is on the right track. Feedback very welcome, especially if it's "stop, you're doing it all wrong".

@CLAassistant
Copy link

CLAassistant commented Jan 1, 2019

CLA assistant check
All committers have signed the CLA.

@DonMartin76
Copy link
Member

Hi, yes, this is absolutely the right track. Locally, we have all been testing with the sample repository which had those adaptions in place. Thanks a bunch for this!

Unfortunately, I am sick after travelling a lot, so I haven't been able to test this yet. There may also be other loose ends regarding the configuration update, but this is definitely one of the more tedious ones.

There may also be something regarding the redis configuration, have you experienced any issues there?

@stackedsax
Copy link
Contributor Author

Thanks for the feedback, good to know it's the right direction. And sorry that you're ill!

The redis container came up just fine, so nothing to worry about there yet. I suppose it remains to be seen whether the application speaks to the various containers correctly, but as far as kubernetes goes it as alright.

const localEnv = loadEnv(targetConfig, 'localhost');
if (!localEnv.PORTAL_ECHO_URL) {
localEnv.PORTAL_ECHO_URL = {
value: "http://${LOCAL_IP}:5432"
Copy link
Member

Choose a reason for hiding this comment

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

This can't be right, it has to be PORTAL_STORAGE_PGHOST. not PORTAL_ECHO_URL, and the value should just be ${LOCAL_IP}. The password should probably default to the default environment's setting, and as a fallback to kong.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good catch, will fix.

Copy link
Member

Choose a reason for hiding this comment

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

Now it only writes the password, not the host. And the value for the password is a little off perhaps.

@DonMartin76
Copy link
Member

Do you mind if I pull this in and polish the rest myself?

@DonMartin76 DonMartin76 merged commit 587cc29 into apim-haufe-io:wicked_1_0 Jan 7, 2019
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.

3 participants