How to solve Apex / Ords Configuration of Static Files - oracle-apex-18.2

I'm using Oracle XE 18C on a Windows platform. I installed Apex 18.2 and then installed ORDS 18.4. I followed the instructions in section 1.3.4.1 in the install guide for Apex 18.2 https://docs.oracle.com/en/database/oracle/application-express/18.2/htmig/configuring-Oracle-REST-data-services.html#GUID-AD38DE06-A560-4D6D-BD50-6E5A8E513BBF.strong text
I created two users: with the following commands:
ALTER SESSION SET CONTAINER=XEPDB1;
create user APEX_LISTENER identified by (password) account unlock;
create user APEX_REST_PUBLIC_USER identified by (password) account unlock;
When I was prompted for "Enter the Apex static resource location" I responded with C:\app\product\apex\images
The install went without an error. I looked at all the logs in C:\Users(my_username). Not a single mention of "error" or "warning".
In the Apex install guide, section 4.6 it instructs to copy the Apex images folder to ORDS. I copied C:\app\product\apex\images to C:\app\product\ords\images. Then I ran #apex_rest_config.sql from SQL Plus. It seemed to complete OK.
When I attempt to access Apex through a browser (localhost:9090/ords/apex) I receive a popup error: "There are issues with the configuration of the Static Files in your environment. Please consult "Configuring Static File Support" section in the Application Express Install Guide."
If I click OK on the prompt I can continue on to the Apex logon screen. I'm able to login and get to the first screen. However I want to address the error before proceeding further.
Any ideas why I'm getting this error? Thanks for looking at this.

After installing XE 18C In edited the TNSNAMES.ORA file:
XEPDB1 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = xepdb1)
)
)
Then I realized that I had to install Apex 18.2 and ORDS in the same PDB Container (XEPDB1). Here are the steps from SQLPlus:
Alter Session set container=XEPDB1;
#apexins SYSAUX SYSAUX TEMP /i/ -- (Note: This creates users APEX_180200, APEX_PUBLIC_USER, APEX INSTANCE_ADMIN_USER and FLOWS_FILES in the XEPDB1 container. Only APEX_INSTANCE_ADMIN_USER is Open. All others are locked.)
Select Status from dba_registry Where Comp_ID = 'APEX'; -- (This should return “VALID” if apex was properly installed.)
#apxchpwd -- (Note: this will change the password for the Apex ADMIN account)
Alter Profile DEFAULT limit password_life_time unlimited;
Alter User APEX_PUBLIC_USER Identified by password account unlock;
Alter User ANONYMOUS account unlock;
Alter User FLOWS_FILES account unlock;
Alter User APEX_180200 account unlock;
Commit;
#apex_rest_config.sql -- (Note: This creates APEX_LISTENER and APEX_REST_PUBLIC_USER in the XEPDB1 container and gives them the password you specify in this step.)
#apex_epg_config.sql C:\app\product
Alter User APEX_LISTENER account unlock;
Alter User APEX_REST_PUBLIC_USER account unlock;
Alter Session set container = CDB$ROOT;
Alter User XDB account unlock;
Exit
From there I installed ORDS 18.4
java -jar ords.war install advanced
Configuration Data = C:\app\product
Database Service Name = XEPDB1
Apex Static Resource Location = C:\app\product\apex\images

Related

Get current user windows MicrosoftAccount in node.js

In a node.js cli app running on a windows machine, you can get the current local user using:
// method 1
const os = require('os')
console.log(os.userInfo())
// method 2
console.log(`${process.env.USERDOMAIN}\\${process.env.USERNAME}`)
Which outputs:
# METHOD 1
{
uid: -1,
gid: -1,
username: 'adam',
homedir: 'C:\\Users\\adam',
shell: null
}
# METHOD 2
MYPC\adam
However, in modern Windows OS (e.g. Windows 10, 11), many users opt to sign-in with a Microsoft account. Apparently, this means there are 2 mirrored accounts on the machine:
{USERDOMAIN}\{USERNAME} where USERDOMAIN could be the local machine name or the enterprise network domain name
MicrosoftAccount\{EmailAddress} where EmailAddress is the Microsoft account username
How can I retrieve the 2nd variant of the username in node.js?
IMHO, you can use the windows registry hive HCU, which maps to the current user hive and find the data you need somewhere in the hive, though I don't know the exact path.
Alternatively, you could try running some PS1 script/command that will get this information for you, but this method cannot be reliable, since this option (running ps1) may be disabled on some machines by the user.
And last but not least, you can always build a native Node.js extension, using C++ and access the native Windows API to do what you want :)

How can you update gitlab users after changing LDAP OU

