OHDSI Home | Forums | Wiki | Github

Broadsea ATLAS: No login button

I have a Broadsea container running ATLAS + WebAPI v. 2.10.0, and I’d like to enable security settings. I’m following the Broadsea documentation for enabling security and have modified config-local.js for Active Directory as follows, using the relevant section of /js/config/app.js:

define([], function () {
	var configLocal = {};

	configLocal.api = {
			name: 'OHDSI',
			url: 'http://localhost:8080/WebAPI/'
		};

		configLocal.userAuthenticationEnabled=true;
		configLocal.authproviders = [{
     			"name": "Active Directory LDAP",
     			"url": "user/login/ad",
     			"ajax": true,
     			"icon": "fa fa-cubes",
     			"isUseCredentialsForm": true
    		}]

	return configLocal;
});

However, this doesn’t add a sign-in link at the top right. Is anything else needed?

Could be a cache issue of your browser, can you ctrl-shift-i to open up dev console so that you can do a ‘hard reload’ of the page which will remove any local cached pages.

In addition, to make sure you changed the correct file, you can also look at the ‘network’ tab and search for config-local.js to make sure the downloaded file has the modifications. You can also tell on this panel if the file was loaded from cache or not.

1 Like

I believe the config-local included in Broadsea isn’t pushed into the Atlas container by default, rather it collects it from the Atlas docker hub image, which won’t have security enabled.

If you’ve already updated the config-local.js in the Broadsea folder, then simply add this to your ohdsi-atlas container entry. It will add the file as a volume into the container, and the env variable CONFIG_PATH is already established in the container for overriding the config-local.js.

volumes:
      - ./config-local.js:/tmp/config-local.js:ro
environment:
      CONFIG_PATH: "/tmp/config-local.js"
1 Like

Or did you modify the config-local.js that was in the container after launching it?

Thanks very much, @Chris_Knoll and @Ajit_Londhe! I believe both of your suggestions were needed.

Solution: On my system, docker-compose.yml did not have an entry for “CONFIG_PATH”, so I added one to be sure and cycled the container through a couple restarts. The login button still didn’t appear, so I right clicked the restart button and clicked “Empty Cache and Hard Reload” on the menu (which only appears if the developer console is open [Ctrl-Shift-i]). The “Sign In” link is now available.

1 Like

@Ashlin_Harris – did you need to also add that “volume” statement? Or just set the CONFIG_PATH env variable?

No, but only because the file already had a similar volume statement.

1 Like

@Ashlin_Harris could you share the modified/redacted docker-compose.yml? I’m having quite a time enabling security, and I think you have solved a problem that I am facing currently.

Thanks in advance.

Sorry @Sanjay_Udoshi, I’ve only been able to resolve issues related to config-local.js so far: a login button is present, but I haven’t logged in successfully yet.

Comparing my local docker-compose.yml with the Broadsea example, there is an additional line in the volumes section:

- ./config-gis.js:/usr/local/tomcat/webapps/atlas/js/config-gis.js:ro

Otherwise, it follows the example, just with local names and values. I also added the configuration settings exactly as suggested by @Ajit_Londhe rather than adjust the value of CONFIG_PATH, so the file config-local is present as 2 separate volumes, but I don’t think that is necessary.

1 Like

Thanks Ashlin. I’ll let you know if we succeed on my end and I’ll provide details when we do. This seems to be a common barrier to entry to enable the ecosystem of OHDSI applications.

I just PMed you both about my Broadsea development branch, please have a look.

t