cleaned up linting and added AAP on Code ready
6
aap-on-crc/.github/linters/.markdown-lint.yml
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"default": true,
|
||||
"MD003": false,
|
||||
"MD013": false,
|
||||
"MD033": false
|
||||
}
|
||||
50
aap-on-crc/.github/workflows/linter.yml
vendored
Normal file
@@ -0,0 +1,50 @@
|
||||
---
|
||||
###########################
|
||||
###########################
|
||||
## Linter GitHub Actions ##
|
||||
###########################
|
||||
###########################
|
||||
name: Lint Code Base
|
||||
|
||||
#
|
||||
# Documentation:
|
||||
# https://help.github.com/en/articles/workflow-syntax-for-github-actions
|
||||
#
|
||||
|
||||
#############################
|
||||
# Start the job on all push #
|
||||
#############################
|
||||
on: [push, pull_request]
|
||||
|
||||
###############
|
||||
# Set the Job #
|
||||
###############
|
||||
jobs:
|
||||
build:
|
||||
# Name the Job
|
||||
name: Lint Code Base
|
||||
# Set the agent to run on
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
##################
|
||||
# Load all steps #
|
||||
##################
|
||||
steps:
|
||||
##########################
|
||||
# Checkout the code base #
|
||||
##########################
|
||||
- name: Checkout Code
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
# Full git history is needed to get a proper list of changed files within `super-linter`
|
||||
fetch-depth: 0
|
||||
|
||||
################################
|
||||
# Run Linter against code base #
|
||||
################################
|
||||
- name: Lint Code Base
|
||||
uses: github/super-linter@v3
|
||||
env:
|
||||
VALIDATE_ALL_CODEBASE: false
|
||||
DEFAULT_BRANCH: main
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
21
aap-on-crc/LICENSE
Normal file
@@ -0,0 +1,21 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2021 Chad Ferman
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
162
aap-on-crc/README.md
Normal file
@@ -0,0 +1,162 @@
|
||||
# How to deploy Ansible Automation Platform via the Operator on CodeReady Containers
|
||||
|
||||
This is a quick how to deploy Ansible Automation platform locally on Code Ready Containers for a quick demo, or home lab.
|
||||
|
||||
## Definitions
|
||||
|
||||
[Red Hat CodeReady Containers aka CRC](https://developers.redhat.com/products/codeready-containers/overview) is a very easy to install local OpenShift cluster that runs on your laptop. This works for any operating system and can be downloaded from [here.](https://developers.redhat.com/content-gateway/rest/mirror/pub/openshift-v4/clients/crc/latest/)
|
||||
|
||||
[Ansible Automation Platform (AAP)](https://www.ansible.com/products/automation-platform) is the latest release of what was formerly known as Ansible Tower with many new features.
|
||||
|
||||
## CodeReady Containers Installation
|
||||
|
||||
Instructions to install crc are [here](https://access.redhat.com/documentation/en-us/red_hat_codeready_containers/1.35/html/getting_started_guide/installation_gsg)
|
||||
|
||||
TL;DR if you are on a mac you must be on 10.14 or above and you can just need to run crc binary you installed. (for Linux you will need to install libvirt via ```yum install virt-manager or apt if on debian``` and windows hyper-v must be enabled see install instructions above)
|
||||
|
||||
### From terminal
|
||||
|
||||
Untar files
|
||||
|
||||
```shell
|
||||
tar -xvf crc-linux-amd64.tar.xz
|
||||
```
|
||||
|
||||
Copy files to bin
|
||||
|
||||
```shell
|
||||
sudo cp crc-linux-*1.36.0*-amd64/crc /bin/.
|
||||
```
|
||||
|
||||
Run setup
|
||||
|
||||
```shell
|
||||
crc setup
|
||||
```
|
||||
|
||||
Increase default cpus so you can run AAP. `Note:` You can sometimes get away with 6, however 8 has worked best for most people
|
||||
|
||||
```shell
|
||||
crc config set cpus 8
|
||||
```
|
||||
|
||||
Increase default memory so you can run AAP.
|
||||
|
||||
```shell
|
||||
crc config set memory 12288
|
||||
```
|
||||
|
||||
Then to run it:
|
||||
|
||||
```shell
|
||||
crc start
|
||||
```
|
||||
|
||||
>>Note: If this is the first time you are installing CodeReady it will ask for a pull secret. You will need to get this from [https://cloud.redhat.com](https://cloud.redhat.com) once logged in choose openshift on the left followed by local install and click copy pull secret and paste it into the terminal.
|
||||
|
||||

|
||||
|
||||
Once it is installed it should give you information to log in, however you can always retrieve this with:
|
||||
|
||||
```shell
|
||||
crc console --credentials
|
||||
```
|
||||
|
||||
## Installing the Ansible Automation Platform Operator
|
||||
|
||||
---
|
||||
|
||||
## Login to the crc console as kubeadmin
|
||||
|
||||
[https://console-openshift-console.apps-crc.testing](https://console-openshift-console.apps-crc.testing) (get password via ```crc console --credentials``` )
|
||||
|
||||

|
||||
|
||||
---
|
||||
|
||||
## Once logged into the CRC/Openshift local instance click on OperatorHub on the left
|
||||
|
||||

|
||||
|
||||
---
|
||||
|
||||
### Type Ansible into the filter window and choose Ansible Automation Platform
|
||||
|
||||

|
||||
|
||||
---
|
||||
|
||||
## Click install
|
||||
|
||||

|
||||
|
||||
---
|
||||
|
||||
## Allow all the defaults and click install again
|
||||
|
||||

|
||||
|
||||
---
|
||||
|
||||
## Once it is installed click view operator
|
||||
|
||||

|
||||
|
||||
---
|
||||
|
||||
## Click Create Instance in the Automation Controller box (third from left)
|
||||
|
||||

|
||||
|
||||
---
|
||||
|
||||
## Click Create (you can rename to whatever you want default is example)
|
||||
|
||||

|
||||
|
||||
---
|
||||
|
||||
## Click on instance you created
|
||||
|
||||

|
||||
|
||||
---
|
||||
|
||||
## Loging to AAP console (click on URL link on right. The password is in the Admin Password link below the URL)
|
||||
|
||||

|
||||
|
||||
## Add Subscription via your redhat login (if you dont have one click the request trial button at the top)
|
||||
|
||||
`Note:` Some users have reported that `request subscription` takes a little time to populate, so if you don't see your trial in the next step please try again a little later.
|
||||
|
||||

|
||||
|
||||
## Select the subscription (then next, next, submit)
|
||||
|
||||

|
||||
|
||||
Now you have a fully functional AAP instance to test with.
|
||||
|
||||

|
||||
|
||||
---
|
||||
|
||||
## Known Issues and fixes
|
||||
|
||||
### AAP Memory Requirements
|
||||
|
||||
The AAP operator by default assigns 2gib to each container. Due to this your deployment of AAP may fail with only 12gib assigned to CRC. You can see the failure under pods in the Ansible Automation Project like this:
|
||||
|
||||

|
||||
|
||||
To fix this you have a few options:
|
||||
|
||||
1. Add more ram via crc setup set memory 16384
|
||||
2. Change the memory resource limits to the pod (Deployments >> Edit Resource limits)
|
||||
|
||||

|
||||
|
||||
Change to 500 millicores and 1mib like below:
|
||||
|
||||

|
||||
BIN
aap-on-crc/images/aap_dash.png
Normal file
|
After Width: | Height: | Size: 302 KiB |
BIN
aap-on-crc/images/all_defaults.png
Normal file
|
After Width: | Height: | Size: 71 KiB |
BIN
aap-on-crc/images/choose_aap.png
Normal file
|
After Width: | Height: | Size: 26 KiB |
BIN
aap-on-crc/images/choose_operators.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
aap-on-crc/images/click_install.png
Normal file
|
After Width: | Height: | Size: 21 KiB |
BIN
aap-on-crc/images/click_instance.png
Normal file
|
After Width: | Height: | Size: 53 KiB |
BIN
aap-on-crc/images/crc_login.png
Normal file
|
After Width: | Height: | Size: 133 KiB |
BIN
aap-on-crc/images/create-example.png
Normal file
|
After Width: | Height: | Size: 44 KiB |
BIN
aap-on-crc/images/create_controller.png
Normal file
|
After Width: | Height: | Size: 33 KiB |
BIN
aap-on-crc/images/instance.png
Normal file
|
After Width: | Height: | Size: 114 KiB |
BIN
aap-on-crc/images/login_aap.png
Normal file
|
After Width: | Height: | Size: 60 KiB |
BIN
aap-on-crc/images/podfailure.png
Normal file
|
After Width: | Height: | Size: 98 KiB |
BIN
aap-on-crc/images/pull_secret.png
Normal file
|
After Width: | Height: | Size: 84 KiB |
BIN
aap-on-crc/images/resources.png
Normal file
|
After Width: | Height: | Size: 219 KiB |
BIN
aap-on-crc/images/resources2.png
Normal file
|
After Width: | Height: | Size: 144 KiB |
BIN
aap-on-crc/images/select_sub.png
Normal file
|
After Width: | Height: | Size: 77 KiB |
BIN
aap-on-crc/images/spec_update.png
Normal file
|
After Width: | Height: | Size: 154 KiB |
BIN
aap-on-crc/images/subscription.png
Normal file
|
After Width: | Height: | Size: 194 KiB |
BIN
aap-on-crc/images/view_oper.png
Normal file
|
After Width: | Height: | Size: 23 KiB |