1
0
mirror of https://github.com/openshift/installer.git synced 2026-02-06 09:47:02 +01:00
Commit Graph

4041 Commits

Author SHA1 Message Date
OpenShift Merge Robot
35f1acae0a Merge pull request #6739 from bfournie/agent-command
OCPBUGS-4874: Remove order dependency for agent CLI string
2023-01-06 07:44:02 -05:00
OpenShift Merge Robot
9110f2d5a1 Merge pull request #6695 from rna-afk/gcp_cpms
CORS-2449: Create CPMS manifest
2023-01-05 19:01:29 -05:00
OpenShift Merge Robot
626e1ee6aa Merge pull request #6534 from barbacbd/OCPBUGS-2881
OCPBUGS-2881: Destroy the service and host project dns records
2023-01-05 19:01:21 -05:00
OpenShift Merge Robot
f34998abf9 Merge pull request #6617 from shiftstack/fix-bootstrap-destroy-command
Bug OCPBUGS-3921: OpenStack: fix bootstrap destroy cmd
2023-01-05 12:58:58 -05:00
OpenShift Merge Robot
565cbf8ed0 Merge pull request #6730 from zaneb/wait-for-error-reporting
OCPBUGS-3706: Improve error reporting from agent wait-for install-complete
2023-01-05 03:43:14 -05:00
Bob Fournier
1b325fc0fc OCPBUGS-4874: Remove order dependency for agent CLI string
In order to remove the dependency on providing baremetal hosts, the
"agent" string is checked in the CLI command. This fixes the
requirement that it always be after the "create".

