Error when I try to create a new account with "deis register" command - amazon-ec2

I've a fresh install of Deis on AWS but I get this error when I try to register an user:
http://deis.XXXX.com does not appear to be a valid Deis controller.
Also, when I try to make a curl to the ELB or any node it return a timeout, but I think that it's a normal behaviour due to the security group configutarion.
It could be a proxy configuration error? Because when I installed Deis I got this error:
Enabling proxy protocol failed, please enable proxy protocol manually after finishing your deis cluster installation.
And I enabled it manually with:
deisctl config router set proxyProtocol=1
Thanks!

Once you have enabled proxyProtocol on the router you should be able to run deisctl install platform without issues.
Is that not the case?

I had this issue when I hadn't registered my deis cluster domain with global dns - i.e., I had only added it to a Route 53 hosted zone that wasn't actually public.
I fixed it by adding an A ALIAS record in Route 53 pointing a wildcard sub-domain under my existing domain to the deiswebelb host.
Name:
*.apps.example.com
Type: A
Value: ALIAS dualstack.deis-deiswebelb-1abcdefghijkl-1234567890.us-east-1.elb.amazonaws.com

Related

Docker error "https://registry-1.docker.io/v2/": x509 certifacte not valid for registry-1.docker.io in macOS

I am setting up the airflow in my macOS using Docker and I am encountering this below error while doing the setup. Any help would be appreciated.
ERROR: Get "https://registry-1.docker.io/v2/": x509: certificate is valid for *.integration.livongo.com, integration.livongo.com, not registry-1.docker.io
Thanks.
I have had the same issue this week when upgrading to the latest Docker Desktop 4.4.4.
I am behind a company proxy which injects it's own CA certificate which can cause this problem. If that is your case, make sure you know what is the http & https proxy URL or IP if there is one, and add it in the Docker Desktop settings, under Resources/Proxies.
You may also add the http_proxy and https_proxy environment variables to your system with the full url,IP of the proxy server.
If the problem persists, roll back to a previous version of Docker Desktop. That's what I ended up doing in the end because the latest version didn't work with my proxy configuration.

gcloud login network connection failed issue

I tried to connect gcloud with gcloud init. I got Network connection error.
I tried to fix with Network connection problems in Google Cloud SDK while I have access to google or website like google app engine in my browser
gcloud config set proxy/type socks5
gcloud config set proxy/address 127.0.0.1
gcloud config set proxy/port 1086
But it still does not work for me.
My log is:
Welcome! This command will take you through the configuration of gcloud.
Settings from your current configuration [default] are:
core:
disable_usage_reporting: 'False'
proxy:
address: 127.0.0.1
port: '1080'
type: socks5
Pick configuration to use:
[1] Re-initialize this configuration [default] with new settings
[2] Create a new configuration
[3] Switch to and re-initialize existing configuration: [cindy]
Please enter your numeric choice: 1
Your current configuration has been set to: [default]
You can skip diagnostics next time by using the following flag:
gcloud init --skip-diagnostics
Network diagnostic detects and fixes local network connection issues.
Checking network connection...done.
ERROR: Reachability Check failed.
Cannot reach https://www.google.com (error)
Cannot reach https://accounts.google.com (error)
Cannot reach https://cloudresourcemanager.googleapis.com/v1beta1/projects (error)
Cannot reach https://www.googleapis.com/auth/cloud-platform (error)
Cannot reach https://dl.google.com/dl/cloudsdk/channels/rapid/components-2.json (error)
Network connection problems may be due to proxy or firewall settings.
Current effective Cloud SDK network proxy settings:
type = socks5
host = 127.0.0.1
port = 1080
username = None
password = None
What would you like to do?
[1] Change Cloud SDK network proxy properties
[2] Clear all gcloud proxy properties
[3] Exit
It is due to redirection from goolge account to localhost for acquiring token Try to login using firefox
Considering the error and mainly the following part of the error, it seems that you are facing issues with your proxy and firewall settings and configuration.
Network connection problems may be due to proxy or firewall settings.
Due to this error, you need to configure your SDK to be used with proxy and firewall. I would recommend you to take a look at the documentation Configuring Cloud SDK for use behind a proxy/firewall, to get more information and steps on how to achieve it and avoid the error that you are facing.
Besides that, I could find the below two posts from the Community, of users that are facing similar cases that you are facing.
ERROR: Reachability Check failed. #51
gcloud utility not working #25
Let me know if the information helped you!
For the people who still have this problem.
Try to use IPV4 first as IPV6 is still buggy for many systems.
For Linux, you can just uncomment or add the following line in /etc/gai.conf file:
precedence ::ffff:0:0/96 100
For other systems, you can google the set-up

