Skip to content

Commit

Permalink
fix various installer issues
Browse files Browse the repository at this point in the history
  • Loading branch information
sebovzeoueb committed Dec 12, 2024
1 parent b474694 commit f57db2b
Show file tree
Hide file tree
Showing 9 changed files with 19 additions and 27 deletions.
12 changes: 1 addition & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,22 +47,12 @@ You no longer need to clone this repository to run Concierge.
> [!TIP]
> Pay attention to the use of dashes and underscores in the commands!
If you're not concerned about using a virtual environment you can just use the 2 commands below in the directory of your choosing:
Run the following while not being in a virtual environment. This command will create the virtual environment and run the installer from within it.

`python -m pip install launch-concierge`

`python -m launch_concierge.install`

If you prefer to keep things contained in a virtual environment you can use the 4 commands below:

`python -m venv .`

`.\scripts\activate.ps1` or `source bin/activate` depending on your Operating System

`pip install launch-concierge`

`install_concierge`

Answer the questions and then the installer will ask if you are ready to make changes to the system.
Answer "yes" and let the installation begin!
There may be additional questions during the installation depending on the options you selected.
Expand Down
10 changes: 4 additions & 6 deletions concierge_packages/installer/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
[project]
name = "install-concierge"
version = "0.5a5"
version = "0.5a12"
requires-python = ">=3.10"
dependencies = [
"script-builder~=0.2a0",
"isi-util~=0.2a0",
"concierge-util~=0.2a2",
"packaging",
"python-dotenv"
"python-dotenv",
"requests",
"cryptography"
]

[project.scripts]
install_concierge = "install_concierge.install:install"
relaunch_concierge = "install_concierge.relaunch:relaunch"

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def clean_up_existing():
print("Concierge instance discovered.")
print("This script can help reset your system for a re-install.\n")

new_version = version("launch_concierge")
new_version = version("install_concierge")
if existing_version and new_version != existing_version:
# find if we have any upgrade scripts between the existing and new version
start_index = find_index(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ def install_demo_users():
"exec",
"-d",
"concierge",
"python -m concierge_scripts.add_keycloak_demo_users",
"python",
"-m",
"concierge_scripts.add_keycloak_demo_users",
]
)
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from importlib.resources import files
import launch_concierge
import install_concierge

package_dir = files(launch_concierge)
package_dir = files(install_concierge)
2 changes: 1 addition & 1 deletion concierge_packages/launcher/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "launch-concierge"
version = "0.5a5"
version = "0.5a12"
requires-python = ">=3.10"
dependencies = [
"script-builder~=0.2a1"
Expand Down
4 changes: 2 additions & 2 deletions concierge_packages/launcher/src/launch_concierge/install.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

def install():
setup_pip()
install_package(f"concierge-installer=={version("launch_concierge")}")
run_in_venv("install_concierge")
install_package(f"install-concierge=={version("launch_concierge")}")
run_in_venv("install_concierge.install")


if __name__ == "__main__":
Expand Down
6 changes: 4 additions & 2 deletions concierge_packages/launcher/src/launch_concierge/relaunch.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
from script_builder.util import run_in_venv


def relaunch():
# TODO: run relaunch_concierge in venv
pass
run_in_venv("install_concierge.relaunch")


if __name__ == "__main__":
Expand Down
2 changes: 1 addition & 1 deletion publish_package.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
cwd = os.getcwd()
package_dir = os.path.join(cwd, "concierge_packages", package_name)
os.chdir(package_dir)
shutil.rmtree("dist")
shutil.rmtree("dist", ignore_errors=True)
subprocess.run(["python", "-m", "build"])
os.chdir(cwd)
subprocess.run(
Expand Down

0 comments on commit f57db2b

Please sign in to comment.