-
Notifications
You must be signed in to change notification settings - Fork 10
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
Trcotton/quickstart readme #66
Closed
Closed
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,14 +33,16 @@ This quickstart makes a few assumptions about the target operating system and is | |
grep LOCAL_IP .env | ||
``` | ||
If you have problems with this step, check to make sure that the main IP address of your host is in `.env` as `LOCAL_IP`. | ||
|
||
1. Update your /etc/hosts to point your system name to your local ip (this is important for valid certs) | ||
1. Start the main services | ||
```bash | ||
docker compose -f base.yml -f postgres.yml -f jwt-security.yml -f haproxy-api-gateway.yml -f openchami-svcs.yml -f autocert.yml up -d | ||
|
||
1. Use docker-compose to bring up the services. Docker compose needs to know about all the files to follow dependencies. | ||
```bash | ||
docker compose -f base.yml -f postgres.yml -f jwt-security.yml -f haproxy-api-gateway.yml -f openchami-svcs.yml -f autocert.yml -f dnsmasq.yml up -d | ||
``` | ||
__If this step produces an error like: `Error response from daemon: invalid IP address in add-host: ""` it means you're missing the LOCAL_IP in step 2.__ | ||
You can fix it by destroying everything, editing `.env` manually and starting over. The command to destroy is the same as the command to create, just replace `up -d` with `down --volumes` | ||
|
||
1. Use the running system to download your certs and create your access token(s) | ||
```bash | ||
# Assuming you're using bash as your shell, you can use the included functions to simplify interactions with your new OpenCHAMI system. | ||
|
@@ -50,22 +52,19 @@ This quickstart makes a few assumptions about the target operating system and is | |
# Create a jwt access token for use with the apis. | ||
ACCESS_TOKEN=$(gen_access_token) | ||
# If you're curious about that token, you can safely copy and paste it into https://jwt.io to learn more. | ||
# Use curl to confirm that everything is working | ||
curl --cacert cacert.pem -H "Authorization: Bearer $ACCESS_TOKEN" https://foobar.openchami.cluster/hsm/v2/State/Components | ||
|
||
1. Confirm services are up and running | ||
Check you can access SMD. Component endpoint is unprotected | ||
```bash | ||
curl --cacert cacert.pem https://foobar.openchami.cluster:8443/hsm/v2/State/Components | ||
# This should respond with an empty set of Components: {"Components":[]} | ||
``` | ||
1. Create a token that can be used by the dnsmasq-loader which reads from smd. This activates our automatic dns/dhcp system. The command automatically adds it to .env | ||
```bash | ||
echo "DNSMASQ_ACCESS_TOKEN=$(gen_access_token)" >> .env | ||
``` | ||
1. Use docker-compose to bring up your dnsmasq contianers. The only difference between this command and the one above is the addition of the `dnsmasq.yml` file. Docker compose needs to know about all the files to follow dependencies. | ||
Check if you can read Redfish endpoints. This endpoint is protected | ||
```bash | ||
docker compose -f base.yml -f postgres.yml -f jwt-security.yml -f haproxy-api-gateway.yml -f openchami-svcs.yml -f autocert.yml -f dnsmasq.yml up -d | ||
curl --cacert cacert.pem -H "Authorization: Bearer $ACCESS_TOKEN" https://foobar.openchami.cluster:8443/hsm/v2/Inventory/RedfishEndpoints | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I guess we are sticking with port 8443 for now then. It might be worth pointing out that this is running on a non-standard port. |
||
``` | ||
|
||
|
||
|
||
|
||
## What's next? | ||
|
||
### Refresh your certificates | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe clarify here that since the endpoint is protected, a token is required. The user should make sure they have set the access token in the step above.