MariaDB on HomeBrew: Enabling Network Access

I have just installed MariaDB 10.4 using Home Brew. I was finally able to set the root password, and I am now trying to enable network access.
I think have added the correct directive:
bind-address=0.0.0.0
The thing is, is it to the correct my.cnf? I have tried adding it to /usr/local/etc/my.cnf as well as to a my.cnf I found in various Cellar directories.
It doesn’t seem to work. I get the message
Host … is not allowed to connect to this MariaDB server
even when I try from the local machine.
Am I setting the directive in the wrong file, or is there something else I should be doing.
Check that your user have the privilege to access the database from remote by running:
SELECT User, Host FROM mysql.user
Check also that you don't have the skip_networking configuration property set.
Read also the following documentation page: Configuring MariaDB for Remote Client Access

Unable to load SiteMinder host configuration object or host configuration file

The application log in the event viewer shows
Unable to load SiteMinder host configuration object or host configuration file
for Siteminder 12.51 on IIS 7.5 (64bit) OS Windows 2008 (64bit).
When do you get the error? Is it when you're configuring the Webagent?
Anyway, verify the following.
Verify your environment variables are set correctly, if must have references to the Webagent files, you may need to export the envvars in the webagent or policy server folder (nete_wa_env...) file.
if the host config object you're using exists? Verify this using the
Admin UI
If the hostname is configured in the policy server as a trusted host
Verify if the settings are correct in the corresponding SmHost.conf file in the webagent folder
Verify and eliminate any duplicate or conflicting lines in your IIS config files which refer to siteminder.
Verify the host config object and the agent config object settings.
make sure WebAgent.conf is pointing to the correct SmHost.conf and SmHost.conf has the correct HostConfigObject defined (with the exact case that is used in the Policy Store).
If the HCO in the Policy Store is named "DefaultHostSettings" and SmHost.conf contains HostConfigObject=defaulthostsettings you will get this type of error.
Try re-registering the web agent with the policy server using the smreghost command.

Heroku Database Connection Properties

