
As a newer project, Spyglass is still a work in progress in terms of its styling. This change is meant to help improve readability and compliance of Spyglass source code. To match other Airship projects, this change implements YAPF into tox so linting is automatically ran. This will hopefully keep formatting grey areas styled consistently. PEP-8: https://www.python.org/dev/peps/pep-0008/ OpenStack Style Guidelines: https://docs.openstack.org/hacking/latest/user/hacking.html PEP Index: https://www.python.org/dev/peps/ Depends on https://review.openstack.org/#/c/648764. Change-Id: I45b19cc8a7932fd7823dcb69f64a0a1bf19fc434
68 lines
1.9 KiB
ReStructuredText
68 lines
1.9 KiB
ReStructuredText
..
|
|
Copyright 2018 AT&T Intellectual Property.
|
|
All Rights Reserved.
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License"); you may
|
|
not use this file except in compliance with the License. You may obtain
|
|
a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
|
License for the specific language governing permissions and limitations
|
|
under the License.
|
|
|
|
==========================
|
|
Developer Quickstart Guide
|
|
==========================
|
|
|
|
To run your first spyglass job, follow these steps from inside the
|
|
airship-spyglass directory.
|
|
|
|
1. Install external dependencies if not already installed.
|
|
|
|
.. code-block:: console
|
|
|
|
sudo apt install -y python3-pip
|
|
sudo apt install -y tox
|
|
|
|
2. Set up an environment with tox.
|
|
|
|
.. code-block:: console
|
|
|
|
tox -e py36 --notest
|
|
|
|
3. Enter the tox environment.
|
|
|
|
.. code-block:: console
|
|
|
|
source .tox/py36/bin/activate
|
|
|
|
4. Install spyglass in the tox environment.
|
|
|
|
.. code-block:: console
|
|
|
|
pip install -e .
|
|
|
|
5. Run spyglass on the example files to generate an intermediate document.
|
|
|
|
.. code-block:: console
|
|
|
|
mkdir intermediate
|
|
spyglass -g -s airship-seaworthy -t tugboat \
|
|
-idir intermediate \
|
|
--excel_spec spyglass/examples/excel_spec.yaml \
|
|
--excel spyglass/examples/SiteDesignSpec_v0.1.xlsx \
|
|
--additional_config spyglass/examples/site_config.yaml \
|
|
--template_dir spyglass/examples/templates/
|
|
|
|
6. Run spyglass on the intermediate document to generate manifests.
|
|
|
|
.. code-block:: console
|
|
|
|
mkdir manifest_dir
|
|
spyglass -m -i intermediate/airship-seaworthy_intermediary.yaml \
|
|
-mdir manifest_dir/ -tdir spyglass/examples/templates/
|