I'm currently playing around with gitlab-ce (omnibus, on an Ubuntu VM) in an environment with LDAP authentication.
The LDAP administrator recently reconfigured the OUs from something like
ou=temp, ou=users, ou=baseinfrastructure to
ou=users, ou=baseinfrastructure.
Now when I do something as simple as git pull with a regular user account, that user account will be set to ldap_blocked since gitlab queries for the user with the temp part in the cn string and obviously doesn't find it.
Is there a way to update the users or something else so gitlab no longer queries with the ou=temp, part?
After some search, I've found out the information is stored in the identities table.
In gitlab omnibus, you can start a database console using gitlab-psql.
In my case, the required query for verifying I'm doing the right thing was:
SELECT external_uid, replace(external_uid, 'ou=temp,', '') FROM identities;
and then actually replacing them by executing:
UPDATE identities SET external_uid = replace(external_uid, 'ou=temp,', '');
For a single user you can use gitlab-rails console.
Find your user:
user = User.find_by_email("user#email")
Get user extern_uid:
user.ldap_identity.extern_uid
the above should print result similar to: => "uid=username,ou=people,dc=example,dc=com"
Update values as neccesary:
user.ldap_identity.extern_uid = "uid=newusername,ou=newpeople,dc=example,dc=com"
Verify:
user.ldap_identity.extern_uid
=> "uid=newusername,ou=newpeople,dc=example,dc=com"
And finally save
user.save
I believe this script Gitlab rake task to mass update ldap dn may be useful for updating multiple users at once.

unable to login with default user name administrator after installing Kentico

I have installed the Kentico and it generated an URL. When we try to login with a default username 'administrator' and getting an error message as follow.
[WebFarmTaskManager.CanCreateTask]: Task type 'DICTIONARYCOMMAND' is not supported. The task needs to be registered with WebFarmHelper.RegisterTask method.
Publish first CMSApp_AppCode, then, in the same folder, CMSApp, however disable the option "Delete all existing files prior to publish" in CMSApp

openAm 12.0.0 failed to add user with external opendj

I had build and install openam 12 from source code, from svn checkout
link:
svn checkout https://svn.forgerock.org/openam/tags/12.0.0/openam/
after that I had used external OpenDJ-2.6.0 with openam , installation is successful.
But when I add new user and click OK I got error
Error :”Plug-in org.forgerock.openam.idrepo.ldap.DJLDAPv3Repo encountered a ldap exception. ldap errorcode=65”
Also check in OpenDJ-2.6.0 logs access logs:
[25/Feb/2015:16:27:00 +0530] ADD RES conn=6 op=131 msgID=132 result=65 message=”Entry uid=indranis,dc=xyz,dc=net violates the Directory Server schema configuration because it contains an unknown objectclass iPlanetPreferences” etime=2
Same exception I got when I try to add group ,
but able to solve referring following link:
https://java.net/projects/opensso/lists/users/archive/2007-08/message/21
remove manually from Data Store – opends and remove groupOfURLs or groupOfUniqueNames from the LDAP Groups Object Class
Is there is issue with openDJ2.6 version , or any changes do I need to configure?
I got issue resolve, by installing openAM with embeded datastore and and then after installation ,configured it with an external opendj store and removed embedded one.

Windows Azure - Migrations is enabled for context 'ApplicationDbContext'

Following this blog with steps by steps http://www.windowsazure.com/en-us/documentation/articles/web-sites-dotnet-deploy-aspnet-mvc-app-membership-oauth-sql-database/#setupdevenv
If I run from my local machine then i see the data which is coming from Windows Azure db and i can add and update or delete ... perfectly working fine but the problem is when I publish my application to Windows Azure and I able to see my page and all the static pages are working fine but except one page which is interacting with database.
here is my web.config connection string:
<add name="DefaultConnection" connectionString="server=tcp:* insert server name*.database.windows.net,1433;Database=* insert database name *;User ID=*insert username *#* insert server name*;Password={*insert password here *};Trusted_Connection=False;Encrypt=True;Connection Timeout=30;" />
I get this message when i try to access the page from http://XXXX.azurewebsites.net/Employee
Error Message:
Migrations is enabled for context 'ApplicationDbContext' but the database does not exist or contains no mapped tables. Use Migrations to create the database and its tables, for example by running the 'Update-Database' command from the Package Manager Console.
Seems that your database cannot be created automatically. The fastest way to fix that is to follow the suggestion from your error message. Open your Package Manager Console with the project, which contains the connection string and the Configuration.cs (your migrations), selected as the startup project and run Update-Database. It could be that you must pass some parameters to this command if you have changed something on your migrations.

Resources