I'm trying to perform a relatively trivial task: I want to connect to a Heroku database. I have created the database and have been issued credentials from the Heroku site. However, when I try to connect to this database using anything besides the terminal 'heroku' command line client, I get fatal errors or cannot connect errors.
The two tools that I tried to connect with outside of the Heroku terminal application are: Navicat and IntelliJ.
The error that I receive in Navicat when trying to connect to the database is:
could not connect to server: Host is down
Is the server running on host "ec2-107-21-112-215.compute-1.amazonaws.com" and accepting
TCP/IP connections on port 5432?
My connection settings are as follows:
Connection Name Heroku Dev Test
Host Name/IP Address ec2-107-21-112-215.compute-1.amazonaws.com
Port 5432
Navicat doesn't even seem to be making an attempt to connect to that hostname.
When I try to connect with IntelliJ, using the full credentials, I get the following error:
java.sql.SQLException: FATAL: no pg_hba.conf entry for host "75.168.4.146", user "rphbqggxeokuxl", database "dc008iqk0rq4j5", SSL off
Again, I'm using the credentials that the Heroku application provides me with when accessing my database on their website.
Has anyone ran into this Heroku connection issue before?
I also had the issue with the FATAL: no pg_hba.conf entry for host error message.
I solved the connection issue to my Heroku Postgres database by adding the following to my JDBC string: &ssl=true&sslfactory=org.postgresql.ssl.NonValidatingFactory.
Example
jdbc:postgresql://host:port/database?user=username&password=secret&ssl=true&sslfactory=org.postgresql.ssl.NonValidatingFactory
You will need the SSL option only if SSL is enabled for your Postgres database (which is the default).
Hint
If you want to check your database connection properties, then just run the following command with the Heroku Toolbelt: heroku pg:info --app your-heroko-appname (make sure that you have Postgres insalled to run this command in your terminal)
The pg:info command will also tell you that sslmode is set to require.
To test the database connection I recommend SQL Power Architect as it is the tool which I was using to check my solution.
Heroku provides this information for connecting from external sources:
https://devcenter.heroku.com/articles/heroku-postgresql#external-connections-ingress
The second error message indicates PostgreSQL is not configured to accept the connection you're trying to make. Given the information Heroku provides, a good guess is that you're not connecting with SSL. Try to enable that on your connection.
Here are instructions for using SSL with Navicat: http://mirror.navicat.com/manual/online_manual/en/navicat/rv_manual/ClientCert.html.
This may be helpful in configuring Intellij to use SSL: https://devcenter.heroku.com/articles/connecting-to-relational-databases-on-heroku-with-java#connecting-to-a-database-remotely.
IntelliJ -> Datasources and Drivers
After you've configured the host, database and user details under the General tab switch to the Advanced tab and ensure that you've added the following:
ssl = true
sslfactory = org.postgresql.ssl.NonValidatingFactory
sslmode = require
You may consider setting a ENVIRONMENT CONFIG VARIABLE 'PGSSLMODE' to 'require' via Heroku's web interface or CLI.
Case: Postgres dB set up as a Heroku add-on and attached to app on a Heroku Dyno.
Heroku's instructions unfortunately leave out any mention of how to activate SSL, even though it is required for any dB tier starting with Standard-0 by default.
Follow all of the pg-copy or pg-upgrade steps (preferred approach depends on your version of Postgres) in Heroku instructions; however, before decommissioning the old database (if relevant) -- add the PGSSLMODE environment variable.
The instructions sufficiently cover how to promote the new database (and, consequently set the DATABASE_URL), so no changes/modifications to them should be required.
Wanted to help others who might run into this.
If you're supplying the Username and Password in seperate fields rather than on the command line, you need to use a ? between the database name and ssl=true and discard the first &
jdbc:postgresql://host:port/database?ssl=true&sslfactory=org.postgresql.ssl.NonValidatingFactory
That's the command line that finally allowed me to connect to a PostgreSQL database using SQL Power Architect
For those who might be using Spring Boot and having the configuration provided through the DATABASE_URL environment property (not system property), the suffix can be added to the property:
?ssl=true&sslfactory=org.postgresql.ssl.NonValidatingFactory
and passed through with a slight modification to the config bean:
#Bean
public BasicDataSource dataSource() throws URISyntaxException {
URI dbUri = new URI(System.getenv("DATABASE_URL"));
String username = dbUri.getUserInfo().split(":")[0];
String password = dbUri.getUserInfo().split(":")[1];
StringBuilder dbUrl = new StringBuilder(128);
dbUrl.append("jdbc:postgresql://")
.append(dbUri.getHost()).append(":")
.append(dbUri.getPort())
.append(dbUri.getPath());
String query = dbUri.getQuery();
if (null != query && !query.isEmpty()) {
dbUrl.append("?").append(query);
}
BasicDataSource basicDataSource = new BasicDataSource();
basicDataSource.setUrl(dbUrl.toString());
basicDataSource.setUsername(username);
basicDataSource.setPassword(password);
return basicDataSource;
}
I'm using node.js and was trying to run my knex migrations for my Heroku app. I tried appending ?sslmode=require to the connection URL but it didn't work. I added ?ssl=true instead and now it works perfectly.
Here's an example Heroku PostgreSQL connection URL that works:
postgres://user:password#ec2-12-34-56-78.compute-99.amazonaws.com:port/databasename?ssl=true
Add or edit the following line in your postgresql.conf file :
listen_addresses = '*'
Add the following line as the first line of pg_hba.conf. It allows access to all databases for all users with an encrypted password:
TYPE DATABASE USER CIDR-ADDRESS METHOD
host all all 0.0.0.0/0 md5
Restart postgresql service:
net stop postgresql-9.0 & net start postgresql-9.0
(version should be based on your installation) -- On windows (run cmd as an administrator).
sudo service start postgresql -- On linux (or according to your linux distribution.)
const pool = new Pool({
connectionString: process.env.DATABASE_URL,
ssl: {
rejectUnauthorized: false
}
});

Resources