(Note that this solution is an improvement, but not perfect, as it can
result in a false positive if "agent" is used elsewhere in the command
line. A more complete solution will come in a later release).
2023-01-04 16:03:14 -05:00
OpenShift Merge Robot
23ed14be88 Merge pull request #6665 from miyamotoh/vpc-region-zone-from-name-subnets
Better logic to derive vpcRegion/Zone from vpcName/Subnets
2023-01-04 15:58:18 -05:00
OpenShift Merge Robot
d3b3b71fdc Merge pull request #6697 from zaneb/console-error-immediate
OCPBUGS-3032: Report status on the console immediately
2022-12-23 17:17:07 -05:00
Zane Bitter
9b613cf816 OCPBUGS-3706: Don't report bootstrap errors as install errors
When running the 'agent wait-for install-complete' command, we first
check that bootstrapping is complete (by running the equivalent of
'agent wait-for bootstrap-complete'. However, if this failed because the
bootstrapping timed out, we would report it as an install failure along
with the corresponding debug messages (stating that the problem is with
the cluster operators, and inevitably failing to fetch data about
which).

If the failure occurs during bootstrapping, report it as a bootstrap
error the same as you would get from 'agent wait-for
bootstrap-complete'.
2022-12-22 12:02:09 -05:00
Zane Bitter
48058f9cb9 Refactor agent wait-for commands
Create the Cluster object outside of the WaitFor...() implementation and
pass it in, instead of creating it inside and returning it.
2022-12-22 11:34:58 -05:00
Zane Bitter
596f1622fe Remove dead code
err is always nil at this point, because we check it further up and it
is not overwritten by the variable of the same name that is shadowing it
inside the anonymous function, as was probably intended.
2022-12-22 10:02:55 -05:00
Pawan Pinjarkar
dc031eff41 AGENT-438: Create PXE files (#6699)
* AGENT-438: Create PXE image assets

Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>

* typo

Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>

* Rename to pxe-files

Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>

* Only extract the required pxe files into tmp dir

* gofmt

Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>

* Restructure and use os.MkdirTemp()

* Correctly create files with --dir flag

* golint

* Rename file

Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>

* Integration test, golint

Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>

* go-lint

* Use archname

* Make it work for disconnected

* Rename var

Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>

* Use baseImage.File.Filename

* Use multiple readers

* Review suggestions

Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>
2022-12-22 08:53:06 -05:00
Maysa Macedo
c4393115da Bug OCPBUGS-3921: OpenStack: fix bootstrap destroy cmd
The installer bootstrap destroy command does not locate the
clouds.yaml file containing the credentials when it's present
in the current directory. This commit fixes the issue by ensuring
that prior to destroying the resources, the installer attempts to
look for the OS_CLIENT_CONFIG_FILE env var and if unset looks for
any clouds.yaml file in the current directory.
2022-12-22 09:43:01 +01:00
OpenShift Merge Robot
7f980fc9a2 Merge pull request #6656 from shiftstack/refactor_deps
openstack: Rely on Go's stdlib for errors
2022-12-21 18:56:39 -05:00
Zane Bitter
804af8c35e Remove unnecessary warning
All errors produced by this function are accompanied by Fatal-level
logs, so there is no need for an additional warning-level log.
2022-12-21 16:58:00 -05:00
Hiro Miyamoto
42e453184b Better logic to derive vpcRegion/Zone from vpcName/Subnets
Signed-off-by: Hiro Miyamoto <miyamotoh@us.ibm.com>
2022-12-20 13:39:36 -05:00
Brent Barbachem
f23b44adf8 Added ability to search for and delete dns records in host and service projects.
**Search for DNS private and public zones in the host and service project.
**Attempt to match DNS records between entries from different projects.
**Loop over all of the possible public zones instead of assuming the first that is found
with a matching domain.
2022-12-19 09:16:39 -05:00
Brent Barbachem
887532375a GCP: Tfvars will determine the user has create firewall permissions
** Create Firewall permissions option is removed from the install config. The
terraform vars checks the user permissions in the project to determine if the
user can create firewall rules. If the user does not have permissions to create firewall
rules then the firewall rules are skipped.
2022-12-19 08:33:29 -05:00
OpenShift Merge Robot
1e05df75d1 Merge pull request #6707 from shiftstack/204_nocontent_objects
OCPBUGS-4941: OpenStack: Force JSON content-type in Swift object listing
2022-12-19 07:04:53 -05:00
Pierre Prinetti
3b6dbeba17 OpenStack: Force JSON content-type in Swift object listing
Some OpenStack object storages respond with `204 No Content` to list
requests when there are no containers or objects to list. In these
cases, when responding to requests with an `Accept: text/plain` or no
`Accept` header, some object storages omit the `content-type` header in
their status-204 responses.

Now, Gophercloud throws an error when the response does not contain a
`content-type` header.

With this change, we work around the issue by forcing Gophercloud to
request a JSON response from the object storage when listing objects.
When passed an `Accept: application/json` header, the server responds
with `200 Ok` and a `content-type` header in our tests.

This solution gives us a fix that is easily backportable because it
doesn't require any dependency bump.
2022-12-18 21:49:59 +01:00
Pierre Prinetti
0b796af553 openstack: Rely on Go's stdlib for errors
The package github.com/pkg/errors has been archived and its
functionality integrated in Go's standard library.
2022-12-18 21:48:30 +01:00
OpenShift Merge Robot
2473a10fb9 Merge pull request #6700 from hamzy/powervs-cleanup-context-timeout
PowerVS: Defer cancel when calling contextWithTimeout
2022-12-17 10:37:59 -05:00
OpenShift Merge Robot
08d4c3838e Merge pull request #6712 from r4f4/go-lint-fixes
linter: fix issues since revision 75173a17cf
2022-12-17 06:40:53 -05:00
Patrick Dillon
4442bbd121 OCPBUGS-4809: Azure: toggle image in machinesets (#6694)
* Azure: toggle image in machinesets

Hive vendors the installer and uses the asset package to generate
machinesets for scaleup. Because Hive is using the latest code version
but installing multiple previous versions, the machinesets--particularly
the values--need to be backward compatible.

In this particular case, the installer switched from using Azure
managed images to image galleries in 4.12. In 4.12+ Azure machinesets
expect an image referencing an image gallery, while prior to this change
the machinesets looked for a managed image.

This commit updates the machineset code to allow a toggle which will
allow Hive to generate Azure machinesets utilizing managed images,
which should be done with 4.11 and earlier clusters.

This change also future proofs the 4.12+ by switching the machinesets
to use the latest version, rather than tying them to a particular RHCOS
version.

* fixup! hyperv gen support for managed image
2022-12-16 16:47:13 -05:00
Rafael Fonseca
ef95c1bcd4 linter: fix issues since rev 75173a17cf 2022-12-16 18:14:21 +01:00
OpenShift Merge Robot
5ef0adfaaa Merge pull request #6688 from pawanpinjarkar/OCPBUGS-3706-new
OCPBUGS-3706: Wait longer for baremetal
2022-12-15 17:21:05 -05:00
rna-afk
bbfafec2df gcp: Create CPMS manifest
Creating CPMS manifest for GCP.
2022-12-15 13:32:18 -05:00
OpenShift Merge Robot
9377cb3974 Merge pull request #6643 from r4f4/gci-import-order-1
Fix import order using the gci tool
2022-12-15 08:20:08 -05:00
Zane Bitter
4daff6117f Update console debug messages immediately
When updating the console debug messages, don't wait for the next
refresh. Issue a reload, which will cause the console to be redisplayed
unless the user has already started logging in.
2022-12-14 14:35:07 -05:00
Mark Hamzy
202ed755ed Defer cancel when calling contextWithTimeout
Every place where this occurs:
        ctx, _ := o.contextWithTimeout()
Change to:
        ctx, cancel := o.contextWithTimeout()
        defer cancel()

NOTE:
For the functions instance.NewIBMPI.*Client(, we now use context.Background()
because o.contextWithTimeout() and then cancel() will cause future calls to
these functions to error out with "context canceled."
2022-12-14 13:11:49 -06:00
OpenShift Merge Robot
5a8e9937c9 Merge pull request #6528 from r4f4/aws-destroy-elb-listener
OCPBUGS-2891: aws: destroy: delete ELB listeners
2022-12-14 13:34:06 -05:00
OpenShift Merge Robot
011ba8af0e Merge pull request #6686 from hamzy/powervs-defer-loadsdk-debug
Consolidate loadsdk debug statements
2022-12-14 09:30:37 -05:00
Pawan Pinjarkar
379d9f6f3d Just increase bootstrap timeout 2022-12-13 10:19:16 -05:00
Rafael Fonseca
80e02a974d chore: fix import order 2022-12-13 15:40:58 +01:00
Pawan Pinjarkar
0772d2cd55 gofmt
Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>
2022-12-12 09:27:50 -05:00
OpenShift Merge Robot
780b29adbe Merge pull request #6614 from r4f4/azure-servp-3
OCPBUGS-4549: azure: replace deprecated AD Graph API
2022-12-10 13:20:35 -05:00
OpenShift Merge Robot
3c693eb1c8 Merge pull request #6683 from pawanpinjarkar/save-rendezvousIP-in-file
Save rendezvous IP in a file 'rendezvousIP' alongside the ISO
2022-12-09 20:56:04 -05:00
Pawan Pinjarkar
dceae07887 Increase bootstrap timeout to 60 min 2022-12-09 16:10:04 -06:00
Pawan Pinjarkar
cc16c0d8ad OCPBUGS-3706: Wait longer for baremetal 2022-12-09 15:54:25 -06:00
Pawan Pinjarkar
c50b6db3df Review suggestions
Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>
2022-12-09 09:41:59 -05:00
Mark Hamzy
43583abd51 Consolidate loadsdk debug statements
Merge all of the debug output statements into one defer code block.
2022-12-09 08:38:19 -06:00
Bob Fournier
20e57c6e10 OCPBUGS-3987: Check nmstateconfig content in agent-config.yaml
The NMStateConfig data in agent-config.yaml was not being validated,
it was only checked in the Load() i.e. the data in nmstateconfig.yaml.
This can result in invalid configurations being stored in ignition
and then the install would fail when these configs were validated
by assisted-service.

The change is to do the same checks in Load() and Generate().
2022-12-08 19:40:50 -05:00
Pawan Pinjarkar
17034e1d7d Save rendezvous IP in a file 'rendezvousIP' alongside the ISO
Signed-off-by: Pawan Pinjarkar <ppinjark@redhat.com>
2022-12-08 17:38:16 -05:00
OpenShift Merge Robot
e28401ae70 Merge pull request #6662 from bfournie/debug-log-oc
OCPBUGS-4367: Fix missing debug messages when getting baseISO
2022-12-08 14:36:37 -05:00
Bob Fournier
144a72aedf use defer to set log level after staticnetworkconfig 2022-12-08 11:03:24 -05:00
OpenShift Merge Robot
254a2b7d13 Merge pull request #6591 from hamzy/powervs-destroy-backoff
Use backoff functions in PowerVS destroy logic
2022-12-08 10:19:30 -05:00
Bob Fournier
5538dc538f change back to using new instance of logger for nmstateconfig 2022-12-08 08:18:20 -05:00
Mark Hamzy
da2aea6a8b WIP: Use backoff functions in PowerVS destroy logic
In the destroy logic, use wait.ExponentialBackoffWithContext while
deleting and waiting for PowerVS objects to delete.  Also consistently
use the process of deleting and then requerying to see if they have
been deleted.
2022-12-08 06:43:16 -06:00
OpenShift Merge Robot
01adff5d62 Merge pull request #6544 from zaneb/issue-console
OCPBUGS-3032: Report agent installation problems on the console
2022-12-08 03:00:04 -05:00
OpenShift Merge Robot
ec59cfa3e5 Merge pull request #6596 from rvanderp3/OCPBUGS-3668
OCPBUGS-3668: fully qualified username must be provided
2022-12-07 17:14:31 -05:00